Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Need help writing a VB Script for Excel.
I'm using Excel 2004 (version 11.5.1) and have created an Excel sheet that has an area to enter a variable or numerical number (Cell, E1). Then I have 12 checkboxes on the left of Excel Sheet, which I created with the Form Toolbox. What I would like to do is be able to enter the variable in the E1 Cell, then check off one of the checkboxes and have that variable appear in another Cell (E3, E5, or E7). If multiple checkboxes are checked, then I would like the variables to increase in value by one (e.g. Original Variable in E1 Cell + 1). Does anyone have any suggestions? Cheers! *** Sent via Developersdex http://www.developersdex.com *** |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
You don't need a macro! You need to set the cell link property of the check
box. Have the first check box linked to D3, 2nd D5, 3rd D7,... the results will be either true or False. then use a worksheet formula to get your results. To add the Cell Link property of the check box select the check box so it gets highlighted like a picture. Then press property on the Toolbox - forms (the icon with the finger). Then one the Control Tab of the proerty box enter the cell Link location. "Archie Hernandez" wrote: Need help writing a VB Script for Excel. I'm using Excel 2004 (version 11.5.1) and have created an Excel sheet that has an area to enter a variable or numerical number (Cell, E1). Then I have 12 checkboxes on the left of Excel Sheet, which I created with the Form Toolbox. What I would like to do is be able to enter the variable in the E1 Cell, then check off one of the checkboxes and have that variable appear in another Cell (E3, E5, or E7). If multiple checkboxes are checked, then I would like the variables to increase in value by one (e.g. Original Variable in E1 Cell + 1). Does anyone have any suggestions? Cheers! *** Sent via Developersdex http://www.developersdex.com *** |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi Joel,
Thanks for the advice. I did what you stated but I was unable to add a formula that stuck. Everytime I added a formula, the formula works but as soon as I click on the Checkbox, then the formula gets erased and a True/False variable appears in the cell. Any suggestions? Best, Archie *** Sent via Developersdex http://www.developersdex.com *** |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
You don't put a formula in the linked cell. Your formula should refer to the
link cell expecting a true or false entry in the linked cell. If the link cell is C3 then in cell C5 you can have a formula =if(C3=true,"Check box 1 is true","Check box 1 is false") "Archie Hernandez" wrote: Hi Joel, Thanks for the advice. I did what you stated but I was unable to add a formula that stuck. Everytime I added a formula, the formula works but as soon as I click on the Checkbox, then the formula gets erased and a True/False variable appears in the cell. Any suggestions? Best, Archie *** Sent via Developersdex http://www.developersdex.com *** |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Help ! How do I do this in VB Script | Setting up and Configuration of Excel | |||
VBA, VB Script and VB | Excel Programming | |||
Can I add this VB script to a VBA script? | Excel Programming | |||
Excel 2000/XP script to Excel97 script | Excel Programming | |||
what is a vb script | Excel Programming |