 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Jon Robertson Guest
|
Posted: Fri Dec 03, 2004 5:17 pm Post subject: Re: delphi x word - image in heading |
|
|
Marcelo wrote:
| Quote: | I need to insert in my application delphi x word a new document
with image in heading...
|
That's a big question, and only a little has to do with OleAutomation
in Delphi.
What specific help do you need?
--
Jon Robertson
Borland Certified Advanced Delphi 7 Developer
MedEvolve, Inc
http://www.medevolve.com
|
|
| Back to top |
|
 |
Marcelo Guest
|
Posted: Fri Dec 03, 2004 5:43 pm Post subject: delphi x word - image in heading |
|
|
I need to insert in my application delphi x word a new document with
image in heading...
Thank you
|
|
| Back to top |
|
 |
Marcelo Guest
|
Posted: Fri Dec 03, 2004 6:36 pm Post subject: Re: delphi x word - image in heading |
|
|
I open in wordapp a new aplicacão "word" and I would like that
automatically an image in heading was inserted, with I say this with
wordapp, wordocument....??
Jon Robertson <jon.robertson (AT) medevolve (DOT) dontspamme.com> escreveu nas notícias
de mensagem:41b0adbd$1 (AT) newsgroups (DOT) borland.com...
| Quote: | Marcelo wrote:
I need to insert in my application delphi x word a new document
with image in heading...
That's a big question, and only a little has to do with OleAutomation
in Delphi.
What specific help do you need?
--
Jon Robertson
Borland Certified Advanced Delphi 7 Developer
MedEvolve, Inc
http://www.medevolve.com
|
|
|
| Back to top |
|
 |
Deborah Pate (TeamB) Guest
|
Posted: Fri Dec 03, 2004 6:57 pm Post subject: Re: delphi x word - image in heading |
|
|
<
I need to insert in my application delphi x word a new
document with image in heading...
var
Hdr: HeaderFooter;
...
Hdr := Doc.Sections.Item(1).Headers.Item(
wdHeaderFooterPrimary);
Hdr.Range.InlineShapes.AddPicture('K:PicsTower.bmp',
EmptyParam, EmptyParam, EmptyParam);
--
Deborah Pate (TeamB) http://delphi-jedi.org
TeamB don't see posts sent via Google or ISPs
Use the real Borland server: newsgroups.borland.com
http://www.borland.com/newsgroups/genl_faqs.html
|
|
| Back to top |
|
 |
Jon Robertson Guest
|
Posted: Fri Dec 03, 2004 8:53 pm Post subject: Re: delphi x word - image in heading |
|
|
Marcelo wrote:
| Quote: | I open in wordapp a new aplicacco "word" and I would like that
automatically an image in heading was inserted, with I say this with
wordapp, wordocument....??
|
The Section object has a Headers property to access the headers of a
given section.
Use the Sections property of the Document object to get to the
approriate Section.
Once you have the Header, you could insert a picture several ways. We
use the InlineShapes object, like so:
FWordDoc.InlineShapes.AddPicture(FSigFile, LinkToFile,
SaveWithDocument, Anchor);
I've never done this in the header, but you should be able to use
Header.Range as the Anchor.
The VBA Word Help file is invaluable for learning the Word Automation
Object Model. Search for VBAWD*.CHM on your drive.
I also use the .PAS file generated for Word Type Library, as I can
search for a word such as "header" and see places where it is used.
If you still have questions, remember that the more specific your
question, the more specific the answer! :)
--
Jon Robertson
Borland Certified Advanced Delphi 7 Developer
MedEvolve, Inc
http://www.medevolve.com
|
|
| Back to top |
|
 |
Jon Robertson Guest
|
Posted: Fri Dec 03, 2004 8:54 pm Post subject: Re: delphi x word - image in heading |
|
|
Deborah Pate (TeamB) wrote:
| Quote: | var
Hdr: HeaderFooter;
..
Hdr := Doc.Sections.Item(1).Headers.Item(
wdHeaderFooterPrimary);
Hdr.Range.InlineShapes.AddPicture('K:PicsTower.bmp',
EmptyParam, EmptyParam, EmptyParam);
|
Well, I think Deborah may have done that a time or two... :-P
--
Jon Robertson
Borland Certified Advanced Delphi 7 Developer
MedEvolve, Inc
http://www.medevolve.com
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|