#pragma once

using namespace System;
using namespace System::ComponentModel;
using namespace System::Collections;
using namespace System::Windows::Forms;
using namespace System::Data;
using namespace System::Drawing;


namespace CppForm {

	/// <summary>
	/// Summary for MyDialog
	///
	/// WARNING: If you change the name of this class, you will need to change the
	///          'Resource File Name' property for the managed resource compiler tool
	///          associated with all .resx files this class depends on.  Otherwise,
	///          the designers will not be able to interact properly with localized
	///          resources associated with this form.
	/// </summary>
	public ref class MyDialog : public System::Windows::Forms::Form
	{
	public:
		// Properties for accessing control data
		property String^ Name
		{
			String^ get() { return nameBox->Text; }
			void set(String^ n) { nameBox->Text = n; }
		}

		property String^ Phone
		{
			String^ get() { return phoneBox ->Text; }
			void set(String^ p) { phoneBox ->Text = p; }
		}

		property int Dept
		{
			int get() { return deptCombo->SelectedIndex; }
			void set(int d) { deptCombo->SelectedIndex = d; }
		}

		MyDialog(void)
		{
			InitializeComponent();
			//
			//TODO: Add the constructor code here
			//
		}

	protected:
		/// <summary>
		/// Clean up any resources being used.
		/// </summary>
		~MyDialog()
		{
			if (components)
			{
				delete components;
			}
		}
	private: System::Windows::Forms::Label^  label1;
	private: System::Windows::Forms::Label^  label2;
	private: System::Windows::Forms::Label^  label3;
	private: System::Windows::Forms::TextBox^  nameBox;
	private: System::Windows::Forms::TextBox^  phoneBox;
	private: System::Windows::Forms::ComboBox^  deptCombo;
	private: System::Windows::Forms::Button^  OKButton;
	private: System::Windows::Forms::Button^  CancelButton;





	protected: 

	private:
		/// <summary>
		/// Required designer variable.
		/// </summary>
		System::ComponentModel::Container ^components;

#pragma region Windows Form Designer generated code
		/// <summary>
		/// Required method for Designer support - do not modify
		/// the contents of this method with the code editor.
		/// </summary>
		void InitializeComponent(void)
		{
			this->label1 = (gcnew System::Windows::Forms::Label());
			this->label2 = (gcnew System::Windows::Forms::Label());
			this->label3 = (gcnew System::Windows::Forms::Label());
			this->nameBox = (gcnew System::Windows::Forms::TextBox());
			this->phoneBox = (gcnew System::Windows::Forms::TextBox());
			this->deptCombo = (gcnew System::Windows::Forms::ComboBox());
			this->OKButton = (gcnew System::Windows::Forms::Button());
			this->CancelButton = (gcnew System::Windows::Forms::Button());
			this->SuspendLayout();
			// 
			// label1
			// 
			this->label1->AutoSize = true;
			this->label1->Location = System::Drawing::Point(41, 19);
			this->label1->Name = L"label1";
			this->label1->Size = System::Drawing::Size(38, 13);
			this->label1->TabIndex = 0;
			this->label1->Text = L"Name:";
			this->label1->TextAlign = System::Drawing::ContentAlignment::MiddleRight;
			// 
			// label2
			// 
			this->label2->AutoSize = true;
			this->label2->Location = System::Drawing::Point(38, 58);
			this->label2->Name = L"label2";
			this->label2->Size = System::Drawing::Size(41, 13);
			this->label2->TabIndex = 1;
			this->label2->Text = L"Phone:";
			this->label2->TextAlign = System::Drawing::ContentAlignment::MiddleRight;
			// 
			// label3
			// 
			this->label3->AutoSize = true;
			this->label3->Location = System::Drawing::Point(14, 95);
			this->label3->Name = L"label3";
			this->label3->Size = System::Drawing::Size(65, 13);
			this->label3->TabIndex = 2;
			this->label3->Text = L"Department:";
			this->label3->TextAlign = System::Drawing::ContentAlignment::MiddleRight;
			// 
			// nameBox
			// 
			this->nameBox->Location = System::Drawing::Point(103, 12);
			this->nameBox->Name = L"nameBox";
			this->nameBox->Size = System::Drawing::Size(145, 20);
			this->nameBox->TabIndex = 3;
			// 
			// phoneBox
			// 
			this->phoneBox->Location = System::Drawing::Point(103, 51);
			this->phoneBox->Name = L"phoneBox";
			this->phoneBox->Size = System::Drawing::Size(145, 20);
			this->phoneBox->TabIndex = 4;
			// 
			// deptCombo
			// 
			this->deptCombo->FormattingEnabled = true;
			this->deptCombo->Items->AddRange(gcnew cli::array< System::Object^  >(5) {L"IT", L"Admin", L"R&D", L"Catering", L"Manufacturing"});
			this->deptCombo->Location = System::Drawing::Point(103, 92);
			this->deptCombo->Name = L"deptCombo";
			this->deptCombo->Size = System::Drawing::Size(145, 21);
			this->deptCombo->TabIndex = 5;
			// 
			// OKButton
			// 
			this->OKButton->DialogResult = System::Windows::Forms::DialogResult::OK;
			this->OKButton->Location = System::Drawing::Point(80, 131);
			this->OKButton->Name = L"OKButton";
			this->OKButton->Size = System::Drawing::Size(75, 23);
			this->OKButton->TabIndex = 6;
			this->OKButton->Text = L"OK";
			this->OKButton->UseVisualStyleBackColor = true;
			// 
			// CancelButton
			// 
			this->CancelButton->DialogResult = System::Windows::Forms::DialogResult::Cancel;
			this->CancelButton->Location = System::Drawing::Point(173, 131);
			this->CancelButton->Name = L"CancelButton";
			this->CancelButton->Size = System::Drawing::Size(75, 23);
			this->CancelButton->TabIndex = 7;
			this->CancelButton->Text = L"Cancel";
			this->CancelButton->UseVisualStyleBackColor = true;
			// 
			// MyDialog
			// 
			this->AcceptButton = this->OKButton;
			this->AutoScaleDimensions = System::Drawing::SizeF(6, 13);
			this->AutoScaleMode = System::Windows::Forms::AutoScaleMode::Font;
			this->CancelButton = this->CancelButton;
			this->ClientSize = System::Drawing::Size(272, 166);
			this->Controls->Add(this->CancelButton);
			this->Controls->Add(this->OKButton);
			this->Controls->Add(this->deptCombo);
			this->Controls->Add(this->phoneBox);
			this->Controls->Add(this->nameBox);
			this->Controls->Add(this->label3);
			this->Controls->Add(this->label2);
			this->Controls->Add(this->label1);
			this->FormBorderStyle = System::Windows::Forms::FormBorderStyle::Fixed3D;
			this->Name = L"MyDialog";
			this->Text = L"Personal Details";
			this->ResumeLayout(false);
			this->PerformLayout();

		}
#pragma endregion
	};
}
