foreach(System.Net.Cookie cookie in webIf.Cookie.GetCookies(new Uri("http://baidu.com"))) { string str= cookie.Name + "=" + cookie.Value; }