PDA

View Full Version : Solved: powerpoint tutorial on intranet - Get pop-up box 'This document has been modified'



harrycamp
03-02-2006, 07:05 PM
I hope someone is able to help me. I wrote a tutorial using powerpoint for work using VB on the backend. At the beginning, a pop-up box comes up for you to input your name. There are then 4 sections that you go through with a quiz at the end of each section. As you complete each section and quiz, a slide tells you which questions you got wrong. After you complete the whole tutorial, you have a slide that gives your name, your score, and a button to click on to print out the results. I tested it out in the folder where it was located and everything worked fine. My company placed it in a folder with a link to it on the company intranet. When you click on the link the slide show starts and everything works fine until you complete the first quiz. When you start the second section you get a pop-up box for each of the slides through the rest of the presentation. It says 'This document has been modified. Do you want to save changes?' Yes: Saves your changes, No: Discards your changes, Cancel: Keeps this document open. The title bar of the pop-up box has the following path M:\Documents and Settings\hcampbel\Local Settings\Temporary Internet Files\Content.IE5\.... Also, at the end of the tutorial, it doesn't give the persons name. But it does give the correct score and it prints. I've opened the tutorial without using the link and it works fine. We're using Powerpoint 97 SR-2 and IE 6.0.28 Update SP1. I'm not sure if it matters but in Properties for the tutorial, when you click on Everyone, the following permissions are set to Allow - Full Control, Modify, Read & Execute, Read, Write. I'm pretty new to this but I think that Everyone should be set to only Read & Execute, and Read. I was going to try setting those two only but I don't have privileges. I apologize for this being so long but I wanted to try and give as much information as possible. Thank you for your time.

Killian
03-03-2006, 05:54 AM
Hi and welcome to VBAX :hi:

While the directory for the source file should only have read permission (for regular users at least), the issue is that the pres is opened in a temp folder (the path you mentioned) and it's seen as unsaved because of the new path.
Ultimately, it won't matter if the user saves it, since it will be in their temp internet files but you could try just setting it's "Saved" property to True before you exit the last routineActivePresentation.Saved = True

The missing user name sounds like the scope of its variable isn't right but it's a bit difficult to tell without the code

harrycamp
03-03-2006, 05:01 PM
Killian,
I just wanted to thank you for the help. I added the line of code in each section and it worked great. I didn't do anything with the name yet but I think what I will do is add the code to get the name at the end, in the printable page section instead of at the beginning. Also thanks for the welcome.

Killian
03-04-2006, 05:11 PM
Your welcome :)

Here's a link to a kb article regarding getting usernames from the app/OS
http://vbaexpress.com/kb/getarticle.php?kb_id=768

software786
09-28-2006, 09:33 AM
If you get this message when clicking on an Excel hyperlink in a Browser:
"This document has been modified. Do you want to save changes?"

You can get rid of this message by doing the following:

In either of the following events:

1. For a Worksheet: Event Name = FollowHyperlink

2. For a Workbook: Event Name = SheetFollowHyperlink

Add the following statement:

ThisWorkbook.Saved = True

VBdisAble
10-12-2008, 06:14 PM
2. For a Workbook: Event Name = SheetFollowHyperlink

Add the following statement:

ThisWorkbook.Saved = True

Hi software786,

Thanks for your help. I've got the same problem and added the above code in the SheetFollowHyperlink event as you advised.

Problem is that this event only triggers if the hyperlink is located in a cell on the worksheet. In my workbook, I have a number of icons that have hyperlinks to different parts of the workbook. As a result, the SheetFollowHyperlink event doesn't get called when these objects are clicked... and then the annoying "Changes have been made" box pops up.

Do you have any ideas on how to get around this please?

Thanks.

eric8005
01-19-2009, 04:47 PM
VBdisAble, you might be able to Right-click the icon and Assign Macro.

Then, have the VBA do what you wanted the hyperlink to do.

VBdisAble
01-19-2009, 05:00 PM
Thanks, eric8005. That is exactly what I did to work around the problem. The only thing is that you don't get a screentip when you scroll over the button like you do with hyperlinks :(