Solved

vb in Word 97

Posted on 2000-03-24
4
138 Views
Last Modified: 2010-05-02
Hi all, is it possible to use vba in word 97 to automatically load up and display the File -> Save As     browser window for the user to browse through and choose the directory where he wants to save the file, everytime a user opens a particular document.
Thanks for any help.
0
Comment
Question by:Rocheval
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 143

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 5 total points
ID: 2656311
Add this Code into the ThisDocument module using the Visual Basic Editor (Alt+F11)
Private Sub Document_Open()
  Application.Dialogs(wdDialogFileSaveAs).Show
End Sub

If you want this in the template, then
Private Sub Document_New()
  Application.Dialogs(wdDialogFileSaveAs).Show
End Sub
0
 

Author Comment

by:Rocheval
ID: 2663339
Thanks angel for answering :)
But is there a way such that File
-> Save As window loads up and appears only when the user opens the parent document and not when the user opens the saved child documents?
The problem occurs because the file-saving code carries over to the saved documents as well.
Thanks for any help.
0
 
LVL 143

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 2663448
What do you call Parant Document? Does it not correspond to a Word Template.
If it does, then only copy the code for the event Document_New() to the template (file.dot).
You may change the filename extention from .doc to .dot to make a document a template
0
 

Author Comment

by:Rocheval
ID: 2668457
Thanks Angel for all your help!
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

There are many ways to remove duplicate entries in an SQL or Access database. Most make you temporarily insert an ID field, make a temp table and copy data back and forth, and/or are slow. Here is an easy way in VB6 using ADO to remove duplicate row…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question