Home |
Search |
Today's Posts |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
The problem is much greater:
I have a field C2 "). With a click on a button, Outlook generates an email with Body, Subject, Attachment and Signatur. But I want that the email-Adress for the To-Field is taken from C2. Therefore I thought, that I can provide this field dynamic, so that VBA takes the Name of the Button (in this Case C2) and after that it chooses the field C2, lookes inside, takes the adress in C2 and puts it in the To-Field! Do I want to much? I know everything about that process but now idea how to query the the name of the button in that button. So I hope someone can help me. "ben" wrote: You want to get the name without using the name???? Sorry not quite certain what you are asking for. you could loop through all the controls on the userform and see if any of them match criteria dim con as control for each con in me.controls if 'criteria code here whatiwant = con.name end if next ben "Oener" wrote: Hi, I have a button "C2". I want to get the name of the button in VBA to point on the cell C2. How do I get the name of the button without using the name of the button? With use: Dim whatIwant as variant whatIwant = Me.C2.Name -- whatIwant=C2 is there a way like: whatIwant = Mebutton.Name ??? Kindly Oener |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Creating a Macro Button to Extract Data | New Users to Excel | |||
Creating a Macro Button to Extract Data | Excel Discussion (Misc queries) | |||
Creating a Macro Button to Extract Data | New Users to Excel | |||
Extract Unique Values, Then Extract Again to Remove Suffixes | Excel Discussion (Misc queries) | |||
Extract image from toolbar button | Excel Programming |