title: Uploading multiple photos to folder and their paths to database through a single click
body: <p>I am having trouble with making logic for uploading three picture at the same time to database and their paths to database.
  i am using three textboxes for the images titles, 3 file upload buttons and a submit button.</p>
  
  <p>here is what i have tried so far:</p>
  
  <pre><code> protected void Button1_Click1(object sender, EventArgs e)
       {
           using (Property_dbDataContext context = new Property_dbDataContext())
           {
  
                   Property_image image = new Property_image();
  
  
                   image.prop_id = "1";
                       image.image_title = _ImageTitle1.Text;
                       image.image_title = _ImageTitle2.Text;
                       image.image_title = _ImageTitle3.Text;
  
                       string imagename = _PictureUpload1.FileName.ToString();
                       string imagepath = "wp-content/uploads/2013/05/" + imagename;
                       _PictureUpload1.SaveAs(Server.MapPath(imagepath));
                       image.image_url = imagepath.ToString();
  
                       context.Property_images.InsertOnSubmit(image);
                       context.SubmitChanges();         
  
           }
       }
  </code></pre>
  
  <p>The interface:
  <img src="https://i.stack.imgur.com/ah57P.png" alt="enter image description here"></p>
  
  <p>The fileuploader names are: _PictureUploader1, _PictureUploader2, _PictureUploader3
  The textboxes names are: _ImageTitle1, _ImageTitle2, _ImageTitle3
  The button name: button1</p>
  
  <p>i am not getting whether which loop to use or not use a loop at all.</p>
  
  <p>i want to store the record in different rows like this:</p>
  
  <pre><code>prop_id | image_title | Image_url
  1       | car         | wp-content/uploads/2013/05/car.jpg
  1       | bus         | wp-content/uploads/2013/05/bus.jpg
  1       | truck       | wp-content/uploads/2013/05/truck.jpg
  </code></pre>