Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Saving from form into multiple sheets
I have built a form to enter data from. I have two sheets, “Customers
and “Projects”. Some fields are duplicated in both sheets. How do I activate both sheets? How do I make Customer data be saved into "Customers" sheet an Projects data be saved into "Projects" sheet? How do I ensure that the data of the duplicated fields are saved int both sheets? Thank you very much -- Message posted from http://www.ExcelForum.com |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Saving from form into multiple sheets
Just change the range to where you want the data to go on the appropriate
sheet Worksheets("Customers").range("a3") = control(whatever you are calling the thing you enter datainto) Worksheets("Projects"),rang("b3")=control(whatever you are calling the thing you enter datainto) If you are dealing with a lot of data then you are better setting up a loop to paste the data back into the spreadsheets "ryssa " wrote in message ... I have built a form to enter data from. I have two sheets, "Customers" and "Projects". Some fields are duplicated in both sheets. How do I activate both sheets? How do I make Customer data be saved into "Customers" sheet and Projects data be saved into "Projects" sheet? How do I ensure that the data of the duplicated fields are saved into both sheets? Thank you very much. --- Message posted from http://www.ExcelForum.com/ |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Saving from form into multiple sheets
Thank you David, though I am not a programmer and Im not sure what to do
with that. Here is what my code looks like. Private Sub cmdSave_Click() ActiveWorkbook.Sheets("Contacts").Activate Range("A1").Select Do If IsEmpty(ActiveCell) = False Then ActiveCell.Offset(1, 0).Select End If Loop Until IsEmpty(ActiveCell) = True ActiveCell.Value = txtName.Value ActiveCell.Offset(0, 2) = txtCompany.Value ActiveCell.Offset(0, 3) = txtAddress.Value ActiveCell.Offset(0, 4) = txtPhone.Value ActiveCell.Offset(0, 13) = txtProject.Value ActiveCell.Offset(0, 10) = cboIndustry.Value ActiveCell.Offset(0, 15) = cboPersonInCharge.Value End Sub In "Customers" sheet I am supposed to save the data Name, Company, Address, Phone In "Projects" sheet I am supposed to save the data Project, Company, Name, Industry, Person In Charge Though in reality I have many more that just those fields. --- Message posted from http://www.ExcelForum.com/ |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
I want to add formulas from multiple sheets to master form | Excel Worksheet Functions | |||
editing a form and emailing without saving | Excel Worksheet Functions | |||
Saving Sheets into Multiple Files | Excel Discussion (Misc queries) | |||
saving multiple sheets in a workbook | Excel Discussion (Misc queries) | |||
saving excel with multiple sheets, but won't save to proper sheet | Excel Discussion (Misc queries) |