@tinstaafl
Ok Thank You Very Much for Given Me Time And Solved My Problem

I think Line Numer 38 as con.open() and Line number 42
com.CommandType = CommandType.StoredProcedure;
should be after Parameters it should after line no 40 as below

SqlCommand("insertguestinfo", con);

com.Parameters.Add(new SqlParameter("@guest_ID",gst_info.Guest_id));
com.Parameters.Add(new SqlParameter("@first_name", gst_info.First_name));
com.Parameters.Add(new SqlParameter("@Last_name", gst_info.Last_name));
com.Parameters.Add(new SqlParameter("@Gender_ID", gst_info.Gender_status));
com.Parameters.Add(new SqlParameter("@Martial_ID",gst_info.Martial_status));                    com.Parameters.Add(new SqlParameter("@phone_number",gst_info.Phone_numb ));
com.Parameters.Add(new SqlParameter("@email_address",gst_info.Email_address ));
     con.Open();
     com.CommandType = CommandType.StoredProcedure;
     com.ExecuteNonQuery();
                con.Close();

Hope This Help You.....................

 //Write/Save File as RichText 
  private void btnwrite_Click(object sender, EventArgs e)
        {

            richTextBox1.ForeColor = Color.Red;
            richTextBox1.Font = new Font(richTextBox1.Font, FontStyle.Bold);
            richTextBox1.SaveFile(@"D:/myFile.rtf", RichTextBoxStreamType.RichText);
        }
        // Read File from D Drive as RichText
 private void btnRead_Click(object sender, EventArgs e)
        {
            richTextBox2.LoadFile(@"D:/myFile.rtf", RichTextBoxStreamType.RichText);

        }
        //Show RichText in Label
                           // Here is Problem I show text but not forecolor and not font
         private void btnshowtext_Click(object sender, EventArgs e)
        {

            label1.Text = richTextBox2.Text;
            label1.ForeColor = richTextBox2.ForeColor;
            label1.Font = richTextBox2.Font;
        }

I hope You Understood my Problem Please Help

@tinstaafl
Ihave already do that

label1.text = RitchTextBox1.text;
Label1.ForeColor = RitchTextBox1.ForeColor
Label1.Font = RitchTextBox1.Font;

But It Could not Work.Text show in label but it font and color doesn't show.Please Help

How Can Transferdata from RitchTextBox to Label with all Formats. i.e RitchTextBox's Text Color ,Font,FontStyle

This is My Code I could not fingur out the code for Next Picture in my array

      int imagenume;
      string[] imagepat = new string[imagenum];

     private void button3_Click(object sender, EventArgs e)
            {  

            OpenFileDialog open = new OpenFileDialog();
            open.Multiselect = true;
            if (open.ShowDialog() != DialogResult.Cancel)
            {
                for (imagenum =0; imagenum < imagepat.Length; imagenum++)
                {
                    lblcounter.Text = imagenum.ToString();
                    imagepat[imagenum] = open.FileName;
                    myimage = Image.FromFile(imagepat[imagenum]);
                    pictureBox1.Image = myimage;

                }

            }
        }

My Question in how can code in Next Button For Next Picture Show in Picture Box
Thanks&Regards
Yousafc#

Send Value from Form1 to Form2 You can use this code
In Form1

private void btnsendvalue_Click(object sender, EventArgs e)
        {

           Form2 form2 = new Form2(TextBox1.Text +"SurName "+ TextBox2.Text);
            form2.ShowDialog();
        }

and in Form2 use this code

public Form2 (string text)
        {
            InitializeComponent();
            label1.Text = text;
        }

Hope this Help You

I am Creating Attendance windows form I have two lables 1-current time 2- time i fixed ie 8:00:00am.i want if student came to school before 5 minutes It show message you came before 5minutes and if student came after time 5 minutes late it show student came 5 minutes late
Thanks&Regards

A database is a collection of data that is organized so that its contents can easily be access, manage, and update.

Ap0ca1ypse's code is perfect for this purpos, but if you don't want to use these code because of troubling keypress Event "YOu Can Use this simple code for Text validation "

 private void button8_Click(object sender, EventArgs e)
        {
            try
            {
                if (Convert.ToInt32(textbox1.Text) < 0)
                {
                    MessageBox.Show("Please Enter Correct Value !", "Information");
                    textbox1.Text = "0";
                    textbox1.Focus();
                }
            }
            catch
            {
                MessageBox.Show("Enter Only Numaric Value !", "Information");
                textbox1.Text = "0";
                textbox1.Focus();
            }
        }

