博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

随笔分类 -  C#常用函数

摘要:Environment.GetEnvironmentVariable("WINDIR")[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment]public static string GetEnvironmentVariable ( string variable, EnvironmentVariableTarget target)从当前进程或者从当前用户或本地计算机的 Windows 操作系统注册表项检索环境变量的值。 variable环境变量名。targetEnv 阅读全文

posted @ 2012-02-10 09:54 LonelyStar

摘要:.net用新的日期方法,就是使用Int64来代替Double类型储存时间。但仍然提供了转换为老类型日期的方法,就是DataTime的ToOADate和FormOADate方法。你在MSDN中输入这些关键字,就能很快找到使用方法。[代码] 阅读全文

posted @ 2008-10-17 08:53 LonelyStar 阅读(3838) 评论(0) 推荐(0)

摘要:[代码] 阅读全文

posted @ 2008-10-07 15:41 LonelyStar 阅读(2506) 评论(1) 推荐(0)

摘要:Code Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->private static DateTime GetFridayDate(DateTime standardDate) { int weekNum = ... 阅读全文

posted @ 2008-08-15 10:38 LonelyStar 阅读(518) 评论(0) 推荐(0)