0
私はいくつかのチェックボックスを基本的に持っています。チェックボックス1がチェックされている場合、私は文字列を変数に代入します。だから私はテキストファイルに保存される独自の文字列を持つ各チェックボックスを持っています。checkbox_checkedchangeとボタンをクリックしてイベントのヘルプ
ボタンをクリックした場合のみ、これらの文字列がテキストファイルに保存されます。
私はこれでした..私はもしelse文をクリックして、ボタン上に追加する必要があると思う
protected void CheckBox1_CheckedChanged(object sender, EventArgs e)
{
string masterbuild1 = "Exec_Build_starting_mail";
}
protected void Button1_Click(object sender, EventArgs e)
{
// create a writer and open the file
TextWriter tw = new StreamWriter("C:/Documents and
Settings/Cha57061/Desktop/New Folder/C#/new/build.txt");
// should i have a if statement like:
if CheckBox1_CheckedChanged = true
{
tw.Write(masterbuild1);
}
// close the stream
tw.Close();
を事前に感謝は
ありがとうございました。私は考え出した。 on buttonclick event if(checkbox1.checked){何かをする};それはうまくいく – jeremychan