when initially creating the string, try this...
then you can check if the string is empty or not like this....VB Code:
[Color=Blue]string[/color] MyString = [Color=Blue]string[/color].Empty;
VB Code:
[Color=Blue]private[/color] [Color=Blue]void[/color] button1_Click([Color=Blue]object[/color] sender, System.EventArgs e) { [Color=Blue]string[/color] MyString = [Color=Blue]string[/color].Empty; [Color=Blue]if[/color](MyString==[Color=Blue]string[/color].Empty) { MessageBox.Show("it's empty"); } [Color=Blue]else [/color] { MessageBox.Show("it's NOT empty"); } }





Reply With Quote