Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default Assigning a macro to a worksheet (vs personal.xls)

If all you want to do is display the Print dialog, use the
following line of code:

Application.Dialogs(xlDialogPrint).Show


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com



"StargateFan" wrote in
message ...
On Thu, 13 May 2004 13:13:16 -0700, David


wrote:

Bridget wrote

I chose the "Command Button" option from the "Control
Toolbox". I don't know if this was the right button as
this wasn't specified but it seemed the best one. But
maybe that's what's wrong (?).


Use one from the Forms toolbar instead. That one has the

right-click|Assign
Macro option as opposed to one from the Controls toolbar (it

uses
button_click code).


OMG, that is just so utterly incredible! And it took a mere

moments
to do! It's amazing how all the functions/features resemble db
creation! I was able to use the same ideas and techniques! I

could
even put an icon on the button just like I would in Filemaker!
Totally awesome!

I also saved the macros to the worksheet itself. I'd never

done that
before. I usu. make global ones to the personal.xls file so

never
really noticed that you could save to a sheet itself! This

makes it
ideal!

There is just one last thing which I hope to do before calling

this
quits: I'm just no good at VB. I can't get a handle on it

(though
I'm good at following clear instructions <lol!). Is there a

way to
put in an "open print dialogue box" command as a last thing to

do for
a print command macro? And, if so, is it hard to code?

This way, the print button will do the sort necessary before

printing
but then will open the print dialogue box for the user.

<fingers
crossed I hope there's an easy way to do this. I was doing

that
sort of thing in WordPerfect as long ago as 1998 (if not in ear

lier
versions) so hoping that I can do that in the macro language of

Excel.

If that is possible, then every time I get sent to a contract

and they
want me to track data yet won't allow me to create a db and

absolutely
want me to use Excel (THEY DO do that to me!!), then I can get

around
spreadsheet limitations by creating macros that users can

access via
buttons!! And sorting and doing certain things before printing

seem
to be one of the most common things one needs to do.

This is exciting!!

Thank you!



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
assigning macro carrera Excel Discussion (Misc queries) 16 March 21st 08 09:00 PM
Personal macro workbook and personal.xls John Kilkenny Excel Discussion (Misc queries) 1 June 14th 05 09:43 PM
How do I get my personal macro worksheet to open whenever I open . Claudia_R Excel Discussion (Misc queries) 3 December 9th 04 11:59 PM
personal.htm & personal.xls in Macro Rasoul Khoshravan Azar Excel Programming 0 January 21st 04 05:27 PM


All times are GMT +1. The time now is 10:03 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"