Inventor General Discussion

Inventor General Discussion

Reply
Product Support
VinodBalasubramanian
Posts: 656
Registered: ‎09-30-2007
Message 11 of 14 (118 Views)

Re: How to apply a style to a picture using WordPictureWriter in ETO?

12-04-2011 10:59 PM in reply to: bsee1

Hi,

 

Can you send me a short video of your workflow and explain me on what is happening and what's your requirement. This might help me to understand your problem better.



Vinod Balasubramanian
Mentor
bsee1
Posts: 212
Registered: ‎11-14-2011
Message 12 of 14 (112 Views)

Re: How to apply a style to a picture using WordPictureWriter in ETO?

12-05-2011 07:06 AM in reply to: VinodBalasubramanian

Here is a link to download the screencap. It's only 30mb.
http://dl.dropbox.com/u/46698764/WordPictureWriter_Screencap.avi

 

In the video, I highlight the relevant code(shown below), then generate the document. After the document is generated, I click on a few pictures. They are hidden behind text and you can only see their outline. I then change one of the pictures to use the square text wrap style.

 

Here is the code I'm working with:

Child StationPicture As :WordPictureWriter, Quantity =    NumberofStations
Bookmark = "InsertPicture" + stringValue(child.index)
Placement = :Replace
PictureFile = nth(child.index,PictureFiles)
End Child

 

The problem is that these pictures need to be visible, and nothing I do in Inventor seems to be able to change that. When I tried to resolve the problem, I was under the impression I could use the style tag in Inventor to apply a Microsoft Word style to the picture. I tried using

style = wdWrapMergeSquare

 

It did not work. Here is the list of Microsoft Word styles I *thought* would work: http://msdn.microsoft.com/en-us/library/ff835490.aspx

 

In WordPictureWriter, is there ANY style that I can apply to an image by using style= ? Specifically, I need to be able to apply square text wrapping to a picture in a document generated from Inventor..

 

*****************************
Win7 x64 - 16gb ram
i7 3610qm
FirePro M4000

Inventor 2013
ETO 6.1
Product Support
VinodBalasubramanian
Posts: 656
Registered: ‎09-30-2007
Message 13 of 14 (88 Views)

Re: How to apply a style to a picture using WordPictureWriter in ETO?

12-11-2011 10:34 PM in reply to: bsee1

After reviewing the thread and the code, it appears that style parameter is common to all word writer elements, and refers to the style name to be applied to text or a picture element: “Normal”, “Heading 1”, “Heading 2”, “Title”, etc. In the picture case, it is not the specific word wrapping style around an image.

 

Have a look at the samples project, there is an Office Sample that has a picture writer example. The samples are installed to C:\Users\Public\Documents\Autodesk\Inventor ETO 2012\Inventor\Samples.

 

After reviewing the office sample, make sure the customer sets up/formats the image correctly in the template. There aren’t a lot of options for formatting in the child rule parameters.

 


______________________________________________________________

If my post answers your question, please click the "Accept as Solution" button. This helps everyone find answers more quickly!

 



Vinod Balasubramanian
Mentor
bsee1
Posts: 212
Registered: ‎11-14-2011
Message 14 of 14 (70 Views)

Re: How to apply a style to a picture using WordPictureWriter in ETO?

01-30-2012 06:05 AM in reply to: bsee1

For anyone else that experiences this problem, I came up with a workaround solution.  If you put a 1x1 pixel image either before the bookmark you're inserting the image to, or inside of it, give that the specified wordwrap.  Text by itself cannot be given a wordwrap.

 

Also, the solution proposed above this post will not work, nor will the sample work.  In most documents, inserting images worked fine, so it wasn't a problem with how I was inserting.  Images with a word wrap that hides them by default seems to be an odd case, and I'm sure there's a better way to do what I'm suggesting, but it should work.

*****************************
Win7 x64 - 16gb ram
i7 3610qm
FirePro M4000

Inventor 2013
ETO 6.1
Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Need installation help?

Start with some of our most frequented solutions or visit the Installation and Licensing Forum to get help installing your software.