Reply
 
Thread Tools Display Modes
  #1   Report Post  
youngslyfr
 
Posts: n/a
Default run time error 91 in word 2002

I created a macro in word...I want word to use this macro on startup. I type
in the switche /mmacroname right after the target for winword.exe (shortcut)(
yes with a space after the " ) When i click on word to open up..i get this
stupid run time error 91 object variable or with block variable not set. It
is soooooo easy to to the same thing in excel!! Wonder why microsoft is not
STANDARD !!!!!
My macro only has one line!!! I just want it to justify my text instead of
justify left by default (btw its for a lazy client )

I use windows 2000. I tried it on XP and it does the same thing.

Any help would be appreciated, thank u
Sylvie
  #2   Report Post  
Suzanne S. Barnhill
 
Posts: n/a
Default

You can accomplish the same thing by naming your macro AutoExec or AutoOpen
or AutoNew, but any of those is a hamhanded approach to the problem, which
should be solved by modifying the paragraph style instead (but I strongy
recommend against modifying the Normal style to be justified since most
other styles are based on it).

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA
Word MVP FAQ site: http://word.mvps.org
Email cannot be acknowledged; please post all follow-ups to the newsgroup so
all may benefit.

"youngslyfr" wrote in message
...
I created a macro in word...I want word to use this macro on startup. I

type
in the switche /mmacroname right after the target for winword.exe

(shortcut)(
yes with a space after the " ) When i click on word to open up..i get this
stupid run time error 91 object variable or with block variable not set.

It
is soooooo easy to to the same thing in excel!! Wonder why microsoft is

not
STANDARD !!!!!
My macro only has one line!!! I just want it to justify my text instead of
justify left by default (btw its for a lazy client )

I use windows 2000. I tried it on XP and it does the same thing.

Any help would be appreciated, thank u
Sylvie


  #3   Report Post  
youngslyfr
 
Posts: n/a
Default

Hello Suzanne, THank you for the advice.
Whenever I do a macro though, being anything I put in it, and call it
AutoOpen it just wont do anything when I open Word. No errors, but also its
not executing it !!
Any suggestions what I might be doing wrong???
Im on windows 2000 pro running word 2000
Thank you again
Sylvie

"Suzanne S. Barnhill" wrote:

You can accomplish the same thing by naming your macro AutoExec or AutoOpen
or AutoNew, but any of those is a hamhanded approach to the problem, which
should be solved by modifying the paragraph style instead (but I strongy
recommend against modifying the Normal style to be justified since most
other styles are based on it).

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA
Word MVP FAQ site: http://word.mvps.org
Email cannot be acknowledged; please post all follow-ups to the newsgroup so
all may benefit.

"youngslyfr" wrote in message
...
I created a macro in word...I want word to use this macro on startup. I

type
in the switche /mmacroname right after the target for winword.exe

(shortcut)(
yes with a space after the " ) When i click on word to open up..i get this
stupid run time error 91 object variable or with block variable not set.

It
is soooooo easy to to the same thing in excel!! Wonder why microsoft is

not
STANDARD !!!!!
My macro only has one line!!! I just want it to justify my text instead of
justify left by default (btw its for a lazy client )

I use windows 2000. I tried it on XP and it does the same thing.

Any help would be appreciated, thank u
Sylvie



  #4   Report Post  
Suzanne S. Barnhill
 
Posts: n/a
Default

An AutoOpen macro runs when you open a document. AutoExec runs when you
start Word, AutoNew when you create a new document.

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA
Word MVP FAQ site: http://word.mvps.org
Email cannot be acknowledged; please post all follow-ups to the newsgroup so
all may benefit.

"youngslyfr" wrote in message
...
Hello Suzanne, THank you for the advice.
Whenever I do a macro though, being anything I put in it, and call it
AutoOpen it just wont do anything when I open Word. No errors, but also

its
not executing it !!
Any suggestions what I might be doing wrong???
Im on windows 2000 pro running word 2000
Thank you again
Sylvie

"Suzanne S. Barnhill" wrote:

You can accomplish the same thing by naming your macro AutoExec or

AutoOpen
or AutoNew, but any of those is a hamhanded approach to the problem,

which
should be solved by modifying the paragraph style instead (but I strongy
recommend against modifying the Normal style to be justified since most
other styles are based on it).

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA
Word MVP FAQ site: http://word.mvps.org
Email cannot be acknowledged; please post all follow-ups to the

newsgroup so
all may benefit.

"youngslyfr" wrote in message
...
I created a macro in word...I want word to use this macro on startup.

I
type
in the switche /mmacroname right after the target for winword.exe

(shortcut)(
yes with a space after the " ) When i click on word to open up..i get

this
stupid run time error 91 object variable or with block variable not

set.
It
is soooooo easy to to the same thing in excel!! Wonder why microsoft

is
not
STANDARD !!!!!
My macro only has one line!!! I just want it to justify my text

instead of
justify left by default (btw its for a lazy client )

I use windows 2000. I tried it on XP and it does the same thing.

Any help would be appreciated, thank u
Sylvie




  #5   Report Post  
Graham Mayor
 
Posts: n/a
Default

There are a number of things that could be wrong here. Where are you saving
the macro? Is it supposed to act on all new documents? In that case it
should be in normal.dot. It should also be called AutoNew as AutoOpen is for
existing documents.

Frankly no matter how stupid or lazy your client, this is a very poor method
for setting justification that could introduce more problems than it solves.
You need to set justification as a paragraph style attribute.

--

Graham Mayor - Word MVP

My web site www.gmayor.com
Word MVP web site http://word.mvps.org




youngslyfr wrote:
Hello Suzanne, THank you for the advice.
Whenever I do a macro though, being anything I put in it, and call it
AutoOpen it just wont do anything when I open Word. No errors, but
also its not executing it !!
Any suggestions what I might be doing wrong???
Im on windows 2000 pro running word 2000
Thank you again
Sylvie

"Suzanne S. Barnhill" wrote:

You can accomplish the same thing by naming your macro AutoExec or
AutoOpen or AutoNew, but any of those is a hamhanded approach to the
problem, which should be solved by modifying the paragraph style
instead (but I strongy recommend against modifying the Normal style
to be justified since most other styles are based on it).

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA
Word MVP FAQ site: http://word.mvps.org
Email cannot be acknowledged; please post all follow-ups to the
newsgroup so all may benefit.

"youngslyfr" wrote in message
...
I created a macro in word...I want word to use this macro on
startup. I type in the switche /mmacroname right after the target
for winword.exe (shortcut)( yes with a space after the " ) When i
click on word to open up..i get this stupid run time error 91
object variable or with block variable not set. It is soooooo easy
to to the same thing in excel!! Wonder why microsoft is not
STANDARD !!!!!
My macro only has one line!!! I just want it to justify my text
instead of justify left by default (btw its for a lazy client )

I use windows 2000. I tried it on XP and it does the same thing.

Any help would be appreciated, thank u
Sylvie



Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How can I divide a page into three sections? Bonnie Microsoft Word Help 3 May 8th 23 02:47 AM
How can I default to open with WORD 97 rather than WORD 2002 MB_ Microsoft Word Help 2 December 10th 04 04:09 AM
saving the workspace Mike Microsoft Word Help 3 December 8th 04 11:32 PM
Working several docs at the same time with Word 2000 Frode Hjønnevåg Microsoft Word Help 2 December 2nd 04 07:25 PM
Semitransparent watermarks take a long time to PDF with Word 2002 Glenn Turner Microsoft Word Help 0 November 29th 04 12:29 AM


All times are GMT +1. The time now is 07:43 AM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"