using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace IE
{
public partial class Form1 : Form
{
private bool ie_Read = false;
public Form1()
{
InitializeComponent();
}
private void button1_Click(object sender, EventArgs e)
{
SHDocVw.InternetExplorer ie = new SHDocVw.InternetExplorer();
ie.DocumentComplete += ie_DocumentComplete;
ie.Navigate("http://www.baidu.com");
ie.Visible = true;
compWait();
mshtml.HTMLDocument doc = ie.Document;
doc.getElementById("kw").innerText = "c#";
doc.getElementById("su").click(); .
}
private void ie_DocumentComplete(object pDisp, ref object
.Net:C#实现百度自动搜索
最新推荐文章于 2024-07-01 09:34:20 发布