Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 26
Default ENTER DATA - LOG ENTRIES ON SEPERATE SHEET (IN SAME BOOK)

Hello guys,
A little Help here...I can't figure it out.

I have one sheet in my workbook called DATA. On the DATA sheet, I
enter the Last Name in Cell C3, I enter the First Name in Cell C5, I
enter the middle name in C7 and the Worker ID in W3. After these
cells, I have a command button (Button 6), it is labeled: "ADD TO
LOG".

I have another sheet in the same workbook called LOG. On this sheet I
would like to log each name I enter in the DATA sheet. The first
person I enter starts on Row 3. The next person I enter would go in
Row 4, and this would keep going.. For example...in the LOG sheet,
the first column would have LAST, FIRST MIDDLE in column A; the second
column on the LOG sheet would have the worker's ID.

I want to be able to push the command button (button 6) and the DATA
sheet, and automatically have the data put on the next row down in the
LOG sheet.

Can someone throw some CODE my way ???? I appreciate it guys.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default ENTER DATA - LOG ENTRIES ON SEPERATE SHEET (IN SAME BOOK)

You say you have a commandbutton, but they are usually named like
CommandButton6. this represents the event (located in the sheet module) for
such a commandbutton. If it is a button from the forms toolbar instead (which
matches the name you cite), put the code in a general module and assign it to
the button.

Private Sub commandButton6_click()
Dim sh as Worksheet, lastrow as Long
set sh = Worksheets("Data")
With worksheets("Log")
lastrow = Cells(rows.count,1).End(xlup).row +1
if lastrow < 3 then lastrow = 3
.Cells(lastrow,1).Value = sh.Range("C3").Value & ", " & _
sh.Range("C5").Value & " " & sh.Range("C7").Value
.Cells(lastrow,2).Value = sh.Range("W3").Value
End with
end Sub

--
Regards,
Tom Ogilvy

"Bull" wrote:

Hello guys,
A little Help here...I can't figure it out.

I have one sheet in my workbook called DATA. On the DATA sheet, I
enter the Last Name in Cell C3, I enter the First Name in Cell C5, I
enter the middle name in C7 and the Worker ID in W3. After these
cells, I have a command button (Button 6), it is labeled: "ADD TO
LOG".

I have another sheet in the same workbook called LOG. On this sheet I
would like to log each name I enter in the DATA sheet. The first
person I enter starts on Row 3. The next person I enter would go in
Row 4, and this would keep going.. For example...in the LOG sheet,
the first column would have LAST, FIRST MIDDLE in column A; the second
column on the LOG sheet would have the worker's ID.

I want to be able to push the command button (button 6) and the DATA
sheet, and automatically have the data put on the next row down in the
LOG sheet.

Can someone throw some CODE my way ???? I appreciate it guys.


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 26
Default ENTER DATA - LOG ENTRIES ON SEPERATE SHEET (IN SAME BOOK)

Tom, wow...where in the heck do you learn all this stuff...I think
your name is all over these forums...thanks alot.

On Jan 29, 10:23 am, Tom Ogilvy
wrote:
You say you have a commandbutton, but they are usually named like
CommandButton6. this represents the event (located in the sheet module) for
such a commandbutton. If it is a button from the forms toolbar instead (which
matches the name you cite), put the code in a general module and assign it to
the button.

Private Sub commandButton6_click()
Dim sh as Worksheet, lastrow as Long
set sh = Worksheets("Data")
With worksheets("Log")
lastrow = Cells(rows.count,1).End(xlup).row +1
if lastrow < 3 then lastrow = 3
.Cells(lastrow,1).Value = sh.Range("C3").Value & ", " & _
sh.Range("C5").Value & " " & sh.Range("C7").Value
.Cells(lastrow,2).Value = sh.Range("W3").Value
End with
end Sub

--
Regards,
Tom Ogilvy



"Bull" wrote:
Hello guys,
A little Help here...I can't figure it out.


I have one sheet in my workbook called DATA. On the DATA sheet, I
enter the Last Name in Cell C3, I enter the First Name in Cell C5, I
enter the middle name in C7 and the Worker ID in W3. After these
cells, I have a command button (Button 6), it is labeled: "ADD TO
LOG".


I have another sheet in the same workbook called LOG. On this sheet I
would like to log each name I enter in the DATA sheet. The first
person I enter starts on Row 3. The next person I enter would go in
Row 4, and this would keep going.. For example...in the LOG sheet,
the first column would have LAST, FIRST MIDDLE in column A; the second
column on the LOG sheet would have the worker's ID.


I want to be able to push the command button (button 6) and the DATA
sheet, and automatically have the data put on the next row down in the
LOG sheet.


Can someone throw some CODE my way ???? I appreciate it guys.- Hide quoted text -- Show quoted text -


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 26
Default ENTER DATA - LOG ENTRIES ON SEPERATE SHEET (IN SAME BOOK)

