随笔分类 -  Silverlight

后台设计控件的样式Style
摘要:先将样式定义在App.xaml中<Application.Resources> <Style x:Key="MsgTextBlock" TargetType="TextBlock"> <Setter Property="Height" Value="auto"/> <Setter Property="Width" Value="auto"/> <Setter Property="FontSize" Va 阅读全文
posted @ 2013-02-04 09:39 NNKOOK 阅读(874) 评论(0) 推荐(1)
Silverlight动态设置样式
摘要:1.从页面资源中获取样式并应用btnTest.Style=(Style)this.Resources["BigButtonStyle"]2.从项目中单独分开的资源字典文件(或一个引用的程序集中)中获取样式。首先,需要创建一个ResourceDictionary对象并提供正确的URI:ResourceDictionarydictionary=newResourceDictionary();dictionary.Source=newUri("/Test.xaml",UriKind.Relative);假设样式字典的名字叫Test.xaml,资源字典的编译格式 阅读全文
posted @ 2012-11-08 15:06 NNKOOK 阅读(185) 评论(0) 推荐(0)
Silverlight项目在IIS6上部署注意事项
摘要:IIS6上部署Silverlight项目1、 安装net framework 4.0.303192、 发布IIS3、 ASP.NET----ASP.NET的版本要选择为4.0.303194、 目录安全性----身份验证和访问控制[编辑]-----去掉集成Windows身份验证5、 主目录----执行权限:纯脚本6、 Http头---MIME类型,新增Mine类型如下:.xap application/x-silverlight-app.xaml application/xaml+xml.xbap application/x-ms-xbap7、 从开发机拷备文件夹(目录:C:\WINDOWS\M 阅读全文
posted @ 2012-05-10 16:22 NNKOOK 阅读(2416) 评论(1) 推荐(1)
silverlight DataGrid 模拟实现双击行事件
摘要:首先看一下效果: 环境:silverlight 4 ,vs2010, windows xp xaml:<sdk:DataGridAutoGenerateColumns="False"Height="164"LoadingRow="ResultsGrid_LoadingRow"IsReadOnly="True"HorizontalAlignment="Left"Margin="69,70,0,0"Name="dataGrid1"VerticalAlig 阅读全文
posted @ 2012-03-30 11:36 NNKOOK 阅读(923) 评论(0) 推荐(0)
RadControls for Silverlight(学习1-GridView) (转载)
摘要:引用:Telerik(官 网:http://www.telerik.com/)是保加利亚的一个软件公司,专注于微软.Net平台的表示层与内容管理控件。我们提供高度稳定性和丰富性能的组件产品,并可应用在非常严格的环境中。现在拥有 Microsoft, HP, Alcoa, BP, Harper Collins, Siemens, T-Mobile, HJ Heinz和一些最主要的教育机构和很多政府机关等客户。我在使用的版本是RadControls_for_Silverlight4_2011_1_0316,开发工具采用VS2010 +SQLServer2008R2进行测试学习Grid是我们做系统必 阅读全文
posted @ 2012-02-24 16:46 NNKOOK 阅读(568) 评论(0) 推荐(0)
Silverlight 4常用StringFormat格式总结
摘要:在Silverlight 4中使用StringFormat属性,可以简单的实现如下:<TextBlock Text=“{Binding Name, StringFormat=’当前登录用户: \{0\}’}”>这样实现简单而又方便。对于StringFormat属性的使用方法还有很多,下面使用实例演示常用的属性:<Gridx:Name="LayoutRoot"><ScrollViewerx:Name="PageScrollViewer"Style="{StaticResourcePageScrollViewerSty 阅读全文
posted @ 2011-12-30 14:04 NNKOOK 阅读(554) 评论(1) 推荐(0)
Silverlight导入数据的三种写法
摘要:说明: System.ServiceModel.DomainServices.Client.LoadOperation - 用于异步加载System.ServiceModel.DomainServices.Client.InvokeOperation - 用于异步调用System.ServiceModel.DomainServices.Client.SubmitOperation - 用于异步提交写法一privatevoidbutton3_Click(objectsender,RoutedEventArgse){ds.Load(ds.GetSelectAllStudentQuery(),(x) 阅读全文
posted @ 2011-12-13 11:15 NNKOOK 阅读(365) 评论(0) 推荐(0)
错误An entity with the same identity already exists in this EntitySet RIA
摘要:错误信息:缺少对象,An entity with the same identity already exists in this EntitySet RIA解决方案:1、如果你的表是要更新的,需要设置主键;2、identity字段,如果你的数据中这个字段值有零的就特别要注意了。 阅读全文
posted @ 2011-12-12 11:16 NNKOOK 阅读(639) 评论(0) 推荐(0)