SharePoint自带Silverlight WebPart中文输入问题处理
2011-03-21 16:44
274 查看
开发了SilverLight程序在SharePoint上使用,为了省事,就直接用了SharePoint自带的WebPart。可是在用的时候发现TextBox中文不能输入,网上一查,居然说2.0/3.0版本有这样的问题,不知道4.0有没有解决呢。在网上找到的解决办法都是直接去修改HTML里Object对象的Windowless属性,是在
<object data="data:application/x-silverlight-2," type="application/x-silverlight-2" width="100%" height="100%">
<param name="windowless" value="false"/>
可是在SharePoint中的SilverLight WebPart属性设置面板里找不到该属性。用Reflector看了下这个WebPart,其实是有个属性叫WindowlessMode的,只不过特性里没加可视化显示出来。
View Code
四、上传修改后的WebPart文件
五、插入修改后的web部件,试一试,输入中文OK了。
另外再说下那个CustomInitParameters,自定义初始化参数,设置方式需要处理分隔符,"key1=value1,key2=value2,key3=value3"。是应用程序级的初始化参数,可以是背景、颜色等,可以在程序中获得使用。
<object data="data:application/x-silverlight-2," type="application/x-silverlight-2" width="100%" height="100%">
<param name="windowless" value="false"/>
可是在SharePoint中的SilverLight WebPart属性设置面板里找不到该属性。用Reflector看了下这个WebPart,其实是有个属性叫WindowlessMode的,只不过特性里没加可视化显示出来。
View Code
<webParts> <webPart xmlns="http://schemas.microsoft.com/WebPart/v3"> <metaData> <type name="Microsoft.SharePoint.WebPartPages.SilverlightWebPart, Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" /> <importErrorMessage>无法导入此 Web 部件。</importErrorMessage> </metaData> <data> <properties> <property name="HelpUrl" type="string" /> <property name="AllowClose" type="bool">True</property> <property name="ExportMode" type="exportmode">All</property> <property name="Hidden" type="bool">False</property> <property name="AllowEdit" type="bool">True</property> <property name="Direction" type="direction">NotSet</property> <property name="TitleIconImageUrl" type="string" /> <property name="AllowConnect" type="bool">True</property> <property name="HelpMode" type="helpmode">Modal</property> <property name="CustomProperties" type="string" null="true" /> <property name="AllowHide" type="bool">True</property> <property name="Description" type="string">A web part to display a Silverlight application.</property> <property name="CatalogIconImageUrl" type="string" /> <property name="MinRuntimeVersion" type="string" null="true" /> <property name="ApplicationXml" type="string" /> <property name="AllowMinimize" type="bool">True</property> <property name="AllowZoneChange" type="bool">True</property> <property name="CustomInitParameters" type="string">windowless="false"</property> <property name="Height" type="unit">600px</property> <property name="ChromeType" type="chrometype">Default</property> <property name="Width" type="unit" /> <property name="Title" type="string">Silverlight Web Part</property> <property name="ChromeState" type="chromestate">Normal</property> <property name="TitleUrl" type="string" /> <property name="Url" type="string">/_LAYOUTS/ClientBin/xxxxx/xxxxxxx.xap</property> <property name="WindowlessMode" type="bool">False</property> </properties> </data> </webPart> </webParts>
四、上传修改后的WebPart文件
五、插入修改后的web部件,试一试,输入中文OK了。
另外再说下那个CustomInitParameters,自定义初始化参数,设置方式需要处理分隔符,"key1=value1,key2=value2,key3=value3"。是应用程序级的初始化参数,可以是背景、颜色等,可以在程序中获得使用。
相关文章推荐
- SharePoint 2010 Silverlight webpart 加载超时的问题
- 在前端界面输入中文经过处理存进数据库为乱码问题
- silverlight 不能输入中文问题
- 解决Qt 5.7自带Creator在Ubuntu 16.04下不能输入中文的问题(fcitx输入框架)
- silverlight---TextBox只能输入数字或小数 屏蔽中文输入和非法粘贴: KeyDown事件处理方法
- Joomla!系统自带的搜索组件com_search如果输入中文关键词,有两个问题:
- SharePoint 2010 Silverlight webpart 加载超时的问题
- silverlight中文不能输入问题
- 处理中文输入的问题
- sharepoint 中用自带的download.aspx实现文件的下载,中文文件名编码的问题
- 关于SilverLight webPart 在SharePoint调试问题。
- UVaoj 1586处理输入的一个小问题
- Silverlight3学习笔记6(Silverlight,WCF双工通信)(回调异常问题处理)
- spring mvc rest风格的URL输入中文乱码问题
- IText中文处理问题!!!
- Struts2 与 js 处理Get方式提交的中文参数乱码问题
- 使用iText5.x创建PDF中文处理问题
- FLASH Flex输入框不支持输入中文的问题
- 简单解决sublime 中文输入问题
- 英文Ubuntu系统中skype输入中文问题