Quantcast
Channel: Windows Forms General forum
Viewing all articles
Browse latest Browse all 12583

Dynamic Button Creation (HowTo ?)

$
0
0

Hello there.
I am using VS 2010, C++ WIndows Forms Applic.

I want to create a buttonB using already created buttonA.
and then create ButtonC, using buttonB.


	private: System::Void button1_Click(System::Object^  sender, System::EventArgs^  e) 
	{
	this->SuspendLayout();
	Button^ ButtonNew = gcnew Button;
	ButtonNew->Location = System::Drawing::Point(200,200);
	ButtonNew->Size = System::Drawing::Size( 75, 125 );
	ButtonNew->Text = "OK";
	this->Controls->Add(ButtonNew);
	this->ResumeLayout();
	}
This is how I create buttonB using already created buttonA.
How can I create event for buttonB?????



Viewing all articles
Browse latest Browse all 12583

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>