Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Programming / November 2005

Tip: Looking for answers? Try searching our database.

Enduring Variable

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
donbowyer - 26 Nov 2005 23:22 GMT
Is there any way to store a numeric variable value somewhere in Word, so that
the value remains after Word is closed, and is available next time Word is
opened?
Signature

donwb

Greg Maxey - 26 Nov 2005 23:53 GMT
You can store variable information in a .txt file or the windows registry.
See PrivateProfileString in VBA Help.

Signature

Greg Maxey/Word MVP
See:
http://gregmaxey.mvps.org/word_tips.htm
For some helpful tips using Word.

> Is there any way to store a numeric variable value somewhere in Word,
> so that the value remains after Word is closed, and is available next
> time Word is opened?
ML - 27 Nov 2005 00:25 GMT
If you want it to be associated with a specific Word document then you can
save it in a custom document property.

> Is there any way to store a numeric variable value somewhere in Word, so
> that
> the value remains after Word is closed, and is available next time Word is
> opened?
Jezebel - 27 Nov 2005 00:49 GMT
In addition to the methods suggested by the other posters, you can use a
customproperty stored in normal.dot --

templates("normal.dot").CustomDocumentProperties("MyProperty") = ...

> Is there any way to store a numeric variable value somewhere in Word, so
> that
> the value remains after Word is closed, and is available next time Word is
> opened?
Doug Robbins - Word MVP - 27 Nov 2005 07:46 GMT
See the article "Creating sequentially numbered documents (such as
invoices)" at:

http://www.word.mvps.org/FAQs/MacrosVBA/NumberDocs.htm

or "Sequentially numbering multiple copies of single document using a macro"
at:

http://www.word.mvps.org/FAQs/MacrosVBA/NumberCopiesOf1Doc.htm

Signature

Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

> Is there any way to store a numeric variable value somewhere in Word, so
> that
> the value remains after Word is closed, and is available next time Word is
> opened?
donbowyer - 27 Nov 2005 23:03 GMT
Many thanks to all who contributed to my Enduring Variable question.
From a combination of your inputs, I have a solution, based largely on the
creation of an "external" *.txt file.
Signature

donwb

> See the article "Creating sequentially numbered documents (such as
> invoices)" at:
[quoted text clipped - 10 lines]
> > the value remains after Word is closed, and is available next time Word is
> > opened?

Rate this thread:






 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.