Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Programming Challenges!

I have a spreadsheet set up for the purpose of data entry via an external
data collection device. The spreadsheet consists of a header row: Serial No.,
Dim #1-Dim #16, Average, Range. I need a macro to run automatically upon
opening the worksheet that will position the cursor in the first empty Dim #1
(Column B) cell. Upon entry of the 16th pc of data, I need the cursor to
reset to the Dim #1 (Column B) in the next row. Also, I would like to set the
spreadsheet to either autosave within the macro that resets the cursor or
autosave every X minutes.

Anyone?

--
Thanx,

Loretta
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35
Default Programming Challenges!

Hi,

Try pasting the following code into the ThisWorkbook module. On open, this
code will find the first empty cell within column 2 (Column B). On any
worksheet change, it will check if the cell changed was in column 17 (Column
Q, Dim#16). If so, it will select the following row in column B.

Hope this helps!
Andy

Private Sub Workbook_Open()
Dim row As Long
row = 1
Do Until Trim(Cells(row, 2).Value) = ""
row = row + 1
Loop
Cells(row, 2).Select
End Sub
Private Sub Workbook_SheetChange(ByVal Sh As Object, ByVal Target As Range)
If Target.Column = 17 Then
ActiveWorkbook.Save
Cells(Target.row + 1, 2).Select
End If
End Sub


"Loretta" wrote:

I have a spreadsheet set up for the purpose of data entry via an external
data collection device. The spreadsheet consists of a header row: Serial No.,
Dim #1-Dim #16, Average, Range. I need a macro to run automatically upon
opening the worksheet that will position the cursor in the first empty Dim #1
(Column B) cell. Upon entry of the 16th pc of data, I need the cursor to
reset to the Dim #1 (Column B) in the next row. Also, I would like to set the
spreadsheet to either autosave within the macro that resets the cursor or
autosave every X minutes.

Anyone?

--
Thanx,

Loretta

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
programming help biker man Excel Discussion (Misc queries) 2 July 22nd 07 11:54 PM
programming help Stan Excel Discussion (Misc queries) 2 April 23rd 07 02:44 PM
Programming a NAME Dan Excel Programming 3 March 13th 07 02:10 PM
Double-byte challenges. Please help! Douglas Gennetten[_2_] Excel Programming 0 January 15th 04 02:20 AM
Do I need programming for this? .NET Developer Excel Programming 2 August 18th 03 08:55 PM


All times are GMT +1. The time now is 11:54 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"