Microsoft KB Archive/826418

= How to troubleshoot damaged drawings in Visio =

Article ID: 826418

Article Last Modified on 1/27/2007

-

APPLIES TO


 * Microsoft Office Visio Professional 2007
 * Microsoft Office Visio Standard 2007
 * Microsoft Office Visio Professional 2003
 * Microsoft Office Visio Standard 2003
 * Microsoft Visio 2002 Professional Edition
 * Microsoft Visio 2002 Standard Edition
 * Microsoft Visio for Enterprise Architects 2002

-





SUMMARY
''This article discusses how to troubleshoot damaged drawings in Microsoft Office Visio 2007, Microsoft Office Visio 2003, and Microsoft Visio 2002. This article describes some symptoms that may indicate that the drawing that you are working with in Visio is damaged.

Additionally, this article lists some recovery methods that you can use on the damaged drawing. They include general troubleshooting methods, methods to try if you can or cannot open the drawing, and methods to help prevent damage that may occur to drawings.''



IN THIS TASK

 * INTRODUCTION
 * Overview
 * General troubleshooting methods
 * Start Visio without Automation events and without Microsoft Visual Basic for Applications
 * Start Microsoft Windows in Safe Mode
 * Methods to try if you cannot open the drawing
 * Method 1: Drag the drawing file to the icon for the Visio.exe file
 * Method 2: Double-click the drawing file in Microsoft Windows Explorer
 * Method 3: Open the temporary copy of the drawing file
 * Method 4: Use the Microsoft Visio Viewer to open the drawing
 * Method 5: Copy the drawing file to another computer
 * Method 6: Copy the drawing file to another disk on your computer
 * Method 7: Detect and repair errors on the hard disk
 * Methods to try if you can open the drawing
 * Method 1: Drag the drawing file to the icon for the Visio.exe file
 * Method 2: Insert the drawing to a new blank drawing
 * Methods to try to help prevent damage to drawings
 * Optimize the AutoRecovery setting in Visio
 * Make sure that the power supply is consistent
 * Back up your data
 * Work with your data locally
 * REFERENCES



Overview
If you experience unexpected behavior when you work with a Visio drawing, the Visio drawing may be damaged. You may receive the following error messages if you have a damaged drawing:  &quot;Invalid Page Fault,&quot; &quot;General Protection Fault,&quot; or &quot;Illegal Instruction&quot; error messages Error messages that are similar to one of the following when you open a drawing:

An error (100) occurred during the action Open

Visio cannot open the file because it’s not a Visio file or it has become corrupted.

 &quot;Out of memory&quot; error messages or error messages that indicate low system resources

Note These error messages do not always mean that your drawing is damaged. However, if you repeatedly experience one or more of these error messages when you work with a particular drawing, that drawing may be damaged.

This article lists some methods that you can use to try to recover the damaged drawing. The methods that are described in this article do not guarantee the successful recovery of a damaged drawing. Sometimes, depending on the type of damage, you may not be able to recover any data. You may have to re-create the drawing or restore the drawing from your backup files.

back to the top

Start Visio without Automation events and without Microsoft Visual Basic for Applications
Start Visio without Automation events and without Visual Basic for Applications. To do this, use one of the following methods:

Method 1: Microsoft Office Visio 2007
 * 1) Start Visio normally.
 * 2) On the Tools menu, click Trust Center.
 * 3) Click Macro Settings, and then click Disable all macros without notification.
 * 4) Click Add-ins.
 * 5) Click to select the Disable all Application Add-ins check box.
 * 6) Click OK.
 * 7) Exit Visio, and then restart Visio.

Method 2: Microsoft Office Visio 2003 and earlier versions of Visio
 * 1) Start Visio normally.
 * 2) Use one of the following procedures, depending on the version of Visio that you are running:
 * 3) * If you are running Visio 2003, click Options on the Tools menu, and then click the Security tab.
 * 4) * If you are running Visio 2002, click Options on the Tools menu, and then click the Advanced tab.
 * 5) Do the following:
 * 6) * Click to clear the Enable Microsoft Visual Basic for Applications check box.

