string vname=stLocation;
string delimStr = @"\";
char [] mySp = delimStr.ToCharArray();
string[] myweb = vname.Split(mySp);
string desktop=Environment.GetFolderPath(Environment.SpecialFolder.DesktopDirectory);
StreamWriter sw=new StreamWriter(File.Open(desktop+"\\系统.url",FileMode.Create,FileAccess.Write));
sw.WriteLine("[InternetShortcut]");
MessageBox.Show(strWebPort);
sw.WriteLine(string.Format("URL=http://{0}:{1}/{2}/FramePages/FrmMain.htm",Environment.MachineName,strWebPort,myweb[myweb.Length-2]));
sw.WriteLine("Modified=00B21CE31E06C30199");
sw.WriteLine( "IconFile=" + stLocation + "bin/" + "shell32.dll");
sw.WriteLine("IconIndex=13");
sw.Flush();
sw.Close();在生产快捷方式的时候
sw.WriteLine( "IconFile=" + stLocation + "bin/" + "shell32.dll");
sw.WriteLine("IconIndex=13");
这是用DLL文件的图标。
这一步怎样才能把快捷方式的图标指项我自己的ICO图标文件。
或告诉我怎样生成一个象shell32.dll的DLL 可以把路径指向它 就能获取我自己的图标文件!1
string delimStr = @"\";
char [] mySp = delimStr.ToCharArray();
string[] myweb = vname.Split(mySp);
string desktop=Environment.GetFolderPath(Environment.SpecialFolder.DesktopDirectory);
StreamWriter sw=new StreamWriter(File.Open(desktop+"\\系统.url",FileMode.Create,FileAccess.Write));
sw.WriteLine("[InternetShortcut]");
MessageBox.Show(strWebPort);
sw.WriteLine(string.Format("URL=http://{0}:{1}/{2}/FramePages/FrmMain.htm",Environment.MachineName,strWebPort,myweb[myweb.Length-2]));
sw.WriteLine("Modified=00B21CE31E06C30199");
sw.WriteLine( "IconFile=" + stLocation + "bin/" + "shell32.dll");
sw.WriteLine("IconIndex=13");
sw.Flush();
sw.Close();在生产快捷方式的时候
sw.WriteLine( "IconFile=" + stLocation + "bin/" + "shell32.dll");
sw.WriteLine("IconIndex=13");
这是用DLL文件的图标。
这一步怎样才能把快捷方式的图标指项我自己的ICO图标文件。
或告诉我怎样生成一个象shell32.dll的DLL 可以把路径指向它 就能获取我自己的图标文件!1
解决方案 »
- scripX 预览弹出 printing is still in Progress
- 谁知道买哪的空间支持MSDTC服务?
- 请问GridView的EmptyDataTemplate和EmptyDataText两个属性有什么区别?
- .net 2.0 不支持根路径?
- 【求救】DataGrid新增空行后,保存按钮事件丢失,请问这是为什么?
- private class和public class还有class什么区别?
- 如何将页面中通过JS脚本获得的数据传到服务器上
- 在线等待:DataGrid中如何只指定某一个单元格有超级链接!
- 如何定时执行某一后台代函数
- asp与asp.net有什么区别?
- asp.net和xml的问题
- 看书遇到的问题--新手学习中
怎样选择 我的快捷方式是生成的,
ico文件要指定路径 ,
就是不会在快捷方式文件怎样来指定这个文件路径
谁知道用C#写一个DLL ,根据上面的方法,图标文件的路径指向它