Office Picture insert ? Example

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi all,

I need an example to insert an Picture in an opend Word Document. My Code
doesn t work.

I tried :

object vk_missing = Type.Missing;
wordapp.Selection.Range.InlineShapes.AddPicture(@"C:\logo.bmp", ref
vk_missing, ref vk_missing, ref vk_missing);

The Document is successfully open, i can insert text's... the data ist saved
after doing this, but no effekt.

I use : VS2005, Office2003 and Win2k

How can I insert a picture from a file at position X,Y on every paper ? Can
someone give me an examplecode, please ?


Thx and Greets

Fabian
 
that should be working for you if the bitmap is available and you have read
access to it. also have a look at the optional parameters to make sure you
are passing in correct input values.

--
Regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
The Microsoft Office Web Components Black Book with .NET
Now Available @ www.lulu.com/owc
Forth-coming VSTO.NET - Wrox/Wiley 2006
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top