伤心酷龙 发表于 2006-6-11 10:36:00

轻松闲聊这 有懂.NET的高人不 呵呵 HELP

<p>~~</p><p>门外汉求助</p>

?止殇? 发表于 2006-6-11 10:36:00

<p>什么NET?</p><p>ASP.NET?</p>

Jessice 发表于 2006-6-11 10:37:00

不懂?

萧逸 发表于 2006-6-11 10:38:00

同是门外汉

伤心酷龙 发表于 2006-6-11 10:47:00

<p>源代码是CS结尾的&nbsp; 编译后成EXE的哦</p><p></p><p></p>

莫默 发表于 2006-6-11 10:49:00

正忙着考这门课,复习中

?止殇? 发表于 2006-6-11 10:49:00

哦,计算机操作系统的

萧逸 发表于 2006-6-11 10:49:00

CS是反恐么?

伤心酷龙 发表于 2006-6-11 10:50:00

<div class="msgheader">QUOTE:</div><div class="msgborder"><b>以下是引用<i>天颜儿</i>在2006-6-11 10:49:00的发言:</b><br/>正忙着考这门课,复习中</div><p>可以帮我看一段不到100行的源代码不</p><p>以前同学帮我写了可以用的程序&nbsp; 现在用不了了&nbsp; 不知道哪里不能用诶</p>

莫默 发表于 2006-6-11 10:50:00

反恐精英,红色警戒

莫默 发表于 2006-6-11 10:51:00

<div class="msgheader">QUOTE:</div><div class="msgborder"><b>以下是引用<i>伤心酷龙</i>在2006-6-11 10:50:00的发言:</b><br/><p>可以帮我看一段不到100行的源代码不</p><p>以前同学帮我写了可以用的程序&nbsp; 现在用不了了&nbsp; 不知道哪里不能用诶</p></div><p></p>恐怕能力不够

伤心酷龙 发表于 2006-6-11 10:52:00

