<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Denis in Product Forum</title>
    <link>https://community.blueprism.com/t5/Product-Forum/To-Write-A-Collection-Onto-a-Word-Dynamically/m-p/80967#M32605</link>
    <description>Denis
I think the question was more around the number of columns, if this isn't fixed and can change from 2 to 3 or more... 
I'm keen to find a solution to this also as it's something I'm currently being faced with... 
Thanks</description>
    <pubDate>Fri, 31 Mar 2017 17:28:00 GMT</pubDate>
    <dc:creator>FirstName</dc:creator>
    <dc:date>2017-03-31T17:28:00Z</dc:date>
    <item>
      <title>To Write A Collection Onto a Word Dynamically</title>
      <link>https://community.blueprism.com/t5/Product-Forum/To-Write-A-Collection-Onto-a-Word-Dynamically/m-p/80963#M32601</link>
      <description>HI All,

I want to write a collection with unknown number of fields into a table in the word document.
I know how to do it if the number of fields in the collection are known but if the fields in the collection can vary at run time and I am stuck as how to proceed further.

Any suggestions would be appreciated.

Thanks.</description>
      <pubDate>Thu, 30 Mar 2017 10:59:00 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/To-Write-A-Collection-Onto-a-Word-Dynamically/m-p/80963#M32601</guid>
      <dc:creator>PrateekMehan</dc:creator>
      <dc:date>2017-03-30T10:59:00Z</dc:date>
    </item>
    <item>
      <title>Looking at the MS Word VBO</title>
      <link>https://community.blueprism.com/t5/Product-Forum/To-Write-A-Collection-Onto-a-Word-Dynamically/m-p/80964#M32602</link>
      <description>Looking at the MS Word VBO object I can see that it has an 'Add Table Row' action.
Can you not simply loop through your collection and use this 'Add Table Row' action when required to add additionally required rows?</description>
      <pubDate>Thu, 30 Mar 2017 14:06:00 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/To-Write-A-Collection-Onto-a-Word-Dynamically/m-p/80964#M32602</guid>
      <dc:creator>Denis__Dennehy</dc:creator>
      <dc:date>2017-03-30T14:06:00Z</dc:date>
    </item>
    <item>
      <title>I agree with you Dennis but</title>
      <link>https://community.blueprism.com/t5/Product-Forum/To-Write-A-Collection-Onto-a-Word-Dynamically/m-p/80965#M32603</link>
      <description>I agree with you Dennis but adding a table row would require me to know the number of columns in a collection which I stated could change.
That's where I am stuck at , if collection has 2 columns and sometimes 3 columns, how to tackle that??</description>
      <pubDate>Thu, 30 Mar 2017 15:21:00 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/To-Write-A-Collection-Onto-a-Word-Dynamically/m-p/80965#M32603</guid>
      <dc:creator>PrateekMehan</dc:creator>
      <dc:date>2017-03-30T15:21:00Z</dc:date>
    </item>
    <item>
      <title>If you are asking how do i</title>
      <link>https://community.blueprism.com/t5/Product-Forum/To-Write-A-Collection-Onto-a-Word-Dynamically/m-p/80966#M32604</link>
      <description>If you are asking how do i discover the number of rows are in a collection, there is a Count Rows action in the internal collections object, or if you are looping through a collection you simply need to increment a data item counter as you loop?</description>
      <pubDate>Thu, 30 Mar 2017 15:44:00 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/To-Write-A-Collection-Onto-a-Word-Dynamically/m-p/80966#M32604</guid>
      <dc:creator>Denis__Dennehy</dc:creator>
      <dc:date>2017-03-30T15:44:00Z</dc:date>
    </item>
    <item>
      <title>Denis</title>
      <link>https://community.blueprism.com/t5/Product-Forum/To-Write-A-Collection-Onto-a-Word-Dynamically/m-p/80967#M32605</link>
      <description>Denis
I think the question was more around the number of columns, if this isn't fixed and can change from 2 to 3 or more... 
I'm keen to find a solution to this also as it's something I'm currently being faced with... 
Thanks</description>
      <pubDate>Fri, 31 Mar 2017 17:28:00 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/To-Write-A-Collection-Onto-a-Word-Dynamically/m-p/80967#M32605</guid>
      <dc:creator>FirstName</dc:creator>
      <dc:date>2017-03-31T17:28:00Z</dc:date>
    </item>
    <item>
      <title>I see... well if the action</title>
      <link>https://community.blueprism.com/t5/Product-Forum/To-Write-A-Collection-Onto-a-Word-Dynamically/m-p/80968#M32606</link>
      <description>I see... well if the action does not exist in the word interface, your option is probably to create a new action that does what you want.
So, I see that the Add Row action has code that looks like:
Dim doc as Object = GetDocument(handle,documentname)
doc.Tables.Item(TableNumber).Rows.Add()
I would suggest that a new Add Column action would be extreamly similar and probably look something like this:
Dim doc as Object = GetDocument(handle,documentname)
doc.Tables.Item(TableNumber).Columns.Add()
NOTE: I don't know if that is the code you need, that is my non-research guess.  I would suggest using google to find out for sure.  This kind of thing: &lt;A href="https://msdn.microsoft.com/en-us/library/office/ff837258.aspx" target="test_blank"&gt;https://msdn.microsoft.com/en-us/library/office/ff837258.aspx&lt;/A&gt;
However, I would guess that adding columns is more likely to impact the general formatting of a word document (such as going over the right of page boundary) - so even more actions/logic would probably be required to somehoe counter that.</description>
      <pubDate>Fri, 31 Mar 2017 18:06:00 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/To-Write-A-Collection-Onto-a-Word-Dynamically/m-p/80968#M32606</guid>
      <dc:creator>Denis__Dennehy</dc:creator>
      <dc:date>2017-03-31T18:06:00Z</dc:date>
    </item>
    <item>
      <title>Thanks Denis , I would give</title>
      <link>https://community.blueprism.com/t5/Product-Forum/To-Write-A-Collection-Onto-a-Word-Dynamically/m-p/80969#M32607</link>
      <description>Thanks Denis , I would give it a try</description>
      <pubDate>Fri, 07 Apr 2017 14:02:00 GMT</pubDate>
      <guid>https://community.blueprism.com/t5/Product-Forum/To-Write-A-Collection-Onto-a-Word-Dynamically/m-p/80969#M32607</guid>
      <dc:creator>PrateekMehan</dc:creator>
      <dc:date>2017-04-07T14:02:00Z</dc:date>
    </item>
  </channel>
</rss>

