<?xml version="1.0" encoding="utf-8" ?><rss version="2.0"><channel><title><![CDATA[Hauk.Wong]]></title><description><![CDATA[天下事有难易乎]]></description><link>https://blog.csdn.net/haukwong</link><language>zh-cn</language><generator>https://blog.csdn.net/</generator><copyright><![CDATA[Copyright &copy; haukwong]]></copyright><item><title><![CDATA[微软OFFICE在线预览]]></title><link>https://blog.csdn.net/haukwong/article/details/125448678</link><guid>https://blog.csdn.net/haukwong/article/details/125448678</guid><author>haukwong</author><pubDate>Fri, 24 Jun 2022 16:52:04 +0800</pubDate><description><![CDATA[https://view.officeapps.live.com/op/embed.aspx?src=https://school.thinkland.ai/CEP-Evaluation/1656037109-Essay.docxhttps://view.officeapps.live.com/op/view.aspx?src=https://school.thinkland.ai/CEP-Evaluation/1656037109-Acceptance.xlsx]]></description><category></category></item><item><title><![CDATA[JS验证身份证号码正确性]]></title><link>https://blog.csdn.net/haukwong/article/details/47425437</link><guid>https://blog.csdn.net/haukwong/article/details/47425437</guid><author>haukwong</author><pubDate>Tue, 11 Aug 2015 19:32:59 +0800</pubDate><description><![CDATA[function checkIdcard(idcard) {
    var Errors = new Array(
        "验证通过!",
        "请输入18位身份证号!",
        "身份证号码出生日期超出范围或含有非法字符!",
        "身份证号码校验错误!",
        "身份证地区非法!"
    );
    var area = {
   ]]></description><category></category></item><item><title><![CDATA[SQL SERVER跨数据库查询]]></title><link>https://blog.csdn.net/haukwong/article/details/17024517</link><guid>https://blog.csdn.net/haukwong/article/details/17024517</guid><author>haukwong</author><pubDate>Fri, 29 Nov 2013 14:31:17 +0800</pubDate><description><![CDATA[exec sp_addlinkedserver 'linkserver','','SQLOLEDB','192.168.1.200'
EXEC sp_addlinkedsrvlogin 'linkserver','false',NULL,'sa','123456'

select * from linkserver.TestDB.dbo.TestTable

