Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Automating MicroSoft Document Imaging 2003
Message
De
09/12/2003 07:11:07
 
 
À
13/11/2003 15:37:44
Glenn Brown
Federal Reserve Bank of Dallas
Dallas, Texas, États-Unis
Information générale
Forum:
Microsoft Office
Catégorie:
Autre
Divers
Thread ID:
00849657
Message ID:
00857118
Vues:
26
>I need to transfer a lot of document tif images from an old application to a new application. Some of the document images need to be combined. I’m trying to use automation to open up and stitch them together. I’m working with Microsoft Document Imaging 2003. The software really does not have any documentation about automating it. I have tried to find documentation on MSDN and fail.
>
>What I want to do is to:
>(1) Open the image automation server.
>(2) Make it visible.
>(3) Open a document image.
>(4) Add a document image to the bottom of the old image and save it as a new image.
>
>Can you help me with this? Thanks

Check out whether this Visual FoxPro code is good for you:
**************************************************
*-- Form:         modiform 
*-- ParentClass:  form
*-- BaseClass:    form
*-- Time Stamp:   12/09/03 01:58:04 PM
*
modiform = NewObject("modiform")
modiform.Visible = .T.

DEFINE CLASS modiform AS form


	Top = 0
	Left = 0
	Height = 300
	Width = 375
	DoCreate = .T.
	Caption = "modiform"
	WindowState = 0
	Name = "modiform"


	ADD OBJECT modi_docview AS olecontrol WITH ;
		OleClass = "MiDocViewer.MiDocView.1", ;
		Top = 0, ;
		Left = 0, ;
		Height = 260, ;
		Width = 375, ;
		Name = "MODI_DocView"
		


	ADD OBJECT proceedbtn AS commandbutton WITH ;
		Top = 265, ;
		Left = 48, ;
		Height = 27, ;
		Width = 84, ;
		Caption = "Proceed", ;
		Name = "ProceedBtn"


	PROCEDURE Resize
		ThisForm.MODI_DocView.Height = Max(ThisForm.Height-40, 0)
		ThisForm.MODI_DocView.Width = ThisForm.Width
		ThisForm.ProceedBtn.Top = ThisForm.MODI_DocView.Height+5
	ENDPROC


	PROCEDURE proceedbtn.Click
		Local MODI_Document As MODI.Document
		Local MODI_Image1 As MODI.IImage
		Local MODI_Image2 As MODI.IImage

		MODI_Document = CreateObject("MODI.Document")
		MODI_Document.Create(GetFile("TIF"))
		MODI_Image1 = MODI_Document.Images.Item(0)
		MODI_Document.Close(.F.)

		MODI_Document.Create(GetFile("TIF"))
		MODI_Image2 = MODI_Document.Images.Item(0)
		MODI_Document.Images.Add(MODI_Image1, MODI_Image2)

		ThisForm.MODI_DocView.Document = MODI_Document 
		MODI_Document.SaveAs("C:\test.tif")
		Wait window
		ThisForm.MODI_DocView.FileName = ""
	ENDPROC


ENDDEFINE
*
*-- EndDefine: modiform
**************************************************
Zlatin Zlatev,
MCSD (VS6)

Make solutions, not programs!

Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform