tv_kid Posted January 30, 2007 Posted January 30, 2007 Hi guys Is there a way of sending a command from FM to Word to insert an image at a specified point in the file? I have an rtf report created by exporting xml and transforming with an xslt sheet. However, I can't export the contents of a container field, so would like to be able to export to a specified location and then use a command to 'pick it up' and insert at a place holder in the rtf / word doc. Is this possible? Thanks in advance.
Newbies martygearbox Posted February 1, 2007 Newbies Posted February 1, 2007 I am trying to do something similar. I know that MS Word supports images embedded as HEX in RTF. I am trying to find a way to export the contents of a container as HEX and include in the RTF, but have not found a way yet.
Wim Decorte Posted February 5, 2007 Posted February 5, 2007 FM does not have direct commands for this. You'd have to use VBscript generated from FM that uses the Word Object Model. Then you can export from FM, have Word pick it up, insert it into the document and save the document as RTF. The heavy lifting here is through the VBscript talking "Word". (This can all be done invisible to the user). The challenge from FM is how to generate, execute and clean up the VBscript, returning any errors to FM so you can handle them. So the question really is: how much VBscript can you do? In other words: this is more of a Word coding skill than a FM coding skill.
Wim Decorte Posted February 5, 2007 Posted February 5, 2007 Oops, did not see that TV_kid is on OSX. The same logic applies since you'd have to use applescript instead of VBscript.
tv_kid Posted February 6, 2007 Author Posted February 6, 2007 So the question really is: how much VBscript can you do? In other words: this is more of a Word coding skill than a FM coding skill. I've never done any! I would be interested in learning, but not certain that I have the time at the moment, with trying to also learn xml, php .... I'm looking at other ways of achieving the report in question, but will certainly bear this in mind. As it happens, this particular report will be created on a pc most of the time, so it could utilise VBscript. Thanks for your advice.
Recommended Posts
This topic is 6542 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now