View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
cmpcwil2[_6_] cmpcwil2[_6_] is offline
external usenet poster
 
Posts: 1
Default Excel controls vs vba controls


Sorry posted this in Excel General before by mistake!

I am new to VBA so just finding my feet, can anyone help me with the
differences between an excel control (i.e. one from the form toolbox)
lets say a checkBox and a vba checkBox?
From trying the two controls the I have noticed is that you cannot
capture the change event of the VBA checkbox in the code module, it has
to be done via the sheet (i.e. checkbox on sheet1, code goes in change
event on sheet1) the control is placed on, is this correct? What would
you do if you have three sheets with the same controls just different
data, do you really have to code the control 3 times?

The excel control however you can code a module to capture the change
event but cannot reference the checkbox directly as in
activesheet.checkbox1.value, is this correct?

I am trying to decide which is the best 'toolbox' to use for a vba app,
trying to ensure the code is not tied to a specific sheet. Not sure if
this is possible using these controls?


--
cmpcwil2
------------------------------------------------------------------------
cmpcwil2's Profile: http://www.excelforum.com/member.php...o&userid=33411
View this thread: http://www.excelforum.com/showthread...hreadid=534110