<p>有注释的</p><p>using System;<br/>using System.Drawing;<br/>using System.Collections;<br/>using System.ComponentModel;<br/>using System.Windows.Forms;<br/>using System.Data;<br/>using System.Data.OleDb;<br/>using System.Net;<br/>using System.Diagnostics;</p><p>namespace DownLoadSoftware<br/>{<br/>&nbsp;/// &lt;summary&gt;<br/>&nbsp;/// Form1 的摘要说明。<br/>&nbsp;/// &lt;/summary&gt;<br/>&nbsp;public class MainForm : System.Windows.Forms.Form<br/>&nbsp;{<br/>&nbsp;&nbsp;private System.Windows.Forms.Panel panel1;<br/>&nbsp;&nbsp;private System.Windows.Forms.Label label3;<br/>&nbsp;&nbsp;private System.Windows.Forms.TextBox txtReferURL;<br/>&nbsp;&nbsp;private System.Windows.Forms.Label label4;<br/>&nbsp;&nbsp;private System.Windows.Forms.TextBox txtTureURL;<br/>&nbsp;&nbsp;private System.Windows.Forms.Label label1;<br/>&nbsp;&nbsp;private System.Windows.Forms.TextBox txtFlahGat;<br/>&nbsp;&nbsp;private System.Windows.Forms.TextBox txtAccessAdd;<br/>&nbsp;&nbsp;private System.Windows.Forms.Label label5;<br/>&nbsp;&nbsp;private System.Windows.Forms.Button btnAccessAdd;<br/>&nbsp;&nbsp;private System.Windows.Forms.Label label6;<br/>&nbsp;&nbsp;private System.Windows.Forms.TextBox txtFieldName;<br/>&nbsp;&nbsp;private System.Windows.Forms.Label label7;<br/>&nbsp;&nbsp;private System.Windows.Forms.TextBox txtTableName;<br/>&nbsp;&nbsp;private System.Windows.Forms.Button btnStart;<br/>&nbsp;&nbsp;private System.Windows.Forms.Button btnFlashGatAdd;<br/>&nbsp;&nbsp;private System.Windows.Forms.Label label2;<br/>&nbsp;&nbsp;private System.Windows.Forms.TextBox btnFormUrl;</p><p>&nbsp;&nbsp;string accessAdd;<br/>&nbsp;&nbsp;string tableName;<br/>&nbsp;&nbsp;string fieldName;</p><p>&nbsp;&nbsp;string formUrl;//<br/>&nbsp;&nbsp;string referUrl;<br/>&nbsp;&nbsp;string flashAdd;</p><p>&nbsp;&nbsp;string realUrl;</p><p>&nbsp;&nbsp;string selectSQL;<br/>&nbsp;&nbsp;string strConn;</p><p>&nbsp;&nbsp;Process flashGetP = new Process();</p><p>&nbsp;&nbsp;/// &lt;summary&gt;<br/>&nbsp;&nbsp;/// 必需的设计器变量。<br/>&nbsp;&nbsp;/// &lt;/summary&gt;<br/>&nbsp;&nbsp;private System.ComponentModel.Container components = null;</p><p>&nbsp;&nbsp;public MainForm()<br/>&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;//<br/>&nbsp;&nbsp;&nbsp;// Windows 窗体设计器支持所必需的<br/>&nbsp;&nbsp;&nbsp;//<br/>&nbsp;&nbsp;&nbsp;InitializeComponent();</p><p>&nbsp;&nbsp;&nbsp;//<br/>&nbsp;&nbsp;&nbsp;// TODO: 在 InitializeComponent 调用后添加任何构造函数代码<br/>&nbsp;&nbsp;&nbsp;//<br/>&nbsp;&nbsp;}</p><p>&nbsp;&nbsp;/// &lt;summary&gt;<br/>&nbsp;&nbsp;/// 清理所有正在使用的资源。<br/>&nbsp;&nbsp;/// &lt;/summary&gt;<br/>&nbsp;&nbsp;protected override void Dispose( bool disposing )<br/>&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;if( disposing )<br/>&nbsp;&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;&nbsp;if (components != null) <br/>&nbsp;&nbsp;&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;components.Dispose();<br/>&nbsp;&nbsp;&nbsp;&nbsp;}<br/>&nbsp;&nbsp;&nbsp;}<br/>&nbsp;&nbsp;&nbsp;base.Dispose( disposing );<br/>&nbsp;&nbsp;}</p><p>&nbsp;&nbsp;#region Windows 窗体设计器生成的代码<br/>&nbsp;&nbsp;/// &lt;summary&gt;<br/>&nbsp;&nbsp;/// 设计器支持所需的方法 - 不要使用代码编辑器修改<br/>&nbsp;&nbsp;/// 此方法的内容。<br/>&nbsp;&nbsp;/// &lt;/summary&gt;<br/>&nbsp;&nbsp;private void InitializeComponent()<br/>&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;this.panel1 = new System.Windows.Forms.Panel();<br/>&nbsp;&nbsp;&nbsp;this.btnFormUrl = new System.Windows.Forms.TextBox();<br/>&nbsp;&nbsp;&nbsp;this.label2 = new System.Windows.Forms.Label();<br/>&nbsp;&nbsp;&nbsp;this.btnFlashGatAdd = new System.Windows.Forms.Button();<br/>&nbsp;&nbsp;&nbsp;this.txtTableName = new System.Windows.Forms.TextBox();<br/>&nbsp;&nbsp;&nbsp;this.label7 = new System.Windows.Forms.Label();<br/>&nbsp;&nbsp;&nbsp;this.txtFieldName = new System.Windows.Forms.TextBox();<br/>&nbsp;&nbsp;&nbsp;this.label6 = new System.Windows.Forms.Label();<br/>&nbsp;&nbsp;&nbsp;this.btnAccessAdd = new System.Windows.Forms.Button();<br/>&nbsp;&nbsp;&nbsp;this.btnStart = new System.Windows.Forms.Button();<br/>&nbsp;&nbsp;&nbsp;this.label5 = new System.Windows.Forms.Label();<br/>&nbsp;&nbsp;&nbsp;this.txtAccessAdd = new System.Windows.Forms.TextBox();<br/>&nbsp;&nbsp;&nbsp;this.txtFlahGat = new System.Windows.Forms.TextBox();<br/>&nbsp;&nbsp;&nbsp;this.label1 = new System.Windows.Forms.Label();<br/>&nbsp;&nbsp;&nbsp;this.txtTureURL = new System.Windows.Forms.TextBox();<br/>&nbsp;&nbsp;&nbsp;this.label4 = new System.Windows.Forms.Label();<br/>&nbsp;&nbsp;&nbsp;this.txtReferURL = new System.Windows.Forms.TextBox();<br/>&nbsp;&nbsp;&nbsp;this.label3 = new System.Windows.Forms.Label();<br/>&nbsp;&nbsp;&nbsp;this.panel1.SuspendLayout();<br/>&nbsp;&nbsp;&nbsp;this.SuspendLayout();<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// panel1<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.panel1.BackColor = System.Drawing.Color.Gainsboro;<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.btnFormUrl);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.label2);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.btnFlashGatAdd);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.txtTableName);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.label7);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.txtFieldName);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.label6);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.btnAccessAdd);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.btnStart);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.label5);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.txtAccessAdd);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.txtFlahGat);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.label1);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.txtTureURL);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.label4);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.txtReferURL);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Controls.Add(this.label3);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Dock = System.Windows.Forms.DockStyle.Fill;<br/>&nbsp;&nbsp;&nbsp;this.panel1.Location = new System.Drawing.Point(0, 0);<br/>&nbsp;&nbsp;&nbsp;this.panel1.Name = "panel1";<br/>&nbsp;&nbsp;&nbsp;this.panel1.Size = new System.Drawing.Size(352, 285);<br/>&nbsp;&nbsp;&nbsp;this.panel1.TabIndex = 2;<br/>&nbsp;&nbsp;&nbsp;this.panel1.Paint += new System.Windows.Forms.PaintEventHandler(this.panel1_Paint);<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// btnFormUrl<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.btnFormUrl.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;<br/>&nbsp;&nbsp;&nbsp;this.btnFormUrl.Location = new System.Drawing.Point(8, 112);<br/>&nbsp;&nbsp;&nbsp;this.btnFormUrl.Name = "btnFormUrl";<br/>&nbsp;&nbsp;&nbsp;this.btnFormUrl.Size = new System.Drawing.Size(280, 21);<br/>&nbsp;&nbsp;&nbsp;this.btnFormUrl.TabIndex = 24;<br/>&nbsp;&nbsp;&nbsp;this.btnFormUrl.Text = "";<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// label2<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.label2.BackColor = System.Drawing.SystemColors.ActiveBorder;<br/>&nbsp;&nbsp;&nbsp;this.label2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;<br/>&nbsp;&nbsp;&nbsp;this.label2.Location = new System.Drawing.Point(8, 96);<br/>&nbsp;&nbsp;&nbsp;this.label2.Name = "label2";<br/>&nbsp;&nbsp;&nbsp;this.label2.Size = new System.Drawing.Size(128, 17);<br/>&nbsp;&nbsp;&nbsp;this.label2.TabIndex = 23;<br/>&nbsp;&nbsp;&nbsp;this.label2.Text = "来源地址:";<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// btnFlashGatAdd<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.btnFlashGatAdd.BackColor = System.Drawing.SystemColors.ActiveBorder;<br/>&nbsp;&nbsp;&nbsp;this.btnFlashGatAdd.FlatStyle = System.Windows.Forms.FlatStyle.Flat;<br/>&nbsp;&nbsp;&nbsp;this.btnFlashGatAdd.Location = new System.Drawing.Point(296, 248);<br/>&nbsp;&nbsp;&nbsp;this.btnFlashGatAdd.Name = "btnFlashGatAdd";<br/>&nbsp;&nbsp;&nbsp;this.btnFlashGatAdd.Size = new System.Drawing.Size(40, 23);<br/>&nbsp;&nbsp;&nbsp;this.btnFlashGatAdd.TabIndex = 22;<br/>&nbsp;&nbsp;&nbsp;this.btnFlashGatAdd.Text = "...";<br/>&nbsp;&nbsp;&nbsp;this.btnFlashGatAdd.Click += new System.EventHandler(this.btnFlashGatAdd_Click);<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// txtTableName<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.txtTableName.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;<br/>&nbsp;&nbsp;&nbsp;this.txtTableName.Location = new System.Drawing.Point(160, 64);<br/>&nbsp;&nbsp;&nbsp;this.txtTableName.Name = "txtTableName";<br/>&nbsp;&nbsp;&nbsp;this.txtTableName.Size = new System.Drawing.Size(128, 21);<br/>&nbsp;&nbsp;&nbsp;this.txtTableName.TabIndex = 21;<br/>&nbsp;&nbsp;&nbsp;this.txtTableName.Text = "";<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// label7<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.label7.BackColor = System.Drawing.SystemColors.ActiveBorder;<br/>&nbsp;&nbsp;&nbsp;this.label7.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;<br/>&nbsp;&nbsp;&nbsp;this.label7.Location = new System.Drawing.Point(160, 48);<br/>&nbsp;&nbsp;&nbsp;this.label7.Name = "label7";<br/>&nbsp;&nbsp;&nbsp;this.label7.Size = new System.Drawing.Size(128, 17);<br/>&nbsp;&nbsp;&nbsp;this.label7.TabIndex = 20;<br/>&nbsp;&nbsp;&nbsp;this.label7.Text = "表明";<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// txtFieldName<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.txtFieldName.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;<br/>&nbsp;&nbsp;&nbsp;this.txtFieldName.Location = new System.Drawing.Point(8, 64);<br/>&nbsp;&nbsp;&nbsp;this.txtFieldName.Name = "txtFieldName";<br/>&nbsp;&nbsp;&nbsp;this.txtFieldName.Size = new System.Drawing.Size(128, 21);<br/>&nbsp;&nbsp;&nbsp;this.txtFieldName.TabIndex = 19;<br/>&nbsp;&nbsp;&nbsp;this.txtFieldName.Text = "";<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// label6<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.label6.BackColor = System.Drawing.SystemColors.ActiveBorder;<br/>&nbsp;&nbsp;&nbsp;this.label6.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;<br/>&nbsp;&nbsp;&nbsp;this.label6.Location = new System.Drawing.Point(8, 48);<br/>&nbsp;&nbsp;&nbsp;this.label6.Name = "label6";<br/>&nbsp;&nbsp;&nbsp;this.label6.Size = new System.Drawing.Size(128, 17);<br/>&nbsp;&nbsp;&nbsp;this.label6.TabIndex = 18;<br/>&nbsp;&nbsp;&nbsp;this.label6.Text = "字段名字: ";<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// btnAccessAdd<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.btnAccessAdd.BackColor = System.Drawing.SystemColors.ActiveBorder;<br/>&nbsp;&nbsp;&nbsp;this.btnAccessAdd.FlatStyle = System.Windows.Forms.FlatStyle.Flat;<br/>&nbsp;&nbsp;&nbsp;this.btnAccessAdd.Location = new System.Drawing.Point(296, 16);<br/>&nbsp;&nbsp;&nbsp;this.btnAccessAdd.Name = "btnAccessAdd";<br/>&nbsp;&nbsp;&nbsp;this.btnAccessAdd.Size = new System.Drawing.Size(40, 21);<br/>&nbsp;&nbsp;&nbsp;this.btnAccessAdd.TabIndex = 17;<br/>&nbsp;&nbsp;&nbsp;this.btnAccessAdd.Text = "...";<br/>&nbsp;&nbsp;&nbsp;this.btnAccessAdd.Click += new System.EventHandler(this.btnAccessAdd_Click);<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// btnStart<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.btnStart.BackColor = System.Drawing.SystemColors.ActiveBorder;<br/>&nbsp;&nbsp;&nbsp;this.btnStart.FlatStyle = System.Windows.Forms.FlatStyle.Flat;<br/>&nbsp;&nbsp;&nbsp;this.btnStart.Location = new System.Drawing.Point(296, 48);<br/>&nbsp;&nbsp;&nbsp;this.btnStart.Name = "btnStart";<br/>&nbsp;&nbsp;&nbsp;this.btnStart.Size = new System.Drawing.Size(40, 184);<br/>&nbsp;&nbsp;&nbsp;this.btnStart.TabIndex = 16;<br/>&nbsp;&nbsp;&nbsp;this.btnStart.Text = "开始";<br/>&nbsp;&nbsp;&nbsp;this.btnStart.Click += new System.EventHandler(this.btnStart_Click);<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// label5<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.label5.BackColor = System.Drawing.SystemColors.ActiveBorder;<br/>&nbsp;&nbsp;&nbsp;this.label5.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;<br/>&nbsp;&nbsp;&nbsp;this.label5.Location = new System.Drawing.Point(8, 0);<br/>&nbsp;&nbsp;&nbsp;this.label5.Name = "label5";<br/>&nbsp;&nbsp;&nbsp;this.label5.Size = new System.Drawing.Size(128, 17);<br/>&nbsp;&nbsp;&nbsp;this.label5.TabIndex = 15;<br/>&nbsp;&nbsp;&nbsp;this.label5.Text = "Access数据库地址 :";<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// txtAccessAdd<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.txtAccessAdd.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;<br/>&nbsp;&nbsp;&nbsp;this.txtAccessAdd.Enabled = false;<br/>&nbsp;&nbsp;&nbsp;this.txtAccessAdd.Location = new System.Drawing.Point(8, 16);<br/>&nbsp;&nbsp;&nbsp;this.txtAccessAdd.Name = "txtAccessAdd";<br/>&nbsp;&nbsp;&nbsp;this.txtAccessAdd.Size = new System.Drawing.Size(280, 21);<br/>&nbsp;&nbsp;&nbsp;this.txtAccessAdd.TabIndex = 14;<br/>&nbsp;&nbsp;&nbsp;this.txtAccessAdd.Text = "";<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// txtFlahGat<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.txtFlahGat.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;<br/>&nbsp;&nbsp;&nbsp;this.txtFlahGat.Enabled = false;<br/>&nbsp;&nbsp;&nbsp;this.txtFlahGat.Location = new System.Drawing.Point(8, 248);<br/>&nbsp;&nbsp;&nbsp;this.txtFlahGat.Name = "txtFlahGat";<br/>&nbsp;&nbsp;&nbsp;this.txtFlahGat.Size = new System.Drawing.Size(280, 21);<br/>&nbsp;&nbsp;&nbsp;this.txtFlahGat.TabIndex = 13;<br/>&nbsp;&nbsp;&nbsp;this.txtFlahGat.Text = "";<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// label1<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.label1.BackColor = System.Drawing.SystemColors.ActiveBorder;<br/>&nbsp;&nbsp;&nbsp;this.label1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;<br/>&nbsp;&nbsp;&nbsp;this.label1.Location = new System.Drawing.Point(8, 232);<br/>&nbsp;&nbsp;&nbsp;this.label1.Name = "label1";<br/>&nbsp;&nbsp;&nbsp;this.label1.Size = new System.Drawing.Size(128, 17);<br/>&nbsp;&nbsp;&nbsp;this.label1.TabIndex = 12;<br/>&nbsp;&nbsp;&nbsp;this.label1.Text = "FlahGat程序地址";<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// txtTureURL<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.txtTureURL.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;<br/>&nbsp;&nbsp;&nbsp;this.txtTureURL.Location = new System.Drawing.Point(8, 200);<br/>&nbsp;&nbsp;&nbsp;this.txtTureURL.Name = "txtTureURL";<br/>&nbsp;&nbsp;&nbsp;this.txtTureURL.Size = new System.Drawing.Size(280, 21);<br/>&nbsp;&nbsp;&nbsp;this.txtTureURL.TabIndex = 11;<br/>&nbsp;&nbsp;&nbsp;this.txtTureURL.Text = "";<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// label4<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.label4.BackColor = System.Drawing.SystemColors.ActiveBorder;<br/>&nbsp;&nbsp;&nbsp;this.label4.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;<br/>&nbsp;&nbsp;&nbsp;this.label4.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));<br/>&nbsp;&nbsp;&nbsp;this.label4.Location = new System.Drawing.Point(8, 184);<br/>&nbsp;&nbsp;&nbsp;this.label4.Name = "label4";<br/>&nbsp;&nbsp;&nbsp;this.label4.Size = new System.Drawing.Size(128, 17);<br/>&nbsp;&nbsp;&nbsp;this.label4.TabIndex = 10;<br/>&nbsp;&nbsp;&nbsp;this.label4.Text = "真实的网址:";<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// txtReferURL<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.txtReferURL.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;<br/>&nbsp;&nbsp;&nbsp;this.txtReferURL.Location = new System.Drawing.Point(8, 152);<br/>&nbsp;&nbsp;&nbsp;this.txtReferURL.Name = "txtReferURL";<br/>&nbsp;&nbsp;&nbsp;this.txtReferURL.Size = new System.Drawing.Size(280, 21);<br/>&nbsp;&nbsp;&nbsp;this.txtReferURL.TabIndex = 9;<br/>&nbsp;&nbsp;&nbsp;this.txtReferURL.Text = "";<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// label3<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.label3.BackColor = System.Drawing.SystemColors.ActiveBorder;<br/>&nbsp;&nbsp;&nbsp;this.label3.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;<br/>&nbsp;&nbsp;&nbsp;this.label3.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));<br/>&nbsp;&nbsp;&nbsp;this.label3.Location = new System.Drawing.Point(8, 136);<br/>&nbsp;&nbsp;&nbsp;this.label3.Name = "label3";<br/>&nbsp;&nbsp;&nbsp;this.label3.Size = new System.Drawing.Size(128, 17);<br/>&nbsp;&nbsp;&nbsp;this.label3.TabIndex = 8;<br/>&nbsp;&nbsp;&nbsp;this.label3.Text = "伪装来源:";<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;// MainForm<br/>&nbsp;&nbsp;&nbsp;// <br/>&nbsp;&nbsp;&nbsp;this.AcceptButton = this.btnStart;<br/>&nbsp;&nbsp;&nbsp;this.AutoScaleBaseSize = new System.Drawing.Size(6, 14);<br/>&nbsp;&nbsp;&nbsp;this.ClientSize = new System.Drawing.Size(352, 285);<br/>&nbsp;&nbsp;&nbsp;this.Controls.Add(this.panel1);<br/>&nbsp;&nbsp;&nbsp;this.MaximizeBox = false;<br/>&nbsp;&nbsp;&nbsp;this.Name = "MainForm";<br/>&nbsp;&nbsp;&nbsp;this.Text = "获取软件真实地址";<br/>&nbsp;&nbsp;&nbsp;this.panel1.ResumeLayout(false);<br/>&nbsp;&nbsp;&nbsp;this.ResumeLayout(false);</p><p>&nbsp;&nbsp;}<br/>&nbsp;&nbsp;#endregion</p><p>&nbsp;&nbsp;/// &lt;summary&gt;<br/>&nbsp;&nbsp;/// 应用程序的主入口点。<br/>&nbsp;&nbsp;/// &lt;/summary&gt;<br/>&nbsp;&nbsp;<br/>&nbsp;&nbsp;static void Main() <br/>&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;Application.Run(new MainForm());<br/>&nbsp;&nbsp;}</p><p>&nbsp;&nbsp;private void panel1_Paint(object sender, System.Windows.Forms.PaintEventArgs e)<br/>&nbsp;&nbsp;{<br/>&nbsp;&nbsp;<br/>&nbsp;&nbsp;}</p><p>&nbsp;&nbsp;private void btnStart_Click(object sender, System.EventArgs e)<br/>&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;flashGetP.StartInfo.FileName = "cmd.exe";<br/>&nbsp;&nbsp;&nbsp;//flashGetP.StartInfo.FileName= flashAdd +" "+realUrl;<br/>&nbsp;&nbsp;&nbsp;flashGetP.StartInfo.UseShellExecute = false;<br/>&nbsp;&nbsp;&nbsp;flashGetP.StartInfo.RedirectStandardInput = true;<br/>&nbsp;&nbsp;&nbsp;flashGetP.StartInfo.CreateNoWindow = true;<br/>&nbsp;&nbsp;&nbsp;flashGetP.Start();</p><p>&nbsp;&nbsp;&nbsp;accessAdd = txtAccessAdd.Text;<br/>&nbsp;&nbsp;&nbsp;tableName = txtTableName.Text;<br/>&nbsp;&nbsp;&nbsp;fieldName=txtFieldName.Text;</p><p>&nbsp;&nbsp;&nbsp;referUrl= txtReferURL.Text;<br/>&nbsp;&nbsp;&nbsp;flashAdd = txtFlahGat.Text;</p><p>&nbsp;&nbsp;&nbsp;selectSQL= "Select * From "+ tableName ;<br/>&nbsp;&nbsp;&nbsp;strConn="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + accessAdd;</p><p>&nbsp;&nbsp;&nbsp;<br/>&nbsp;&nbsp;&nbsp;<br/>&nbsp;&nbsp;&nbsp;OleDbConnection oleConn = new OleDbConnection();<br/>&nbsp;&nbsp;&nbsp;oleConn.ConnectionString= strConn;</p><p>&nbsp;&nbsp;&nbsp;OleDbDataAdapter OleDA = new OleDbDataAdapter();<br/>&nbsp;&nbsp;&nbsp;OleDA.SelectCommand = new OleDbCommand(selectSQL, oleConn);<br/>&nbsp;&nbsp;&nbsp;OleDbCommandBuilder oleCB = new OleDbCommandBuilder(OleDA);</p><p>&nbsp;&nbsp;&nbsp;DataSet ds = new DataSet();</p><p><br/>&nbsp;&nbsp;&nbsp;try&nbsp;<br/>&nbsp;&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;&nbsp;oleConn.Open();<br/>&nbsp;&nbsp;&nbsp;&nbsp;OleDA.Fill(ds, tableName);<br/>&nbsp;&nbsp;&nbsp;}<br/>&nbsp;&nbsp;&nbsp;catch<br/>&nbsp;&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;&nbsp;MessageBox.Show("数据源错误!!");<br/>&nbsp;&nbsp;&nbsp;&nbsp;oleConn.Close();<br/>&nbsp;&nbsp;&nbsp;&nbsp;return;<br/>&nbsp;&nbsp;&nbsp;}</p><p>&nbsp;&nbsp;&nbsp;<br/>&nbsp;&nbsp;&nbsp;DataTable dt = ds.Tables;<br/>&nbsp;&nbsp;&nbsp;int rows = dt.Rows.Count;;</p><p>&nbsp;&nbsp;&nbsp;for(int i= 0; i&lt;rows; i++)<br/>&nbsp;&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;&nbsp;DataRow dr = dt.Rows;<br/>&nbsp;&nbsp;&nbsp;&nbsp;formUrl = (string) dr;</p><p>&nbsp;&nbsp;&nbsp;&nbsp;//btnFormUrl.Text= formUrl;</p><p>&nbsp;&nbsp;&nbsp;&nbsp;realUrl = GetRealURL(referUrl,formUrl);<br/>&nbsp;&nbsp;&nbsp;&nbsp;if (realUrl !=null)<br/>&nbsp;&nbsp;&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;dr= realUrl;</p><p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(txtFlahGat.ToString() != "")<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;flashGetP.StandardInput.WriteLine(flashAdd +" "+realUrl);<br/>&nbsp;&nbsp;&nbsp;&nbsp;}</p><p>&nbsp;&nbsp;&nbsp;&nbsp;//txtTureURL.Text=realUrl;<br/>&nbsp;&nbsp;&nbsp;}</p><p>&nbsp;&nbsp;&nbsp;OleDA.Update(ds, tableName);</p><p>&nbsp;&nbsp;&nbsp;oleConn.Close();<br/>&nbsp;&nbsp;&nbsp;flashGetP.StandardInput.WriteLine("exit");<br/>&nbsp;&nbsp;&nbsp;btnStart.Text="处理完毕";<br/>&nbsp;&nbsp;}</p><p>&nbsp;&nbsp;public string GetRealURL(string referURl,string formURL)<br/>&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;if (referURl.Length&lt;10)<br/>&nbsp;&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;&nbsp;//MessageBox.Show("URL不正确吧","URL不正确");<br/>&nbsp;&nbsp;&nbsp;&nbsp;return null;<br/>&nbsp;&nbsp;&nbsp;}<br/>&nbsp;&nbsp;&nbsp;else<br/>&nbsp;&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;&nbsp;HttpWebRequest myReq = (HttpWebRequest)WebRequest.Create(formURL);<br/>&nbsp;&nbsp;&nbsp;&nbsp;myReq.Referer=referURl;</p><p>&nbsp;&nbsp;&nbsp;&nbsp;try<br/>&nbsp;&nbsp;&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;HttpWebResponse myres=(HttpWebResponse)myReq.GetResponse();<br/>&nbsp;&nbsp;&nbsp;&nbsp;}<br/>&nbsp;&nbsp;&nbsp;&nbsp;catch<br/>&nbsp;&nbsp;&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return null;<br/>&nbsp;&nbsp;&nbsp;&nbsp;}</p><p>&nbsp;&nbsp;&nbsp;&nbsp;bool hasChanged = (myReq.RequestUri != myReq.Address);<br/>&nbsp;&nbsp;&nbsp;&nbsp;string geturl;<br/>&nbsp;&nbsp;&nbsp;&nbsp;if (hasChanged)<br/>&nbsp;&nbsp;&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;geturl=myReq.Address.ToString();<br/>&nbsp;&nbsp;&nbsp;&nbsp;}<br/>&nbsp;&nbsp;&nbsp;&nbsp;else<br/>&nbsp;&nbsp;&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;geturl=myReq.RequestUri.ToString();<br/>&nbsp;&nbsp;&nbsp;&nbsp;}<br/>&nbsp;&nbsp;&nbsp;&nbsp;return geturl ;<br/>&nbsp;&nbsp;&nbsp;}<br/>&nbsp;&nbsp;}<br/>&nbsp;&nbsp;private void btnAccessAdd_Click(object sender, System.EventArgs e)<br/>&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;OpenFileDialog ofd = new OpenFileDialog();<br/>&nbsp;&nbsp;&nbsp;ofd.Filter="Access数据库|*.mdb";<br/>&nbsp;&nbsp;&nbsp;if(ofd.ShowDialog() == DialogResult.OK)<br/>&nbsp;&nbsp;&nbsp;&nbsp;txtAccessAdd.Text=ofd.FileName.ToString();</p><p>&nbsp;&nbsp;&nbsp;btnStart.Focus();<br/>&nbsp;&nbsp;}</p><p>&nbsp;&nbsp;private void btnFlashGatAdd_Click(object sender, System.EventArgs e)<br/>&nbsp;&nbsp;{<br/>&nbsp;&nbsp;&nbsp;OpenFileDialog ofd = new OpenFileDialog();<br/>&nbsp;&nbsp;&nbsp;ofd.Filter="FlashGat|*.exe";<br/>&nbsp;&nbsp;&nbsp;if(ofd.ShowDialog() == DialogResult.OK)<br/>&nbsp;&nbsp;&nbsp;&nbsp;txtFlahGat.Text=ofd.FileName.ToString();<br/>&nbsp;&nbsp;&nbsp;btnStart.Focus();<br/>&nbsp;&nbsp;}<br/>&nbsp;}<br/>}<br/></p>

伤心酷龙 发表于 2006-6-11 10:53:00

呵呵&nbsp; 长了点&nbsp;&nbsp; 郁闷&nbsp;&nbsp; 吓倒MM了

だ风云だ 发表于 2006-6-11 10:57:00

应该有人懂的,可能现在都不在吧,LZ 再等等吧

?止殇? 发表于 2006-6-11 10:58:00

发棵,这是才100行的么?

飘渺尘爱 发表于 2006-6-11 11:00:00

晕了

伤心酷龙 发表于 2006-6-11 11:00:00

<p></p><p>刚刚放在FP里看了下&nbsp; 465行</p>

萧逸 发表于 2006-6-11 11:02:00

<p>我帮不上</p><p>我闪</p>

莫默 发表于 2006-6-11 11:04:00

<p>我们所学重点在于数据库的连接。。。简单啊</p><p>好多System.Windows.Forms。。。真陌生的代码</p>

伤心酷龙 发表于 2006-6-11 11:08:00

<p>连接的是ACCESS数据库</p><p></p><p><br/></p>
页: [1] 2
查看完整版本: 轻松闲聊这 有懂.NET的高人不 呵呵 HELP