Hide Table of Contents
CriticalDataRepair Property (IDocumentSpecification)

Gets or sets whether to automatically repair critical data errors in the file to be opened.

.NET Syntax

Visual Basic (Declaration) 
Property CriticalDataRepair As System.Boolean
Visual Basic (Usage) 
Dim instance As IDocumentSpecification
Dim value As System.Boolean
 
instance.CriticalDataRepair = value
 
value = instance.CriticalDataRepair
C# 
System.bool CriticalDataRepair {get; set;}
C++/CLI 
property System.bool CriticalDataRepair {
   System.bool get();
   void set ( &   System.bool value);
}

Property Value

True to automatically repair critical data errors, false to not

Remarks

This property is valid only if IDocumentSpecification::Silent is set to true.

If you set this property to true, and the file to open has critical data corruption:

  • Critical data repair proceeds.
  • ISldWorks::OpenDoc7 returns the document with warning, swFileLoadWarning_e.swFileLoadWarning_CriticalDataRepair.
  • All non-critical data errors are ignored, because repairing critical errors obliterates all non-critical data in the file.

If set to true, this property instructs SOLIDWORKS to repair critical data by importing Parasolid bodies into a new file. The repaired file contains only Parasolid bodies.

The following files are created in c:\Users\user\AppData\Local\Temp:

  • Repaired_file_name.sld*
  • Backup of file_name.sld*

If you set this property to false, and the file to open has critical data corruption:

  • The document does not open.
  • ISldWorks::OpenDoc7 fails and returns null with error code, swFileLoadError_e.FileRequiresCriticalDataRepair.

Use IDocumentSpecification::AutoRepair to handle non-critical data corruption of files.

For C++ only, VARIANT_TRUE (-1) automatically repairs the file, and VARIANT_FALSE (0) does not.

See Also

Availability

SOLIDWORKS 2018 FCS, Revision Number 26.0


Provide feedback on this topic

SOLIDWORKS welcomes your feedback concerning the presentation, accuracy, and thoroughness of the documentation. Use the form below to send your comments and suggestions about this topic directly to our documentation team. The documentation team cannot answer technical support questions. Click here for information about technical support.

* Required

 
*Email:  
Subject:   Feedback on Help Topics
Page:   CriticalDataRepair Property (IDocumentSpecification)
*Comment:  
*   I acknowledge I have read and I hereby accept the privacy policy under which my Personal Data will be used by Dassault Systèmes

Print Topic

Select the scope of content to print:

x

We have detected you are using a browser version older than Internet Explorer 7. For optimized display, we suggest upgrading your browser to Internet Explorer 7 or newer.

 Never show this message again
x

Web Help Content Version: API Help (English only) 2018 SP05

To disable Web help from within SOLIDWORKS and use local help instead, click Help > Use SOLIDWORKS Web Help.

To report problems encountered with the Web help interface and search, contact your local support representative. To provide feedback on individual help topics, use the “Feedback on this topic” link on the individual topic page.