The Import Windows Management Instrumentation (WMI) class method, in Configuration Manager, overwrites any matching records of program-compliance data in the database. It also returns the number of records that were imported.

The filter process is case-insensitive. Do not include either filter (SourceFilter or TypeFilter) if you want to import all the compliance data.
UInt32 Import(
	 String ComplianceData, 
	 String SourceFilter, 
	 String TypeFilter,
	 Boolean ReportErrors,
	 UInt32 TotalRecordsProcessed



Data type: StringQualifiers: [in]Tab-delimited compliance data. The data is passed as a null-terminated string. Each record terminates with a carriage return and line feed character.

Data type: StringQualifiers: [in, optional]Source filter used by the method to import only those records that match the source value, limiting them to a single data source.

Data type: StringQualifiers: [in, optional]If a compliance type, such as "Year 2000", is set in TypeFilter, the method imports only those records matching the compliance Type property.

Data type: BooleanQualifiers: [in, optional]true, by default, if the import process stops on the first error and performs a rollback on the database, that is, removes all inserted and updated compliance data. If this parameter is set to false, the import process continues when errors occur.

Data type: UInt32Qualifiers: [out]Total number of records imported, valid or invalid.

Return Values

A UInt32 data type that indicates the number of valid records imported.

The method sets the ErrorCode property of SMS_ExtendedStatus Class to 0x40441218 (E_INT_READ_LINE | R_FIELDNO) when the method is unable to process a record in the file. The ObjectInfo property identifies the record number (excluding blank lines) that is in error. The CauseInfo property contains a number representing the field in the record that caused the error. The field numbers start from zero.


Runtime Requirements

Development Requirements

See Also

Send comments about this topic to Microsoft.