title: vb code to create excel sheet, add button to it and assign a macro to send mail
body: <p>This is my first vb code.Never knew anything about vb except its name. didn't even know dim is used to declare variables in vb!!! Please help me with creation of the batch process..</p>
  
  <p>I need to create a batch process which creates an excel sheet, imports values from flat into the excel sheet and sent as an attachment in an email.
  The excel sheet should also have a command button to send mail to the final recipient(xyz@gmail.com).</p>
  
  <p>Values have to be imported into various columns depending on an 'id' field in flat file. All rows present in the flat file with same id are to be imported in one excel sheet. This excel sheet is to be sent as an attachment in a mail. The mail recipient has to read excel, put in comments(a column in excel) using drop down list, save and click a button(Forward To XYZ) to send the excel sheet to final recipient(xyz@gmail.com) with the saved comment.
  The creation of excel sheet, button and then a macro to send mail on button click is to be done using vb.net.
  please specify the namespaces imported(in VS 2008)</p>
  
  <p>Consider this as the flat file data:  </p>
  
  <pre>abc  cdsmdjn 1 337666746     
  def  odkiejr 1 234585780   
  ghi  kdjfjfn 1 287474675   
  jkl  nfjjwke 2 455767875  
  mno  jfhfiee 3 039484764</pre>  
  
  <p>Values have to be separated using the third column. Hence, first three rows come in one excel workbook, 4th row in second workbook and 5th row in third book.</p>