Note After you click to clear the Enable Microsoft Visual Basic for Applications check box, the Enable Microsoft Visual Basic for Applications project creation check box and the Load Microsoft Visual Basic for Applications project from text check box becomes unavailable.
 * 1) * Click to clear the Enable COM add-ins check box.
 * 2) * Click to clear the Enable Automation events check box.
 * 3) Click OK, and then quit Visio.
 * 4) Restart Visio.

back to the top

Start Windows in Safe Mode
Start Windows in Safe Mode. To do this:

Note Because there are several versions of Microsoft Windows, the following steps may be different on your computer. If they are, see your product documentation to complete these steps.
 * 1) Shut down, and then restart your computer.
 * 2) When you see the &quot;Please select the operating system to start&quot; message, press F8.
 * 3) On the Windows Advanced Options menu, use the ARROW keys to select Safe Mode, and then press ENTER.
 * 4) If you have a dual-boot or multi-boot computer, select the appropriate operating system from the list that appears, and then press ENTER.
 * 5) Start Visio, and then try to open your drawing.

For more information about Safe Mode, click the following article numbers to view the articles in the Microsoft Knowledge Base:

315222 A description of the Safe Mode Boot options in Windows XP

202485 Description of Safe Boot Mode in Windows 2000

180902 How to start a Windows 98-based computer in Safe Mode

back to the top

Method 1: Drag the drawing file to the Visio.exe file icon
Drag the drawing file to the icon that represents the Visio.exe file. To do this:  Quit Visio. Start Microsoft Windows Explorer, and then locate the Visio.exe file on your hard disk. If you installed Visio to the default location, the Visio.exe file is located in one of the following folders, depending on the version of Visio that you are running:  If you are running Visio 2007, the Visio.exe file is located in the following folder:



If you are running Visio 2003, the Visio.exe file is located in the following folder:



</li> If you are running Visio 2002, the Visio.exe file is located in the following folder:



Note If you installed Visio to a folder that is different from the default installation location, the path of the Visio.exe file is different on your computer.</li></ul> </li> In Windows Explorer, locate the drawing file that you want to open.</li> Drag the drawing file to the icon that represents the Visio.exe file.</li></ol>

back to the top

Method 2: Double-click the drawing file in Windows Explorer
Try to open the drawing file by using Windows Explorer. To do this:
 * 1) Quit Visio.
 * 2) Start Windows Explorer, and then locate the drawing file that you want to open.
 * 3) Double-click the drawing file.

back to the top

Method 3: Open the temporary copy of the drawing file
When you modify a Visio drawing, a temporary copy of the drawing file is created. The temporary copy of the drawing file is named ~$$ .~vsd. The temporary copy of the drawing file is typically created and stored in the same folder as where your drawing is located.

To open the temporary copy of the drawing file, do the following: <ol> Start Visio, and then open your drawing.</li> Start Windows Explorer, and then locate the folder where your drawing is stored. Look in this folder for the temporary copy of the drawing file. The temporary copy of the drawing file is named ~$$ .~vsd.

Note If the temporary copy of the drawing file is not located in the folder where your drawing is stored, search the hard disk for the temporary copy of the drawing file.

To search the hard disk for the temporary copy of the drawing file, do the following:

Note Because there are several versions of Microsoft Windows, the following steps may be different on your computer. If they are, see your product documentation to complete these steps. <ol style="list-style-type: lower-alpha;"> Click Start, and then click Search.</li> Click All files and folders.</li> In the All or part of the file name box, type ~$$ .~vsd, and then click Search.</li></ol> </li> Change the extension of the temporary copy of the drawing file to .vsd. To do this: <ol style="list-style-type: lower-alpha;"> Right-click the temporary copy of the drawing file, and then click Rename.</li> Change the extension of the temporary copy of the drawing file from ~.vsd to .vsd.</li></ol> </li> Try to open the temporary copy of the drawing file that you renamed.</li></ol>

