Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Word Automation - insert textbox
Message
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Miscellaneous
Thread ID:
00812277
Message ID:
00812394
Views:
19
This message has been marked as the solution to the initial question of the thread.
Try this:
WITH oWord.ACTIVEDOCUMENT
.SHAPES.ADDTEXTBOX(1, 50, 50, 100, 100)
.shapes(.shapes.count).select
ENDWITH
with oword.selection
.Inlineshapes.AddPicture("D:\vfp6default\projects\epassquotebuilder\support\EPASS.jpg",.f.,.t.)
.TypeParagraph
.TypeText("Picture added")
endwith
>I have managed to create a textbox with this...
>
>WITH oWord.ACTIVEDOCUMENT
>.SHAPES.ADDTEXTBOX(1, 50, 50, 100, 100)
>ENDWITH
>
>
>but am unable to use .AddPicture - the VBA code I get is as follows...
>
>
> ActiveDocument.Shapes("Text Box 2").Select
>    Selection.InlineShapes.AddPicture FileName:="D:\vfp6default\projects\epassquotebuilder\support\EPASS.jpg", LinkToFile:=False, SaveWithDocument:=True
>
>
>Any ideas how to add pictures and text into the textboxes?
>
>Thanks
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform