Hello
Is there a standard inputbox in the .Net framework (usable for C#), just like a modal MessageBox except it prompts for a string? I know that VB had an InputBox( ) method, but I don't see an equivalent, nor do I see how to modify the MessageBox to make it an InputBox. The ideal would be something like

string strResult = InputBox("Message here")
//strResult set to whatever the user typed

I could always just write my own inputbox form, but that's a lot of extra work for something that should be basic

Thanks
Mike

Re: InputBox by hirf-spam-me-here

hirf-spam-me-here
Fri May 14 08:19:08 CDT 2004

* "=?Utf-8?B?TWlrZQ==?=" <anonymous@discussions.microsoft.com> scripsit:
> Is there a standard inputbox in the .Net framework (usable for C#)

No.

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>

Re: InputBox by Marc

Marc
Fri May 14 16:29:49 CDT 2004

Add a reference to the Microsoft Visual Basic .NET Runtime and then the
following code will work:

string s = Microsoft.VisualBasic.Interaction.InputBox("x","y","z",0,0);

Microsoft.VisualBasic.Interaction.MsgBox(s,Microsoft.VisualBasic.MsgBoxStyle
.OKCancel,"Test");


--
Marc Butenko
mbutenko@bresnan.net



"Mike" <anonymous@discussions.microsoft.com> wrote in message
news:898EFABF-6751-47C0-BC51-2BCE84312796@microsoft.com...
> Hello,
> Is there a standard inputbox in the .Net framework (usable for C#), just
like a modal MessageBox except it prompts for a string? I know that VB had
an InputBox( ) method, but I don't see an equivalent, nor do I see how to
modify the MessageBox to make it an InputBox. The ideal would be something
like:
>
> string strResult = InputBox("Message here");
> //strResult set to whatever the user typed.
>
> I could always just write my own inputbox form, but that's a lot of extra
work for something that should be basic.
>
> Thanks,
> Mike