Hi there,
This is my first post here, and I'm hoping the community can help me!
I'm using a UserForm in Excel 2003 to collect data and input it into a worksheet. Before seeing the UserForm, the user is prompted to choose which worksheet (there are three: North America, Europe, and Asia) is to be used. The CommandButton simply selects which worksheet is to become active, and launches the UserForm.
So far so good.
The UserForm then deposits the data into the proper cells, which is great. But what I now want is to summarise ALL data into a "Summary" worksheet. That is to say, I want the UserForm to copy the data into two worksheets, the region-specific one and the Summary one.
My code is as follows:
As you can see, I have the macro set to determine the next ActiveCell and deposit the responses there. How would I get that data copied over to the Summary database worksheet as well, so that no matter which worksheet in which the data is recorded (i.e. NA, Europe, Asia), the macro will choose the next appropriate row/cell in the Summary database worksheet and record the data there?
Does this make sense? I know I'm rambling a bit and it makes sense in my head..
Thanks so much for all your help!!!
This is my first post here, and I'm hoping the community can help me!
I'm using a UserForm in Excel 2003 to collect data and input it into a worksheet. Before seeing the UserForm, the user is prompted to choose which worksheet (there are three: North America, Europe, and Asia) is to be used. The CommandButton simply selects which worksheet is to become active, and launches the UserForm.
So far so good.
The UserForm then deposits the data into the proper cells, which is great. But what I now want is to summarise ALL data into a "Summary" worksheet. That is to say, I want the UserForm to copy the data into two worksheets, the region-specific one and the Summary one.
My code is as follows:
Code:
Private Sub cmdSubmit_Click()
Range("A11").Select
Do Until ActiveCell.Value = ""
ActiveCell.Offset(1, 0).Range("A1").Select
Loop
ActiveCell.Value = tbxAirline
tbxAirline = Empty
Range("B11").Select
Do Until ActiveCell.Value = ""
ActiveCell.Offset(1, 0).Range("A1").Select
Loop
ActiveCell.Value = tbxAirport
tbxAirport = Empty
Range("E11").Select
Do Until ActiveCell.Value = ""
ActiveCell.Offset(1, 0).Range("A1").Select
Loop
ActiveCell.Value = cboxLoungeType
cboxLoungeType = Empty
-----------------------------------------------
If AllianceStar.Value = True Then
Range("D11").Select
Do Until ActiveCell.Value = ""
ActiveCell.Offset(1, 0).Range("A1").Select
Loop
ActiveCell.Value = "Star Alliance"
End If
If AllianceOneworld.Value = True Then
Range("D11").Select
Do Until ActiveCell.Value = ""
ActiveCell.Offset(1, 0).Range("A1").Select
Loop
ActiveCell.Value = "oneworld"
End If
----------------------------------------------
Range("R11").Select
Do Until ActiveCell.Value = ""
ActiveCell.Offset(1, 0).Range("A1").Select
Loop
ActiveCell.Value = tbxOtherFood
tbxOtherFood = Empty
Range("T11").Select
Do Until ActiveCell.Value = ""
ActiveCell.Offset(1, 0).Range("A1").Select
Loop
ActiveCell.Value = tbxNotes
tbxNotes = Empty
If chkHotFood.Value = True Then
Range("G11").Select
Do Until ActiveCell.Value = ""
ActiveCell.Offset(1, 0).Range("A1").Select
Loop
ActiveCell.Value = "Yes"
Else: Range("G11").Select
Do Until ActiveCell.Value = ""
ActiveCell.Offset(1, 0).Range("A1").Select
Loop
ActiveCell.Value = "-"
End If
If chkALaCarte.Value = True Then
Range("H11").Select
Do Until ActiveCell.Value = ""
ActiveCell.Offset(1, 0).Range("A1").Select
Loop
ActiveCell.Value = "Yes"
Else: Range("H11").Select
Do Until ActiveCell.Value = ""
ActiveCell.Offset(1, 0).Range("A1").Select
Loop
ActiveCell.Value = "-"
End If
As you can see, I have the macro set to determine the next ActiveCell and deposit the responses there. How would I get that data copied over to the Summary database worksheet as well, so that no matter which worksheet in which the data is recorded (i.e. NA, Europe, Asia), the macro will choose the next appropriate row/cell in the Summary database worksheet and record the data there?
Does this make sense? I know I'm rambling a bit and it makes sense in my head..
Thanks so much for all your help!!!