- Katılım
- 7 Mart 2012
- Mesajlar
- 12,586
- Konu Yazar
- #1
1 adet toolStripTextBox
2 adet richTextBox
2 adet richTextBox
Kod:
string text = this.richTextBox2.Text;
string str2 = this.richTextBox1.Text;
char ch = Convert.ToChar(text.Substring(0, 1));
string newValue = "');\ninsert into [" + this.toolStripTextBox1.Text + "] values ('";
this.richTextBox1.Text = "insert into [" + this.toolStripTextBox1.Text + "] values ('";
this.richTextBox1.Text = this.richTextBox1.Text + text.Replace("\n", newValue);
this.richTextBox1.Text = this.richTextBox1.Text.Replace("\t", "','");
this.richTextBox1.Text = this.richTextBox1.Text.Replace("('',", "(");
this.richTextBox1.Text = this.richTextBox1.Text + "');";
if (this.richTextBox1.Text.Substring(this.richTextBox1.Text.Length - 4, 1) == "\n") // [url]www.neronlineworld.com[/url]
{
this.richTextBox1.Text = this.richTextBox1.Text.Remove(this.richTextBox1.Text.Length - 4, 1);
}