back to the top

Method 4: Use the Microsoft Office Visio Viewer to open the drawing
Install Microsoft Office Visio Viewer 2003 or Microsoft Visio Viewer 2002, and then use Visio Viewer to open and view your drawing. When you install Visio Viewer 2003, you can use Microsoft Internet Explorer 5.0 or a later version of Internet Explorer to view Visio drawings and diagrams that are created with Visio 2007, Visio 2003, Visio 2002, Microsoft Visio 2000, or Microsoft Visio 5. For more information about Visio Viewer 2007, visit the following Microsoft Web site:

http://www.microsoft.com/downloads/details.aspx?FamilyID=d88e4542-b174-4198-ae31-6884e9edd524&DisplayLang=en

When you install Visio Viewer 2003, you can use Microsoft Internet Explorer 5.0 or a later version of Internet Explorer to view Visio drawings and diagrams that are created with Visio 2003, Visio 2002, Microsoft Visio 2000, or Microsoft Visio 5. For more information about Visio Viewer 2003, visit the following Microsoft Web site:

http://www.microsoft.com/downloads/details.aspx?amp;amp;displaylang=en&familyid=3fb3bd5c-fed1-46cf-bd53-da23635ab2df&displaylang=en

When you install Visio Viewer 2002, you can use Internet Explorer 5.0 or a later version of Internet Explorer to view Visio drawings and diagrams that are created with Visio 2002, Visio 2000, or Visio 5. For more information about the Visio 2002 Viewer, visit the following Microsoft Web site:

http://www.microsoft.com/downloads/details.aspx?familyid=8fad9237-c0a7-4b80-a5df-46ce54dad2df&displaylang=en

If you can open your drawing in the Visio Viewer, the installation of Visio on your computer may be damaged or your drawing may contain one or more objects that may be damaged.

back to the top

Method 5: Copy the drawing file to another computer
Copy the drawing file to another computer that has Visio installed on it. If you can open your drawing on that computer, save the drawing file to a different folder on the hard disk of that computer, and then copy the drawing file back to the original computer.

back to the top

Method 6: Copy the drawing file to another disk on your computer
Windows may not be able to read the drawing file from where the drawing file is currently saved. Copy the drawing file to another disk on your computer. For example, copy the file from a floppy disk to the hard disk. After you copy the drawing file to a different disk on your computer, try to open the drawing file.

Note If you cannot copy the drawing file from the disk where the drawing file is saved, the drawing file may be cross-linked with other files or folders, or the drawing file may be located in a damaged sector of the disk. To troubleshoot this issue, follow the steps in Method 7.

back to the top

Method 7: Detect and repair errors on the hard disk
If you are running Microsoft Windows Server 2003, Microsoft Windows XP, Microsoft Windows 2000, or Microsoft Windows NT 4.0, use the Check Disk tool to detect file system errors or bad sectors on your hard disk.

For more information, click the following article numbers to view the articles in the Microsoft Knowledge Base:

315265 How to perform disk error checking in Windows XP

156571 How to perform Scandisk in Windows

If you are running Microsoft Windows Millennium Edition (Me) or Microsoft Windows 98, use the Scandisk tool to detect file system errors or bad sectors on your hard disk.

For more information, click the following article number to view the article in the Microsoft Knowledge Base:

186365 Description of ScanDisk for Windows (Scandskw.exe) in Windows 98/Me

Note Although the Check Disk tool or the ScanDisk tool can detect and repair file-system errors or bad sectors on the hard disk, Visio may still not be able to open or read the file.

back to the top

