Class PropVariant
Inheritance
Inherited Members
Namespace: Syncfusion.CompoundFile.DocIO.Native
Assembly: Syncfusion.DocIO.Base.dll
Syntax
public class PropVariant : IDisposable, IPropertyData
Constructors
PropVariant()
Default constructor.
Declaration
public PropVariant()
PropVariant(tagSTATPROPSTG, IPropertyStorage, Boolean)
Reads data from IPropertyStorage.
Declaration
[CLSCompliant(false)]
public PropVariant(tagSTATPROPSTG propInfo, IPropertyStorage propStorage, bool bBuiltIn)
Parameters
Type | Name | Description |
---|---|---|
Syncfusion.CompoundFile.DocIO.Native.tagSTATPROPSTG | propInfo | Property description. |
IPropertyStorage | propStorage | IPropertyStorage to read data from. |
System.Boolean | bBuiltIn | Indicates whether property is built-in or not. |
PropVariant(IntPtr)
Creates PropVariant with data pointed by ptr.
Declaration
public PropVariant(IntPtr ptr)
Parameters
Type | Name | Description |
---|---|---|
System.IntPtr | ptr |
Fields
DEF_FILETIME_TICKS_DIFFERENCE
Difference in ticks of FILETIME and DateTime.
Declaration
public const long DEF_FILETIME_TICKS_DIFFERENCE = 504911232000000000L
Field Value
Type | Description |
---|---|
System.Int64 |
FirstIntOffset
Offset to the first int of the data.
Declaration
public const int FirstIntOffset = 8
Field Value
Type | Description |
---|---|
System.Int32 |
PropVariantSize
Size of the native windows PROPVARIANT structure.
Declaration
public static readonly int PropVariantSize
Field Value
Type | Description |
---|---|
System.Int32 |
SecondIntOffset
Offset to the second int of the data.
Declaration
public static readonly int SecondIntOffset
Field Value
Type | Description |
---|---|
System.Int32 |
TYPE_OFFSET
Offset to the type of the PropVariant.
Declaration
public const int TYPE_OFFSET = 0
Field Value
Type | Description |
---|---|
System.Int32 |
Properties
AsciiString
Fills PropVariant with string value.
Declaration
public string AsciiString { get; set; }
Property Value
Type | Description |
---|---|
System.String |
Bool
Fills PropVariant with bool value.
Declaration
public bool Bool { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
DateTime
Fills PropVariant with FILETIME value.
Declaration
public DateTime DateTime { get; set; }
Property Value
Type | Description |
---|---|
System.DateTime |
Double
Fills PropVariant with double value.
Declaration
public double Double { get; set; }
Property Value
Type | Description |
---|---|
System.Double |
FileTime
Fills PropVariant with FILETIME value.
Declaration
public FILETIME FileTime { get; set; }
Property Value
Type | Description |
---|---|
System.Runtime.InteropServices.ComTypes.FILETIME |
Id
Gets property id.
Declaration
public int Id { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 |
Int
Fills PropVariant with integer value.
Declaration
public int Int { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 |
Int16
Gets or sets the int16.
Declaration
public short Int16 { get; set; }
Property Value
Type | Description |
---|---|
System.Int16 | The int16. |
Int32
Fills PropVariant with integer value.
Declaration
public int Int32 { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 |
IntPtr
Gets / sets PropVariant memory.
Declaration
public IntPtr IntPtr { get; set; }
Property Value
Type | Description |
---|---|
System.IntPtr |
IsLinkToSource
Indicates whether it is property or just link to source of some property. Read-only.
Declaration
public bool IsLinkToSource { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Name
Gets / sets property name.
Declaration
public string Name { get; set; }
Property Value
Type | Description |
---|---|
System.String |
ParentId
Returns id of the parent property. Read-only.
Declaration
public int ParentId { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
PropId
ID of the property that will be written into property storage.
Declaration
public PIDSI PropId { get; set; }
Property Value
Type | Description |
---|---|
PIDSI |
PropId2
Same as PropId.
Declaration
public PIDDSI PropId2 { get; set; }
Property Value
Type | Description |
---|---|
PIDDSI |
String
Fills PropVariant with string value.
Declaration
public string String { get; set; }
Property Value
Type | Description |
---|---|
System.String |
Type
Sets type of the variant. Write-only.
Declaration
public VarEnum Type { get; set; }
Property Value
Type | Description |
---|---|
System.Runtime.InteropServices.VarEnum |
Value
Returns value of the property. Read-only.
Declaration
public object Value { get; }
Property Value
Type | Description |
---|---|
System.Object |
Methods
Dispose()
Performs tasks associated with freeing, releasing, or resetting unmanaged resources.
Declaration
public void Dispose()
Finalize()
Finilizer.
Declaration
protected void Finalize()
GetObjectArray()
Returns an array of objects.
Declaration
public object[] GetObjectArray()
Returns
Type | Description |
---|---|
System.Object[] |
GetStringArray()
Returns array of strings.
Declaration
public string[] GetStringArray()
Returns
Type | Description |
---|---|
System.String[] |
Read(IPropertyStorage, Boolean)
Reads information from the storage.
Declaration
[CLSCompliant(false)]
public void Read(IPropertyStorage storProp, bool bBuiltIn)
Parameters
Type | Name | Description |
---|---|---|
IPropertyStorage | storProp | Storage to read from. |
System.Boolean | bBuiltIn | Indicates whether property is built-in. |
Read(tagSTATPROPSTG, IPropertyStorage, Boolean)
Reads information from the storage.
Declaration
[CLSCompliant(false)]
public void Read(tagSTATPROPSTG propInfo, IPropertyStorage storProp, bool bBuiltIn)
Parameters
Type | Name | Description |
---|---|---|
Syncfusion.CompoundFile.DocIO.Native.tagSTATPROPSTG | propInfo | Property information. |
IPropertyStorage | storProp | Storage to read from. |
System.Boolean | bBuiltIn | Indicates whether property is built-in. |
SetBlob(Byte[])
Sets Blob property value.
Declaration
public void SetBlob(byte[] value)
Parameters
Type | Name | Description |
---|---|---|
System.Byte[] | value | Value to set. |
SetName(String)
Sets property name.
Declaration
public void SetName(string strName)
Parameters
Type | Name | Description |
---|---|---|
System.String | strName | Name to set. |
SetObjectArray(Object[])
Fills PropVariant with array of objects.
Declaration
public void SetObjectArray(object[] value)
Parameters
Type | Name | Description |
---|---|---|
System.Object[] | value |
SetStringArray(String[])
Fills PropVariant with array of strings.
Declaration
public void SetStringArray(string[] value)
Parameters
Type | Name | Description |
---|---|---|
System.String[] | value |
SetValue(Object, PropertyType)
Sets property value.
Declaration
public bool SetValue(object value, PropertyType type)
Parameters
Type | Name | Description |
---|---|---|
System.Object | value | Value to set. |
PropertyType | type | Type of the property to set. |
Returns
Type | Description |
---|---|
System.Boolean |
Write(IPropertyStorage)
Writes variant to the property storage.
Declaration
[CLSCompliant(false)]
public void Write(IPropertyStorage storProp)
Parameters
Type | Name | Description |
---|---|---|
IPropertyStorage | storProp | Property storage that will receive PropVariant value. |