zoukankan      html  css  js  c++  java
  • open live write 代码高亮插件的配置和使用

    第一步:下载open live writer插件,下载地址:http://www.cnblogs.com/memento/p/5995173.html

    最新插件下载地址:Memento.OLW_V1.0.0.5.7z

    image

    第二步:找到open live writer的安装目录,并在目录下创建文件夹Plugins


    image

    第三步:解压缩插件的压缩包Memento.OLW_V1.0.0.5.7z,并把文件都拷贝到Plugins文件夹中

    image

    第四步:右键选择每一个文件的属性,看是否有解除锁定,如果有,选择解除,斌确认

    image

    注:我的系统是win7,有解除锁定,必须解除后,插件才能使用,请注意

    这样open live writer的代码高亮插件就可以使用了

    image

    插入一段代码测试效果:

            /// <summary>
            /// List转换成DataTable
            /// </summary>
            /// <typeparam name="T"></typeparam>
            /// <param name="collection"></param>
            /// <returns></returns>
            public DataTable ToDataTable<T>(IEnumerable<T> collection)
            {
                var props = typeof(T).GetProperties();
                var dt = new DataTable();
                dt.Columns.AddRange(props.Select(p => new DataColumn(p.Name, p.PropertyType)).ToArray());
                if (collection.Count() > 0)
                {
                    for (int i = 0; i < collection.Count(); i++)
                    {
                        ArrayList tempList = new ArrayList();
                        foreach (PropertyInfo pi in props)
                        {
                            object obj = pi.GetValue(collection.ElementAt(i), null);
                            tempList.Add(obj);
                        }
                        object[] array = tempList.ToArray();
                        dt.LoadDataRow(array, true);
                    }
                }
                return dt;
            }



    出处:https://www.cnblogs.com/yangxi1081/p/9395226.html

  • 相关阅读:
    uva400 Unix ls
    cf641 div2 abcd
    cf619 div2 abcd
    cf620 div2 abcde
    atc160
    cf638 div2 abcd
    CodeCraft-20(Div. 2 abcd
    cf Round 621 abcd
    luogu1941 飞扬的小鸟
    UVA1601 The Morning afther Halloween
  • 原文地址:https://www.cnblogs.com/mq0036/p/12101912.html
Copyright © 2011-2022 走看看