On Jan 29, 10:23 am, Tom Ogilvy
wrote:
You say you have a commandbutton, but they are usually named like
CommandButton6. this represents the event (located in the sheet module) for
such a commandbutton. If it is a button from the forms toolbar instead (which
matches the name you cite), put the code in a general module and assign it to
the button.

Private Sub commandButton6_click()
Dim sh as Worksheet, lastrow as Long
set sh = Worksheets("Data")
With worksheets("Log")
lastrow = Cells(rows.count,1).End(xlup).row +1
if lastrow < 3 then lastrow = 3
.Cells(lastrow,1).Value = sh.Range("C3").Value & ", " & _
sh.Range("C5").Value & " " & sh.Range("C7").Value
.Cells(lastrow,2).Value = sh.Range("W3").Value
End with
end Sub

--
Regards,
Tom Ogilvy



"Bull" wrote:
Hello guys,
A little Help here...I can't figure it out.


I have one sheet in my workbook called DATA. On the DATA sheet, I
enter the Last Name in Cell C3, I enter the First Name in Cell C5, I
enter the middle name in C7 and the Worker ID in W3. After these
cells, I have a command button (Button 6), it is labeled: "ADD TO
LOG".


I have another sheet in the same workbook called LOG. On this sheet I
would like to log each name I enter in the DATA sheet. The first
person I enter starts on Row 3. The next person I enter would go in
Row 4, and this would keep going.. For example...in the LOG sheet,
the first column would have LAST, FIRST MIDDLE in column A; the second
column on the LOG sheet would have the worker's ID.


I want to be able to push the command button (button 6) and the DATA
sheet, and automatically have the data put on the next row down in the
LOG sheet.


Can someone throw some CODE my way ???? I appreciate it guys.- Hide quoted text -


- Show quoted text -


Tom. Thanks again..but how to I make the entry move to the next row
down, so it keeps a running log. Go to next row if previous row in
the sheet "LOG" is full?

Thanks

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 26
Default ENTER DATA - LOG ENTRIES ON SEPERATE SHEET (IN SAME BOOK)

On Jan 30, 11:23 am, "Bull" wrote:
On Jan 29, 10:23 am, Tom Ogilvy
wrote:





You say you have a commandbutton, but they are usually named like
CommandButton6. this represents the event (located in the sheet module) for
such a commandbutton. If it is a button from the forms toolbar instead (which
matches the name you cite), put the code in a general module and assign it to
the button.


Private Sub commandButton6_click()
Dim sh as Worksheet, lastrow as Long
set sh = Worksheets("Data")
With worksheets("Log")
lastrow = Cells(rows.count,1).End(xlup).row +1
if lastrow < 3 then lastrow = 3
.Cells(lastrow,1).Value = sh.Range("C3").Value & ", " & _
sh.Range("C5").Value & " " & sh.Range("C7").Value
.Cells(lastrow,2).Value = sh.Range("W3").Value
End with
end Sub


--
Regards,
Tom Ogilvy


"Bull" wrote:
Hello guys,
A little Help here...I can't figure it out.


I have one sheet in my workbook called DATA. On the DATA sheet, I
enter the Last Name in Cell C3, I enter the First Name in Cell C5, I
enter the middle name in C7 and the Worker ID in W3. After these
cells, I have a command button (Button 6), it is labeled: "ADD TO
LOG".


I have another sheet in the same workbook called LOG. On this sheet I
would like to log each name I enter in the DATA sheet. The first
person I enter starts on Row 3. The next person I enter would go in
Row 4, and this would keep going.. For example...in the LOG sheet,
the first column would have LAST, FIRST MIDDLE in column A; the second
column on the LOG sheet would have the worker's ID.


I want to be able to push the command button (button 6) and the DATA
sheet, and automatically have the data put on the next row down in the
LOG sheet.


Can someone throw some CODE my way ???? I appreciate it guys.- Hide quoted text -


- Show quoted text -


Tom. Thanks again..but how to I make the entry move to the next row
down, so it keeps a running log. Go to next row if previous row in
the sheet "LOG" is full?

Thanks- Hide quoted text -

- Show quoted text -


Anyone??? How to make the entry move to the next row down, so it
keeps a running log. Go to next row if previous row in the same sheet
is full?

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
flowing data to seperate sheet Jenner Excel Discussion (Misc queries) 3 February 9th 09 09:45 AM
Sort out data on seperate sheet Linda Excel Programming 11 June 13th 06 06:10 PM
enter data on 1 sheet and make it enter on next avail row on 2nd s Nadia Excel Discussion (Misc queries) 27 September 9th 05 03:39 PM
Data copy from a seperate sheet to data sheet ZeroXevo Excel Programming 1 June 20th 05 08:14 AM
Is it possible to export each row of data to a seperate work book Stacey[_2_] Excel Programming 18 May 15th 04 04:36 AM


All times are GMT +1. The time now is 02:42 AM.

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

About Us

"It's about Microsoft Excel"