Prompt Dialog in Windows Forms

前端 未结 11 1444
名媛妹妹
名媛妹妹 2020-11-30 19:47

I am using System.Windows.Forms but strangely enough don\'t have the ability to create them.

How can I get something like a javascript prompt dialog, wi

11条回答
  •  情书的邮戳
    2020-11-30 20:16

    It's generally not a real good idea to import the VisualBasic libraries into C# programs (not because they won't work, but just for compatibility, style, and ability to upgrade), but you can call Microsoft.VisualBasic.Interaction.InputBox() to display the kind of box you're looking for.

    If you can create a Windows.Forms object, that would be best, but you say you cannot do that.

提交回复
热议问题