Accusoft NotateXpress 13
GetAnnIntoVariant Method
A variant to receive the annotation data.
The address of a long to receive the size of the byte array copied to the variant.
Description
Gets the current annotation data into a variant byte array.
Syntax
Visual Basic
Public Sub GetAnnIntoVariant( _
   ByRef v As Variant, _
   ByRef count As Long _
) 
Parameters
v
A variant to receive the annotation data.
count
The address of a long to receive the size of the byte array copied to the variant.
Remarks

The variant data will be in the format of the AnnotationType

The exception is that the NX_AnnotationType_I4W is not honored and will automatically try to use NX_AnnotationType_NXP 

Example
PrivateSubSaveAnnotation()
DimvAsVariant
DimcbSizeAsLong
DimrsAsRecordset

NotateXpress1.GetAnnIntoVariantv,cbSize
'--------------------------------
'oncetheannotationdataisinavariant,
'youcanstoreitintoadatabase.
'youcanverifythelengthbyeithertesting
'cbSizeorbyLen(v)
'--------------------------------
'ifyouwanttosavethese,youshouldaccess
'thesevaluesfromtherespectiveproperties
'--------------------------------
'ThefollowingassumesthevariableDBrepresents
'andopenAccessdatabasecontaininga
'tablenamedAnnotations,andwithfields
'namedImgFileandNXPData.TheNXPDatafield
'isdefinedasaMemofield(dbLongBinary)
'--------------------------------
Setrs=DB.OpenRecordset("Annotations",dbOpenDynaset)

rs.AddNew
'--------------------------------
'storefilenameofcurrentimagefile
'--------------------------------
rs!ImgFile=App.Path&gCurrentImage
'--------------------------------
'nowstoretheannotationdatafromourvariant
'--------------------------------
rs!NXPData.AppendChunkv
rs.Update
rs.Close
Setrs=Nothing

EndSub
See Also

NotateXpress Object  | NotateXpress Members  | Saving

 

 


©2018. Accusoft Corporation. All Rights Reserved.

Send Feedback