Very simple Delete Button help!!!!!

  • Thread starter Thread starter Marc
  • Start date Start date
M

Marc

I have a context menu on a button. I just need some code that will
delete the button when the context menu is clicked.

Any ideas?
 
Marc said:
I have a context menu on a button. I just need some code that will
delete the button when the context menu is clicked.

Any ideas?

I should add that i do not know the button name as it is created
dynamically.
 
Delete the button? you mean remove it from the control?

Contextmenu.controls.remove(buttonname)
-or
Contextmenu.control.removeat(indexofbutton)

Hope this helps.

this method workss in both VB 2k3 and 2k5.

--
Thiele Enterprises - The Power Is In Your Hands Now!

--
I have a context menu on a button. I just need some code that will
delete the button when the context menu is clicked.

Any ideas?

I should add that i do not know the button name as it is created
dynamically.
 
Back
Top