Exec sp_droplinkeds]]></description><category></category></item><item><title><![CDATA[C#读取SharePoint的List中的数据及操作SharePoint]]></title><link>https://blog.csdn.net/haukwong/article/details/8994044</link><guid>https://blog.csdn.net/haukwong/article/details/8994044</guid><author>haukwong</author><pubDate>Thu, 30 May 2013 12:58:51 +0800</pubDate><description><![CDATA[一般SharePoint都有提供一个webservice来访问、操作SharePoint的各项数据。
地址一般为http://server/_vti_bin/Lists.asmx


下面是一个简单的读取SharePoint List数据的例子：

        private void button1_Click(object sender, EventArgs e)]]></description><category></category></item><item><title><![CDATA[C# 动态计算表达式的值--动态编译和DataTable.Compute()]]></title><link>https://blog.csdn.net/haukwong/article/details/8707310</link><guid>https://blog.csdn.net/haukwong/article/details/8707310</guid><author>haukwong</author><pubDate>Thu, 30 May 2013 12:49:30 +0800</pubDate><description><![CDATA[public static void TestComput(string expression)
        {
            //要编译的代码段
            string code = @"public class TestCompute
{public static object Compute()
{return @exp;}}";
            code]]></description><category></category></item><item><title><![CDATA[匿名对象和object的转换]]></title><link>https://blog.csdn.net/haukwong/article/details/8697086</link><guid>https://blog.csdn.net/haukwong/article/details/8697086</guid><author>haukwong</author><pubDate>Wed, 20 Mar 2013 16:29:38 +0800</pubDate><description><![CDATA[有时候经常用到需要把一个匿名对象存入session或List或其他容器中，可是取出来的时候变成object了，不太方便使用。
下面是一种转换方式：

    class Program
    {
        static void Main(string[] args)
        {
            List olist = new List();]]></description><category></category></item><item><title><![CDATA[[C#/asp.net]字符串编码、解码以及编码转换]]></title><link>https://blog.csdn.net/haukwong/article/details/8433648</link><guid>https://blog.csdn.net/haukwong/article/details/8433648</guid><author>haukwong</author><pubDate>Tue, 25 Dec 2012 16:11:18 +0800</pubDate><description><![CDATA[在项目开发中不少朋友都会遇到字符串编码、解码或者编码转换的问题。
为了方便初学者朋友，我就在这里抛砖引玉地讲解一下吧。
在C#中我们一般使用System.Text.Encoding来处理字符串编码的问题。
1、字符串解码
string code = "00430023662f4e0095e85f884f1896c576848bed8a00";

有这么一段代码，我们如何把它转换成可识别]]></description><category></category></item><item><title><![CDATA[[C#] 10进制转62进制，实现穷举指定位数的所有密码组合（暴力破解）]]></title><link>https://blog.csdn.net/haukwong/article/details/8111202</link><guid>https://blog.csdn.net/haukwong/article/details/8111202</guid><author>haukwong</author><pubDate>Thu, 25 Oct 2012 15:18:17 +0800</pubDate><description><![CDATA[因为我们这里要穷举的密码包括0-9,a-z,A-Z共62个字符，所以我们采用62进制来遍历。


首先，我们实现一个10进制转62进制的方法。


        private static char[] charSet = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ".ToCharArray();]]></description><category></category></item><item><title><![CDATA[[C#]简单重写IComparer接口，实现自己的String.CompareTo 方法，自定义比较规则。]]></title><link>https://blog.csdn.net/haukwong/article/details/8055412</link><guid>https://blog.csdn.net/haukwong/article/details/8055412</guid><author>haukwong</author><pubDate>Wed, 10 Oct 2012 11:14:19 +0800</pubDate><description><![CDATA[在项目中经常会用到字符串比较，但是有时候对字符串的操作比较多，规则各异。
比如有的地方我们需要用排序规则，有的地方需要忽略大小写，我们该如何写一个比较容易操作的比较方法呢？
重新实现IComparer接口不失为一个好办法。
我们可以在实现Compare方法的时候指定比较规则CompareOptions




成员名称
说明


IgnoreCase
指示字符串比较必须忽]]></description><category></category></item><item><title><![CDATA[C# 一个关于等差数列的算法]]></title><link>https://blog.csdn.net/haukwong/article/details/8052308</link><guid>https://blog.csdn.net/haukwong/article/details/8052308</guid><author>haukwong</author><pubDate>Tue, 09 Oct 2012 15:05:22 +0800</pubDate><description><![CDATA[一个积分，对应一个等级，但一个等级可能对应多个积分，这样，如果给你任意一个积分，怎么用公式算出等级？没有财富了，郁闷……
前面3级情况特殊：
积分：0 = 等级：1
积分：1 = 等级：2
积分：2 = 等级：3
后面情况一样，每4级为一个阶段。
积分：3或4或5 = 等级：4
积分：6或7或8 = 等级：5
积分：9或10或11 = 等级：6
积分：12或13或14 = 等级：]]></description><category></category></item><item><title><![CDATA[c#你怎么判断一个字符串是否是数字？]]></title><link>https://blog.csdn.net/haukwong/article/details/8029946</link><guid>https://blog.csdn.net/haukwong/article/details/8029946</guid><author>haukwong</author><pubDate>Fri, 28 Sep 2012 20:53:43 +0800</pubDate><description><![CDATA[今天在写代码时突然想起测试经常用Microsoft.VisualBasic.Information.IsNumeric判断 url参数是否为数字时的这个方法的效率
因为数字是字符串是直接使用的，所以不需要转型，也就没有用tryparse
结果一测试吓一跳，这个方法的效率是如此的低，再测试了下tryparse还不错，正则的也比较差，
没什么技术含量，看结果吧：

先拓展下字符串：]]></description><category></category></item><item><title><![CDATA[C# 登录QQ网站并获取QQ相关信息]]></title><link>https://blog.csdn.net/haukwong/article/details/7971979</link><guid>https://blog.csdn.net/haukwong/article/details/7971979</guid><author>haukwong</author><pubDate>Wed, 12 Sep 2012 17:56:56 +0800</pubDate><description><![CDATA[本文以登录http://id.qq.com为例，获取用户等级、Q龄等相关信息。
本文界面使用WPF制作 
技术涵盖：C#、wpf、HttpWebRequest、HttpWebResponse
（.net framework 4.5，当然你也可以使用4.0。不知道为什么使用3.5无法得到正确的结果，代码一模一样，还望高人指点！）








1、获取独立登录框地址]]></description><category></category></item><item><title><![CDATA[C# 泛型编程之泛型类、泛型方法、泛型约束]]></title><link>https://blog.csdn.net/haukwong/article/details/7840158</link><guid>https://blog.csdn.net/haukwong/article/details/7840158</guid><author>haukwong</author><pubDate>Tue, 07 Aug 2012 17:36:43 +0800</pubDate><description><![CDATA[泛型方法

    在C#2.0中，方法可以定义特定于其执行范围的泛型参数，如下所示：


    public class MyClassT>
    {
        //指定MyMethod方法用以执行类型为X的参数
        public void MyMethodX>(X x) 
        {
            //
        }]]></description><category></category></item><item><title><![CDATA[Silverlight 之数据绑定（简单例子）]]></title><link>https://blog.csdn.net/haukwong/article/details/7333543</link><guid>https://blog.csdn.net/haukwong/article/details/7333543</guid><author>haukwong</author><pubDate>Thu, 08 Mar 2012 17:04:18 +0800</pubDate><description><![CDATA[首先我们先明确Databinding Mode的3种模式：


Databinding Mode


OneTime
目标控件的属性只更新一次，以后的更新会被忽略




OneWay
数据对象的值会同步到目标控件的属性，但是目标控件的属性改变不会被同步到数据对象中


TwoWay
目标控件的属性和数据对象的值相互同步





其中，用于OneWa]]></description><category></category></item><item><title><![CDATA[Flex页面打印(打印可显示组建--UIComponent)]]></title><link>https://blog.csdn.net/haukwong/article/details/7103435</link><guid>https://blog.csdn.net/haukwong/article/details/7103435</guid><author>haukwong</author><pubDate>Mon, 26 Dec 2011 16:36:53 +0800</pubDate><description><![CDATA[今天项目中做一功能，需要打印一个显示产品详细信息的页面。
开始想用右键的打印功能，但是这个一打印会把整个Flex界面都打印出来。而我只需要产品详细信息那一部分页面。所以这个不符合需求。
然后在网上找看有没有第三方组件，在一个第三组件的源代码中发现了几句有用的代码，实现了我的需求。
在此贴出来以供和大家分享，交流。


protected function btn_print_click]]></description><category></category></item><item><title><![CDATA[silverlight datagrid动态生成列&动态绑定]]></title><link>https://blog.csdn.net/haukwong/article/details/7078018</link><guid>https://blog.csdn.net/haukwong/article/details/7078018</guid><author>haukwong</author><pubDate>Fri, 16 Dec 2011 16:42:43 +0800</pubDate><description><![CDATA[由于返回的数据表的列不是固定的，所以webservice端的实体我们直接建立如下格式：

    public class DynamicObj
    {
        public string Item_Name { get; set; }           //列名称
        public List Item_Value { get; set; }    //列值集合]]></description><category></category></item><item><title><![CDATA[silverlight datagrid 模拟单元格双击事件]]></title><link>https://blog.csdn.net/haukwong/article/details/7077711</link><guid>https://blog.csdn.net/haukwong/article/details/7077711</guid><author>haukwong</author><pubDate>Fri, 16 Dec 2011 15:27:37 +0800</pubDate><description><![CDATA[最近做一silverlight项目，需要在双击datagrid单元格的时候更具单元格内容弹出新窗口。
查了不少资料发现silverlight很难实现这个效果，于是就用了如下方法来模拟（用户体验和双击一样）。



        //// 模拟双击事件
        private TimeSpan timeSpan = TimeSpan.Zero;
        private v]]></description><category></category></item><item><title><![CDATA[C#不同方式调用webservice]]></title><link>https://blog.csdn.net/haukwong/article/details/7024065</link><guid>https://blog.csdn.net/haukwong/article/details/7024065</guid><author>haukwong</author><pubDate>Tue, 29 Nov 2011 16:52:40 +0800</pubDate><description><![CDATA[继上一篇不添加引用调用webservice这次我们谈谈添加引用调用webservice的几种方式。
首先我们可以看到添加webservice引用有2种，如图：
一种叫service References，另一种叫Web Reference（.net framework 3.5或以下才有）

现在我们就来看看分别在这两种引用下调用webservice。
1、Service Referenc]]></description><category></category></item><item><title><![CDATA[C#不添加引用，动态调用webservice]]></title><link>https://blog.csdn.net/haukwong/article/details/7023039</link><guid>https://blog.csdn.net/haukwong/article/details/7023039</guid><author>haukwong</author><pubDate>Tue, 29 Nov 2011 13:03:29 +0800</pubDate><description><![CDATA[好像很多人做WebService的时候都是直接添加引用的方式，然后调用服务端的方法。这样就个问题，就是每次我服务端添加了方法或者修改了方法后都要更新Web引用，这样比较麻烦。下面给一个不用添加引用的方式调用服务端的方法.只是一个简单的测试，不是很规范,用得着的人可以自己封装一下,然后直接传服务端的方法名进去，Type.GetMethod获取方法,然后method.Invoke返回结果。
高手些多]]></description><category></category></item><item><title><![CDATA[使用程序代码安装/卸载.net服务（不使用InstallUtil.exe）]]></title><link>https://blog.csdn.net/haukwong/article/details/7022961</link><guid>https://blog.csdn.net/haukwong/article/details/7022961</guid><author>haukwong</author><pubDate>Tue, 29 Nov 2011 12:36:09 +0800</pubDate><description><![CDATA[在上一篇文章（C#系统服务定时执行）中讲到使用InstallUtil.exe来安装和卸载系统服务。那么，我们是否可以使用自己写的代码来做这些工作呢？答案是肯定的。
下面我们来看看如何实现：
1、首先我们照上一片文章配置好系统服务，并且生成一个exe文件。
2、这里我们用一个winform来做，上面画2个按钮（一个安装服务，一个卸载服务）。
3、安装服务按钮点击事件

        /]]></description><category></category></item></channel></rss>