日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

SilverLight非托管代码的初始化进度条方法

發布時間:2023/12/13 编程问答 26 豆豆
生活随笔 收集整理的這篇文章主要介紹了 SilverLight非托管代码的初始化进度条方法 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

SilverLight非托管代碼的初始化進度條方法

<script type="text/javascript">
??????? 錯誤處理函數
??????? function onSilverlightError(sender, args) ...

?

??????? //下載進度函數
??????? function onSourceDownloadProgressChanged(sender, eventArgs) {

??????????? sender.findName("progressText").Text = Math.round(eventArgs.progress * 100) + "%";
??????????? sender.findName("progressText2").Text = Math.round(eventArgs.progress * 100) + "%";
??????????? sender.findName("progressBarScale").ScaleX = eventArgs.progress;
??????? }
??? </script>

<body>

<div id="silverlightControlHost">
??<object data="data:application/x-silverlight-2," type="application/x-silverlight-2" width="100%" height="100%">
???<param name="splashscreensource" value="SplashScreen.xaml"/>
???? <param name="onSourceDownloadProgressChanged" value="onSourceDownloadProgressChanged" />
???? <param name="source" value="ClientBin/SlApp_System.xap"/>
???? <param name="onerror" value="onSilverlightError" />
???? <param name="background" value="Blue" />
???? <param name="minRuntimeVersion" value="3.0.40818.0" />
???? <param name="autoUpgrade" value="true" />
???<a href="http://go.microsoft.com/fwlink/?LinkID=149156&v=3.0.40818.0" style="text-decoration: none;">
???? ???<img src="http://go.microsoft.com/fwlink/?LinkId=108181" alt="獲取 Microsoft Silverlight" style="border-style: none"/>
???</a>
??</object><iframe id="_sl_historyFrame" style='visibility:hidden;height:0;width:0;border:0px'></iframe></div>

</body>

?

SplashScreen.xaml

<StackPanel xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" VerticalAlignment="Center" Margin="0,100,0,0"> <Image x:Name="myImage" Source="/silverlightchina.png" Height="56" Width="220" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="10" /> <StackPanel HorizontalAlignment="Center"> <Grid HorizontalAlignment="Center"> <Rectangle Stroke="#FFDEE6F0" HorizontalAlignment="Left" Width="300" Height="10" RadiusX="2" RadiusY="2" StrokeThickness="1"/> <Rectangle Fill="#FF7E99C8" HorizontalAlignment="Left" VerticalAlignment="Center" StrokeThickness="0" RadiusX="0" RadiusY="0" Width="296" Height="6" x:Name="progressBar" RenderTransformOrigin="0,0.5" Margin="4"> <Rectangle.RenderTransform> <ScaleTransform x:Name="progressBarScale" /> </Rectangle.RenderTransform> </Rectangle> </Grid> <Grid HorizontalAlignment="Center"> <TextBlock x:Name="progressText" Margin="18,0,17,19" Height="26" Text="0%" FontSize="16" Opacity="0.8" VerticalAlignment="Bottom" TextAlignment="Right"/> <TextBlock x:Name="progressText2" Margin="18,0,7,8" Height="70" Text="0%" FontSize="50" Opacity="0.04" FontWeight="Bold" VerticalAlignment="Bottom" TextAlignment="Right"/> </Grid> </StackPanel> </StackPanel>

?

轉載于:https://www.cnblogs.com/sqlite3/archive/2010/05/03/2566950.html

總結

以上是生活随笔為你收集整理的SilverLight非托管代码的初始化进度条方法的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。