Method 1: Save the file as an XML drawing
Save the drawing as an XML drawing (.vdx file), and then save the XML drawing as a drawing (.vsd file). To do this:
 * 1) Start Visio, and then open your drawing.
 * 2) On the File menu, click Save As.
 * 3) In the Save As dialog box, click XML Drawing (*.vdx) in the Save as type box, and then type a file name in the File name box. Specify a location where you want to save the drawing file, and then click Save.
 * 4) Close all the drawings that are currently open.
 * 5) On the File menu, click Open.
 * 6) Locate the XML drawing (.vdx) that you saved earlier in step 3, and then click Open.
 * 7) On the File menu, click Save As.
 * 8) In the Save As dialog box, click Drawing (*.vsd) in the Save as type box, and then type a file name in the File name box. Specify a location where you want to save the drawing file, and then click Save.
 * 9) Close the drawing.
 * 10) On the File menu, click Open
 * 11) Locate the drawing (.vsd file) that you saved earlier in step 8, and then click Open.

back to the top

Method 2: Insert the drawing to a new blank drawing
Insert the drawing to a new blank drawing. To do this:
 * 1) Start Visio.
 * 2) On the File menu, point to New, and then click New Drawing.
 * 3) On the Insert menu, click Object.
 * 4) Click Create from file, and then click Browse.
 * 5) Click the drawing, click Open, and then click OK.
 * 6) Depending on your situation, determine whether the drawing file is damaged or whether there is another problem.
 * 7) * If you receive an &quot;Error 3400&quot; error message, the drawing file may be damaged. Use the methods that are described in this article to try to recover the drawing.
 * 8) * If you do not receive an &quot;Error 3400&quot; error message, there may be another issue that may be preventing Visio from opening the drawing. For example, a conflict may exist between certain components on the computer that prevent Visio from opening the drawing.

back to the top

Methods to try to help prevent damage to drawings
You cannot prevent all corruption that may occur to files. Hard disks may wear out, power supplies may fail, and other unforeseeable events may occur that cause files to become damaged. The following tips and suggestions may help reduce the number of damaged files that occur in Visio and in other programs.

Optimize the AutoRecover setting in Visio
Configure the AutoRecover setting to a value that works for you. If your computer stops responding or if you lose power unexpectedly, Visio opens the AutoRecovery file the next time that you start the program. The AutoRecovery file may contain unsaved information that would otherwise be lost from your original drawing file. If your original drawing file was damaged, you may be able to recover information from the AutoRecovery file.

To configure the AutoRecover setting in Visio:
 * 1) Start Visio.
 * 2) On the Tools menu, click Options.
 * 3) Click the Save tab or the Save/Open tab.
 * 4) Select the Save AutoRecover info every check box, and then specify the time in minutes that you want. By default, the AutoRecover setting is set for 10 minutes.
 * 5) Click OK.

back to the top

Make sure that the power supply is consistent
A power supply that is not consistent can cause damage to files, even if you do not lose power. A power supply that spikes or that is not sufficient can affect the read process and write processes on your computer, and may cause damage. If the power supply in your area is inconsistent, use a surge protector. Surge protectors can help prevent damage on your computer if power spikes occur. You may also consider using an uninterruptible power supply (UPS). UPS units supply your computer with power even if there is a power outage. Contact your hardware vendor for more information about how to obtain either of these devices.

back to the top

Back up your data
Make sure that you back up your data regularly. For example, store a backup copy of your drawing on a different volume on the hard disk. Or, depending on your requirements and on your environment, implement other backups or other fault-tolerant solutions on your computer. Some fault-tolerant solutions, such as Redundant Array of Independent Disks (RAID), are typically only practical for larger networks. Other backup options include the following:
 * Tape backup
 * CD backup
 * Mirrored volume
 * RAID-5 volume

back to the top

Work with your data locally
If you work in a network environment and you experience corruption frequently, you may want to consider copying your files to your local computer before you open the file or before you modify the file. Copy the file to your desktop by using My Computer or by using Windows Explorer. When you work with files that are stored on your local computer, you prevent read issues or write issues that may be caused by network connectivity issues such as the following:
 * Slow network connections
 * Dropped network connections
 * Spikes in network traffic

You may also want to consider working from the hard disk and not working from removable media such as a floppy disk or a ZIP drive. The more media and the more device drivers that are involved in a save operation, the more the increased chance of file damage.

back to the top

<div class="references_section">