![Copy image Copy image](copycode.gif)
![CopyHover image CopyHover image](copycodeHighlight.gif)
Deployment Tools Foundation
ValidateDelete Method (record)
Deployment Tools Foundation Namespaces ► Microsoft.Deployment.WindowsInstaller ► View ► ValidateDelete(Record)
Validates a record that will be deleted later, returning information about any errors.
![](collapse_all.gif)
C# | Visual Basic | Visual C++ |
public ICollection<ValidationErrorInfo> ValidateDelete( Record record )
Public Function ValidateDelete ( record As Record ) As ICollection(Of ValidationErrorInfo)
public: ICollection<ValidationErrorInfo>^ ValidateDelete( Record^ record )
![](collapse_all.gif)
- record (Record)
- the Record to be validated
![](collapse_all.gif)
ICollection<(Of <(<'ValidationErrorInfo>)>)>
null if the record is safe to delete; if another row refers to the primary keys of this row then error information is returned
null if the record is safe to delete; if another row refers to the primary keys of this row then error information is returned
![](collapse_all.gif)
Validation does not check for the existence of the primary keys of this row in properties or strings. Does not check if a column is a foreign key to multiple tables. Works with read-write and read-only records. This method cannot be used with a View containing joins.
See Modify(ViewModifyMode, Record) for more remarks.
Win32 MSI APIs: MsiViewModify, MsiViewGetError
![](collapse_all.gif)
Exception | Condition |
---|---|
InstallerException | the validation failed (for a reason other than invalid data) |
InvalidHandleException | the View handle is invalid |
Assembly: Microsoft.Deployment.WindowsInstaller (Module: Microsoft.Deployment.WindowsInstaller.dll) Version: 3.0.0.0 (3.9.1006.0)