asp.net - setting width of silverlight application in aspnet -
I have found the most impossible case here: I have created a small silver application that is one of the remote paths Image loads. The image is very wide, so it does not fit properly on the page when I see the image in the aspnet page, for some reason the lightweight silver application is cut to fit the current width of the page. When a large part of silver on the aspnet page reveals more than a different value of the image. I can not estimate the width of the image every time! What to do?
Silverlight code:
& lt; Canvas x: name = "layouts" & gt; & Lt; Image name = "imgTrack" & gt; & Lt; / Image & gt; & Lt; / Canvas & gt;
Aspen code:
& lt; Body & gt; & Lt; Form id = "form1" runat = "server" & gt; & Lt; Div id = "silverlightControlHost" style = "overflow: auto;" & Gt; & Lt; Object Data = "Data: App / X-Silverlight-2," Type = "App / X-Silverlight-2" & gt; & Lt; Param name = "source" value = "ClientBin / MidiSLMixer.xap" /> & Lt; Param name = "onError" value = "onSilverlight error" /> & Lt; Param name = "background" value = "white" /> & Lt; Param name = "minRuntimeVersion" value = "3.0.40624.0" /> & Lt; Param name = "auto upgrade" value = "true" /> & Lt; A href = "http://go.microsoft.com/fwlink/?LinkID=149156&v=3.0.40624.0" style = "text-decoration: none" & gt; & Lt; Img src = "http://go.microsoft.com/fwlink/?LinkId=108181" alt = "get Microsoft Silverlight" style = "border-style: none" /> & Lt; / A & gt; & Lt; / Object & gt; & Lt; Iframe id = "_ sl_historyFrame" style = "visibility: hidden; height: 0 pixel; width: 0 pixel; range: 0 pixels" & gt; & Lt; / Iframe & gt; & Lt; / Div & gt; & Lt; / Form & gt;
Thank you!
You have two options.
Silverlight app dynamically sized object
Once you download the image, you can access the Silverlight app
Handles the Silverlight scrolling
Another way to drop is to allow the image and scrolling in the ScrollViewer control.
Comments
Post a Comment