Extremely basic ? about VS 2005.
-
I am currently familiar w/ VC 6.0. I downloaded the trial of VS 2005 Express (just C++) to try out. I created a new "Windows Forms App" and added a couple of controls. When I add an event handler (such as _Click for a button), the IDE creates the entry in the .h file, but I don't see a .cpp file. Here's what's in the .h file:
private: System::Void button1_Click(....
I don't think I am now supposed to put my code in the .h file, so... 1) am I supposed to create the .cpp file myself? or 2) did I miss something such that the .cpp file did not get created when it should have? I know this is really simplistic, and I feel like I'm just overlooking something, but some advice to point me in the right direction would be nice. Thanks. PS: One other simple thing. I figured out the following to do a simple MessageBox:
System::Windows::Forms::MessageBox::Show("Button pressed!");
Surely there's a shorter way...! Thanks again.
-
I am currently familiar w/ VC 6.0. I downloaded the trial of VS 2005 Express (just C++) to try out. I created a new "Windows Forms App" and added a couple of controls. When I add an event handler (such as _Click for a button), the IDE creates the entry in the .h file, but I don't see a .cpp file. Here's what's in the .h file:
private: System::Void button1_Click(....
I don't think I am now supposed to put my code in the .h file, so... 1) am I supposed to create the .cpp file myself? or 2) did I miss something such that the .cpp file did not get created when it should have? I know this is really simplistic, and I feel like I'm just overlooking something, but some advice to point me in the right direction would be nice. Thanks. PS: One other simple thing. I figured out the following to do a simple MessageBox:
System::Windows::Forms::MessageBox::Show("Button pressed!");
Surely there's a shorter way...! Thanks again.
This is the VC++ forum, your questions are about C++/CLI, for which there is the C++/CLI forum.
David Fleming wrote:
am I supposed to create the .cpp file myself?
Guess so. I tried it and got the same result.
David Fleming wrote:
PS: One other simple thing. I figured out the following to do a simple MessageBox:
Provided you have
using namespace System::Windows::Forms
in the translation unit, you can simply doMessageBox::Show(...)
Regards Senthil _____________________________ My Blog | My Articles | WinMacro -
This is the VC++ forum, your questions are about C++/CLI, for which there is the C++/CLI forum.
David Fleming wrote:
am I supposed to create the .cpp file myself?
Guess so. I tried it and got the same result.
David Fleming wrote:
PS: One other simple thing. I figured out the following to do a simple MessageBox:
Provided you have
using namespace System::Windows::Forms
in the translation unit, you can simply doMessageBox::Show(...)
Regards Senthil _____________________________ My Blog | My Articles | WinMacroTry in the CLI u might get the proper response as people here are yet on vc++:cool: Vikas Amin Embin Technology Bombay vikas.amin@embin.com
-
Try in the CLI u might get the proper response as people here are yet on vc++:cool: Vikas Amin Embin Technology Bombay vikas.amin@embin.com
Crap! I thought CLI was for regular (non-Visual) C++... where's that then? :~ Thanks! ;-) BTW, David, I don't know how to do it in C++, but in C# you used:
using System.Windows.Forms;
It should be quite similar... ;) Lord Kixdemp www.SulfurMidis.com www.SulfurSoft.tk [ftp://][http://][hotline://]tsfc.ath.cx