Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Annotations with Imaging for Windows Control
Message
De
02/10/2008 16:57:53
June Kendrick
Kendrick Associates, Inc.
New York, États-Unis
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Contrôles ActiveX en VFP
Titre:
Annotations with Imaging for Windows Control
Versions des environnements
Visual FoxPro:
VFP 6 SP5
OS:
Windows XP
Network:
Windows 2003 Server
Database:
MS SQL Server
Divers
Thread ID:
01352422
Message ID:
01352422
Vues:
92
Has anyone used the Annotations feature of the Imaging for Windows control?

I'm trying to add an annotation to an image programmatically. I'm trying to show a different character on each page of a multi-page image. Sometimes it works, and sometimes it gives me an "Invalid Annotation Type" error. The code below is basically what I'm doing. The StampText and the Draw Location vary.
I've tried using Annotation groups, and even then, sometimes it works and sometimes it doesn't.
WITH THISFORM.OleImageEdit
	* must display it before annotating it
	.Display()
	
	* stamp it
	.AnnotationType = wiTextStamp

	* with these characteristics
	STORE .F. TO llBold, llItalic, llUnderline, llStrikeThrough
	lcName = 'Arial'
	lnSize = 128

	WITH ThisForm.OleImageEdit.AnnotationFont
		.Bold = llBold
		.Italic = llItalic
		.Name = lcName
		.Size = lnSize
		.Underline = llUnderline
		.StrikeThrough = llStrikeThrough
	ENDWITH
	.AnnotationFontColor = RGB(128,255,128)	&& green
	.AnnotationStampText = 'H'

	* at this location
	lnX = 90
	.Draw(10, lnX)

	* need to save page in order to keep annotation graphics
	llZoom = .F.
	.Save(llZoom)

	* annotations don't show in thumbnails so
	* generate thumbnail to cause annotation graphic to show
	ThisForm.OleThumbNails.GenerateThumb(1, .Page)
ENDWITH
Any and all ideas would be appreciated.

Thanks,
June
Répondre
Fil
Voir

Click here to load this message in the networking platform