macro buttons

S

Sheetal

hello!

I have just created a button in my excel spreadsheet, and want to
assign a macro to it. I have followed the help in the Excel help menu
which suggested that i right click the button and select assign macro.

However, when i rightclick the button i created, i don't get this
option. i have tried clicking all parts of the button, ie the button
itself, and also the selection boxes.

Does anyone know of any easier ways of creating buttons and then
assigning macros to them, or let me know what i am doing wrong.

Thanks
 
P

Paul B

Sheetal, the buttons have to be from the forms toolbar, view, toolbars forms
to right click and assign the macros, sounds like you have a button from the
control toolbar

--
Paul B
Always backup your data before trying something new
Using Excel 2000 & 97
Please post any response to the newsgroups so others can benefit from it
** remove news from my email address to reply by email **
 
C

Chip Pearson

Sheetal,

There are two types of buttons you can place on a worksheets: one from the
Forms toolbar and the other from the Controls toolbar. The "assign macro"
is available only for controls from the Forms toolbar. Most likely, you are
using controls from the Controls toolbar.

You can either replace your controls with control from the Forms toolbar and
then use Assign Macro to assign a macro, or you can choose View Code from
the right-click menu and call your code from the Click event procedure in
the worksheet module.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com (e-mail address removed)
 
L

libby

As said before, you only get this message with a button
from the Forms toolbar. However, you should be able to
manually assign a macro to a button from the Control
Toolbox toolbar.
1)Go into design mode by clicking the icon with the set
square and pencil on it, on the Control Toolbox toolbar.
2)Right click on the button and click View Code
3)In the following sub type Call followed by the name of
the macro you wish to assign.

libby
 
S

Sheetal

thanks for the previous problem, i have now rectified it. now,

I want to create a macro that can take information from a webpage and
copy into my spreadsheet.

How can i do this?

Everytime this macro is run, the spreadsheet that it will be called
into will be the same.

Thanks
 
K

kotharu

Sheetal,
in the excel sheet you will find...

Data ......then
Import External Data.....then
New Web Query....


there you can select the webpage which you want to copy.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top