当前位置:编程学习 > C#/ASP.NET >>

C#中怎样循环打开一个不同参数的网址

 想要打开一个不同参数的网址 新手不怎么会求教!
比如
//
http://www.xxxxx.com/mm.asp?id=1
http://www.xxxxx.com/mm.asp?id=2
http://www.xxxxx.com/mm.asp?id=3
http://www.xxxxx.com/mm.asp?id=4
http://www.xxxxx.com/mm.asp?id=5

开始我就是直接这样写的
Process.Start("http://www.xxxxx.com/mm.asp?id=1");
Process.Start("http://www.xxxxx.com/mm.asp?id=1");
Process.Start("http://www.xxxxx.com/mm.asp?id=1");
后来太麻烦了 我想通过for循环来实现
最好有延时比如2秒钟之后打开id2 再过2秒打开id3 以此类推!
 System.Threading.Thread.Sleep(2000);
不知道怎么弄了! --------------------编程问答-------------------- 可以把网址放到list里面吗?帮顶。 --------------------编程问答--------------------
for (int i = 1; i <= 5; i++)
{
    Process.Start(string.Format("http://www.xxxxx.com/mm.asp?id={0}", i));
    System.Threading.Thread.Sleep(2000);
}
--------------------编程问答-------------------- 楼上的 方法可行  --------------------编程问答-------------------- 谢谢功能实现了! --------------------编程问答--------------------
补充:.NET技术 ,  C#
CopyRight © 2012 站长网 编程知识问答 www.zzzyk.com All Rights Reserved
部份技术文章来自网络,