View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Hendri Adriaens Hendri Adriaens is offline
external usenet poster
 
Posts: 5
Default programming button again

Hi,

I was trying to program a button with vba (excel) and got the following
advice:

You have to write the event in the sheet module using code (or have it
already there)

http://www.cpearson.com/excel/vbe.htm



It seemed to work, namely in excel 200. Unfortunately, that doesn't work in
excel 2003. The reason is the extra security option "Trust access to vb
project". Even if enabled, it still doesn't allow code to be written, while
it does in 2000, even without changing any option.

Is there no way to just say:
CommandButton1.OnClick="..."
instead of needing to write in the editor?

It's very suprising that such a simple thing as adding a button with a
function first of all, needs such complicated coding (writing in the editor)
and then also leads to security issues...

I pasted the code that I use below.

Anyway, any help is welcome!

Thanks, regards,
-Hendri.