Question

MsWord Writer table - Error

  • 8 October 2018
  • 8 replies
  • 11 views

Badge

Hi,

I'm facing a strange situation with MsWordStyler and Word Writer. I need to add a table to create a report from a feature. If I don't use a template, I can chose different styles for a table with the styler. The output of the table is correct. Trying to use a template, the only option to use a template is to select "Normal Table" as table style. Any other style produce the following error:

"Microsoft Word Writer: Rejecting Feature. The msword_type value 'msword_table' is invalid. Please use a MSWordStyler prior to this writer to set the msword_type attribute".

Is there some hints or best practices to follow creating the template?

Paragraph and image work fine with the same template.

Thanks

Roberto


8 replies

Badge +2
Hi @roberto. I think I can reproduce the same issue you mentioned. I'll have to check with our developer to see what's happening. Will post here with an update, when I have news. Thanks for bringing this to our attention!

 

Userlevel 4
Badge +25

Hi Roberto

I think the issue is that the template must have that type of table existing in it already. For example if I write a table of a certain type to a Word document, and then use that document as a template in a subsequent translation, there is no problem. I only get the error you do when I write to a Word document with a template that has no table design in it.

Of course, I could be wrong and it might be a bug. I'll check with the developers and see what they say. But in the meantime, add a table to your template and try it again. I think it will work then.

Userlevel 4
Badge +25

Hi Roberto

I think the issue is that the template must have that type of table existing in it already. For example if I write a table of a certain type to a Word document, and then use that document as a template in a subsequent translation, there is no problem. I only get the error you do when I write to a Word document with a template that has no table design in it.

Of course, I could be wrong and it might be a bug. I'll check with the developers and see what they say. But in the meantime, add a table to your template and try it again. I think it will work then.

Yes, the developers tell me that your template has to have the same table styles in it already. For a workspace that writes without a template, we have our own template in the background that has all of the required styles in it. That's how it works without a template (with our own template) but not with yours.

 

Badge

Hi Roberto

I think the issue is that the template must have that type of table existing in it already. For example if I write a table of a certain type to a Word document, and then use that document as a template in a subsequent translation, there is no problem. I only get the error you do when I write to a Word document with a template that has no table design in it.

Of course, I could be wrong and it might be a bug. I'll check with the developers and see what they say. But in the meantime, add a table to your template and try it again. I think it will work then.

@Mark2AtSafe, the hint was successful. I made the operation in two steps. The first one to write the Word with the table style without template. Then I copied the table as-is in the real template, delete table and saved the template. Now, I'm able also to output the report using such template with desired table style.

Thanks!

Roberto

Badge +2

@Mark2AtSafe, the hint was successful. I made the operation in two steps. The first one to write the Word with the table style without template. Then I copied the table as-is in the real template, delete table and saved the template. Now, I'm able also to output the report using such template with desired table style.

Thanks!

Roberto

Hi @roberto, Great to hear that Mark's tip worked out for you. I'm trying to get a better understanding of how people are using the template for Word Writers. Would you mind telling me how did using a template helped in your scenario? Thank you very much.
Badge

@Mark2AtSafe, the hint was successful. I made the operation in two steps. The first one to write the Word with the table style without template. Then I copied the table as-is in the real template, delete table and saved the template. Now, I'm able also to output the report using such template with desired table style.

Thanks!

Roberto

@xiaomengatsafe​ I have a complicated style setup in my word document but can't seem to make certain styles choosable... Do you have any suggestions?

Badge +2

@Mark2AtSafe, the hint was successful. I made the operation in two steps. The first one to write the Word with the table style without template. Then I copied the table as-is in the real template, delete table and saved the template. Now, I'm able also to output the report using such template with desired table style.

Thanks!

Roberto

Hi @peteralstorp​ Thanks for your question. I think we may need a little more detail on what your setup is and what you are having trouble with. Also, considering this is a pretty old thread, I'd recommend that you post your issue as a new question, so more people will likely to see it and give you suggestions.

Badge

@Mark2AtSafe, the hint was successful. I made the operation in two steps. The first one to write the Word with the table style without template. Then I copied the table as-is in the real template, delete table and saved the template. Now, I'm able also to output the report using such template with desired table style.

Thanks!

Roberto

Hi! I already did this and got an answer in this thread. Thanks! https://community.safe.com/s/question/0D54Q00008AFvo6SAD/how-connect-to-styles-in-ms-word

Reply