View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
FSt1 FSt1 is offline
external usenet poster
 
Posts: 3,942
Default Macro to add data

hi
assuming that you are using a standard userform from the vb editor......
you will need a line like this for each of your controls that you have
entered data into and want that data to go to the sheet.

Range("A65000").End(xlUp).Offset(1, 0).Value = TextBox1.Value

then to clear the form you would need a line like this for each control to
clear the control......

TextBox1.Value = ""

i assume that all these lines would go into a commandbutton_click event.

post back if questions.

Regards
FSt1
"Arlene" wrote:

I want a macro to carry my information from a form into a spreadsheet. The
data needs to go into the first line of the spreadsheet each time new data is
entered on the form. In the spreadsheet itself, I need to add a row, moving
existing data into the rows below, and add whatever new data id obtained from
the form. Once that is done, I need to clear the form.
--
Arlene