I hope this will help You.

    private void Form1_Load(object sender, EventArgs e)
            {
            //SQL Connection String Modify with Your Data Source and DataBase Name
                string con = "Data Source = Flower-PC;Initial Catalog = Schooldata ; Integrated Security = True";
                // Create Connection 
                SqlConnection cn = new SqlConnection(con);              
               DataTable dt = new DataTable();
                cn.Open();//Sql Conneciton Open
                               // Your Sql Command ,Modify it with Your Query
        SqlCommand cmd = new SqlCommand("Select StudentName from Studentinfo", cn);
                SqlDataAdapter data = new SqlDataAdapter(cmd);
                data.Fill(dt);
                comboBox1.DataSource = dt;
                            //Modify This String with Your Column Name
                comboBox1.DisplayMember = "Studentname";
                comboBox1.ValueMember = "Studentname";

            }

Hope This Help You.

Now I Not UnderStand You.What Do You Want?
Do You Want Show All TextBoxes Number How Many User Created Dynamically Or What user Write in said TextBox.Tell us Clearly.

Draw a Panel and a Text box and set its property multiline = true in your Form and modify the line no "32" to

this.panel1.Controls.Add(txtTemp);      

Now write loop code in button2_click

private void button2_Click(object sender, EventArgs e)
        {

            foreach (Control cont in panel1.Controls )
            {
                if (cont is TextBox)
                {
                    //txtresult is your textbox for result of all textbox
                    txtresult.AppendText(((TextBox)cont).Text);
                }                    
                }
        }

Hope this help you.

AoA
I am Inserting Data From DataGridview to Sql2005.It Insert Perfectely.
The Problem is that when i insert record it alway insert 0 row with my other rows
The Code is below

            try
            {

                string con = "Data Source = FLOWER-PC;Database = MYFIRSTDATABASE;Integrated Security = True";
                SqlConnection cn = new SqlConnection(con);
                cn.Open();
                SqlCommand cmd = new SqlCommand();
                cmd.Connection = cn;                
                for (int i =0; i < dataGridView1.Rows.Count; i++)
                {
                    cmd.CommandText = "INSERT INTO PERSONALINFORMATION(pid,firstname) values('"
                                        + dataGridView1.Rows[i].Cells["pid"].Value + "','"
                                        + dataGridView1.Rows[i].Cells["firstname"].Value + "')";    
                        cmd.ExecuteNonQuery();

                }
                cn.Close();
                MessageBox.Show("Record Inserted Successfully");      
            }
            catch (Exception ex) { MessageBox.Show(ex.Message); }

Please Help and send me its Solution as soon as possible

yes ChrisHunter You understood . Now Please Tell Me How can i do this

 Private string _firstname;
    public string FirstName
    {
    get{ return _firstname;} set {_firstname = Value}

    }

how can i store this value in my database

How to use c sharp properties and after get value save in sql database.

Please tell me deeply about classes and objects
My Question are:
What is class?
Why we use class?
How can we use class?
what do help class?
Please tell me and also tell how can I learn about class?

Please tell me,Why Microsoft choose name operating system (Windows).Please no body reject this question.I know it is not related c#,But it is related IT world.

No But in My .net the reference of Direct show is not exist

Hello In My Visual C# 2008.Its References has not Direct show in .Net Reference .
Tell Me how I can Install Direct show library in c sharp.net

Hello Hi
when I deploy my project using set up wizard the error show and my deployment set up stopped,Please Help for this Immediately.
The Error Is
[COLOR="Red"]The following files may have dependencies that cannot be determined automatically,
Please confirm that all dependencies have been added to the project
C:\windows\system32\wmp.dll
[/COLOR]

Any one tell me how to make own flash player in c sharp

But I want make My Own Flash Player as Flv player In C#.
Have any have code for this

thanks nick.crane ,You solved the problem .

and Thanks for Lamouche and Mitja Bonca

How I perform with iteration
As a Loop

Please tell me how to make flash player in c sharp.I have no Idea.Please tell me about to flash in c sharp 2008.

I have a form of c sharp, In winch I have Five Button.I want hit all buttons one by one dynamically.
Please send me complete Code of c sharp.

But Mitja I want set back ground image of media player not a form

Hello All
I just made a simple media player in c sharp.My code is
[CODE]axWindowsMediaPlayer1.ContainingControl.BackgroundImage = Properties.Resources.Image1 ;[/CODE]
But it is not working..................Please tell me.
Thanks Advance

Any one can help me ?????//