Prev Previous Post   Next Post Next
  #4   Report Post  
Norman Jones
 
Posts: n/a
Default

Hi Jaytree,

"Jaytee" wrote in message
...
Question 1: If I'm entering rows of data, can I set it up at a certain
column
to return to the start of the next row?
So if I have 4 columns of data, I input in A2, hit enter to get to B2,
then
input and hit enter to get to c2, input and enter to get to d2, input and
enter to get to b3.


If you want a VBA solution, try:

'===================
Private Sub Worksheet_Change(ByVal Target As Range)
Dim RngInput As Range
Dim i As Long

Set RngInput = Range("A1:D50") '<<========= CHANGE
i = RngInput.Columns.Count

If Target.Cells.Count 1 Then Exit Sub

If Not Intersect(Target, RngInput) Is Nothing Then
If Target.Column = RngInput.Columns(i).Column Then
Target.Offset(1, 1 - i).Select
Else
Target.Offset(0, 1).Select
End If
End If
End Sub
'===================

Change Range("A1:D50") to match the required input range.

This is worksheet event code and should be pasted into the worksheets's code
module (not a standard module and not the workbook's ThisWorkbook module):

************************************************** **********
Right-click the worksheet's tab

Select 'View Code' from the menu and paste the code.

Alt-F11 to return to Excel.
************************************************** **********

If you are not familiar with macros you may wish to visit David McRitchie's
'Getting Started With Macros And User Defined Functions' at:

http://www.mvps.org/dmcritchie/excel/getstarted.htm


---
Regards,
Norman




 
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
Auto Return Auto Return Excel Discussion (Misc queries) 1 September 8th 05 08:36 PM
Huge problem with "if" formula's [email protected] Excel Discussion (Misc queries) 16 July 20th 05 07:20 PM
Excel - return a picture or range rows as the result of a formula juststarting Excel Worksheet Functions 1 July 4th 05 12:59 AM
How do create a formula to evalute a # to return 1 of 4 conditions Larry Excel Worksheet Functions 4 May 29th 05 12:58 AM
excel links update not working in auto, calculations in auto Mikey Boy Excel Worksheet Functions 0 December 7th 04 11:53 PM


All times are GMT +1. The time now is 04:54 PM.

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"