Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Updating a Data List

Would someone be so kind to provide a VBA code I can assign to a command
button on a user form that will transfer the data just entered in the form's
fields to a list located on a separate worksheet within the same workbook? I
would like each click of the button to update the list by adding new row and
then to clear the user form preparing it for new data entry. I don't want to
use MS Access for that function.

Thanks a lot!


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,979
Default Updating a Data List

There's a sample file here that stores data on a hidden worksheet:

http://www.contextures.com/excelfiles.html#UserForm

Under 'UserForms', look for 'Parts Database'

Plamen A. Vachovski wrote:
Would someone be so kind to provide a VBA code I can assign to a command
button on a user form that will transfer the data just entered in the form's
fields to a list located on a separate worksheet within the same workbook? I
would like each click of the button to update the list by adding new row and
then to clear the user form preparing it for new data entry. I don't want to
use MS Access for that function.



--
Debra Dalgleish
Excel FAQ, Tips & Book List
http://www.contextures.com/tiptech.html

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 391
Default Updating a Data List

In my example your command button (CommandButton1)
loads data from ten text boxes and a combo box into the
next available row on the designated sheet...its quite
easy to follow.
The text boxes are named textbox1, textbox2,..., textbox10
Finally the value of a combbox is also added.

Private Sub CommandButton1_Click()

Dim target As Range
Dim i As Long

target = Worksheets("Sheet1").Range("A65000").End
(xlUp).Offset(1, 0)

target.Value = Format$(Date, "dd-mm-yyyy")

For i = 1 To 10

target.Offset(0, i).Value = _
Controls("textbox" & i).Text
Controls("textbox" & i).Text = ""

Next

target.Offset(0, 11).Value = ComboBox1.Value

End Sub


This should get you started

Patrick Molloy
Microsoft Excel MVP


-----Original Message-----
Would someone be so kind to provide a VBA code I can

assign to a command
button on a user form that will transfer the data just

entered in the form's
fields to a list located on a separate worksheet within

the same workbook? I
would like each click of the button to update the list

by adding new row and
then to clear the user form preparing it for new data

entry. I don't want to
use MS Access for that function.

Thanks a lot!


.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Create auto updating data validation list from all worksheet names fryguy Excel Worksheet Functions 7 December 11th 07 08:59 PM
Updating mailing list data David_Morrison Excel Discussion (Misc queries) 0 November 22nd 06 10:13 PM
Updating a list [email protected] Excel Discussion (Misc queries) 1 February 17th 05 01:36 AM
updating data in rows from master list Allen Nance Excel Programming 7 September 18th 03 06:18 PM
updating data in rows from master list Allen[_8_] Excel Programming 0 September 17th 03 09:42 PM


All times are GMT +1. The time now is 01:31 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"