![]() |
creating macro to ask for variable info when excel starts
Hello, I don't understand visual basic at all, so don't understand the
help that comes with Excel 2002. We create proposals for different companies using Excel, but sometimes the guys forget to change the name of the customer on the proposal. Is there a way I can get the proposal to ask for the customer's name and enter it in a cell when a person starts the spreadsheet for the 1st time? Thanks for any help. |
creating macro to ask for variable info when excel starts
Sub Auto_Open()
Dim sCust sCust = InputBox("Please supply customer number", _ "Custmomer Proposal", _ Worksheets("Sheet1").Range("A1").Value) If sCust < "" Then Worksheets("Sheet1").Range("A1").Value = sCust End If End Sub -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "Flyriverside" wrote in message om... Hello, I don't understand visual basic at all, so don't understand the help that comes with Excel 2002. We create proposals for different companies using Excel, but sometimes the guys forget to change the name of the customer on the proposal. Is there a way I can get the proposal to ask for the customer's name and enter it in a cell when a person starts the spreadsheet for the 1st time? Thanks for any help. |
All times are GMT +1. The time now is 12:41 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com