简体   繁体   中英

Close this and send values to parent(Main) window

Deleted with some reasons. Admin may delete this issue, thank you.

From the error It seems like something from this TxtName.Text,TxtCode.Text,TxtPrice.Text,TxtMt.Text,TxtQty.Text,MyTotal is null. I recommend you to use breakpoint if you use Visual Studio (Code or any version of VS) and then you will able to see what exactly is null. Anyway, you also can make a filed in your class nullable like this: public string Text{ get; set; } public string Text{ get; set; } public string Text{ get; set; } => public string? Text{ get; set; } public string? Text{ get; set; }

Ok guys,

My fault, my mistake. I just forgot to type "this" between the brackets () frm.ShowDialog(this)

Now it works fine. Tnx for all answers.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM