I have deployed a Silverlight 5 PivotViewer web app that runs successfully on the development machine to a server running IIS 6.0.
On that server, the application in a browser runs successfully from localhost. If, on the server, I browse to the html file directly, I get a blank pivotviewer control rendered (as if it can't find my cxml file)
Remotely, I get the same response, a blank pivotviewer control loads. I can access the cxml file remotely via http. However, for one reason or another, the pivotviewer comes up empty.
Please help!
Add the CXML, DZI and DZC MIME type to your webserver :
appcmd set config /section:staticContent /+[fileExtension='.cxml',mimeType='text/xml']
appcmd set config /section:staticContent /+[fileExtension='.dzc',mimeType='text/xml']
appcmd set config /section:staticContent /+[fileExtension='.dzi',mimeType='text/xml']
Related
I have a silverlight application with browsercontrol that needs to use Acrobat PDF Reader to display PDFs in the browser. I am using Acrobat Reader XI and internet explorer as browser. When the application is in the Stage environment everything works fine. However, when the application is in the Production environment pdf does not load or partially loads and stops. There is no difference between the two environments except production environment uses load balancer. The even weirder thing is that Production work and PDF loads when we hit a specific server URL instead of the load balancer URL. Why is it not loading. Why is this happening and better yet, how do I fix it?
Remember that Silverlight is a client technology. While you downloaded the initial site through the load balancer you live then on the client.
So the question is how do you load the pdf within silverlight?
If this is a direct url not through the load balancer the pdf file will not see the load balancer.
If the acrobat reader opens or not depends on the response mime-type and with pdf's this is a disscussion on its own.
Here you find a good stackoverflow question with an answer:
Proper MIME media type for PDF files
HTH
I've found a very small sample showing Silverlight SQL connection (http://www.codeproject.com/KB/silverlight/CntDbSlght.aspx), I've tested it and it works fine on local system, also I've changed its connection string so that it shows data from my remote database, but when I upload files to my host, I cannot see any SQL data, it seems that something is broken, how should I configure my web.config?
What are CrossDomain.XML and ClientAccessPolicy.XML files? should I upload them? If so, where should they be? How should I bind my service? what am I doing wrong? I click on VS2010 publish (in build menu) and select file system, then I upload all files existing in this folder, I use C#.
If you are trying to access an external Silverlight web service from your local dev environment you certainly need a ClientAccessPolicy.XML file on the website. This tells the site services where requests can come from (normally only from the same site the SL app was run from).
Your ClientAccessPolicy.XML file needs to go into the actual root of your website i.e. 'mydomain.com/ClientAccessPolicy.XML.
*Note: You do not also need a CrossDomain.XML if you have ClientAccessPolicy (which is the SL specific one). CrossDomain.xml is an older flash compatibility file that sometimes exists on sites.
I am currently looking into developing a silverlight app. I want to develop the app on my local machine for ease of development. I am using Apache Server on Windows which is hosting php. I am doing a WebClient DownloadStringASync to http://localhost/getData.php but the Silverlight webpage is running in visual studio asp server at http://localhost:54994/MySilverlight.aspx. I think because the silverlight app is running from the vs2010 server and I am making a call to my standard apache server it is having a cross domain problem. When the app is run the innerexception says System.Security.SecurityException at System.Net.Browser.BrowserHttpWebRequest.InternalEndGetResponse.
I have tried putting accesspolicy.xml file in the root of the asp server and the apache server but it still isn't fixing the problem. I know its not a problem with the code as if I run it from my website server and call the webclient request to the same domain it works fine.
Any help you can provide would be great thanks.
I've managed to solve the problem. I needed to have to crossdomain.xml and clientaccesspolicy.xml with the same code. For some reason if I only have one or the other it keeps on bringing up the security exception. As soon as both files in the root of the localhost directory of apache (i.e. in the root of htdocs) the silverlight app works fine
I am having a silverlight pivotviewer control in a sharepoint page. This Pivotviewer talks to a web service hosted under sharepoint to fetch cxml/dzi/dzc. Everything is fine as long as its in http. Once on https - the CXML and dzc responses come out fine, but the dzi never happens - no images come up.Can anyone let me know why this is happening - and how to fix this?
Note: The Image directory is also under the same Sharepoint site - its a virtual directory. So even this is under ssl. If I configure the image path {for forming dzi} to another http virtual directory, everything works fine. But it simply doesn't work for a https virtual directory under the SP site.
This should definitely work as I've done exactly that (using https) for http://percollate.com. Is it possible that https is bound to something unexpected on your IIS server? Have you tried using Fiddler to see what's happening?
I am trying to get started with Azure so that we can port an existing Silverlight app to Azure.
Problem: On running the Windows Azure project that contains Silverlight web app in web role, a blank page is displayed in browser due to error 2104: Could not download Silverlight application. Check web server settings
Things that I have tried
.xap mime type is registered for the Default Web Site in IIS7. Even the applicationHost.config file contains the right entries.
I have restarted the storage and compute emulators and performed IIS reset.
I also tried to put the following code in the silverlight app web.config
<system.webServer>
<staticContent>
<mimeMap fileExtension=".xap" mimeType="application/x-silverlight-app" />
</staticContent>
But this caused a compile error. Something tot he effect of not being able to attach the debugger to iis worker...
Any ideas how I can fix this issue?
Got the Problem. I had set the Mime type on the "Default Web Site". I needed to set it on the IIS Server (The topmost item in the tree).
It works now.