5 Replies Latest reply: Jul 1, 2013 2:00 AM by Ariel Klien RSS

    Count raw of straight table.

    Ariel Klien

      Hello all


      I need help with a faster way to count raw of a straight table.


      Today I have 16 straight tables in my model.

      For each one their is a text box with the count of the raw's of the table.


      Today I am using this macro for each one (16 times):


      Sub NoofRowsCH01

      set table = ActiveDocument.GetSheetObject("CH01")

        rows =  table.GetRowCount - 1

        ActiveDocument.Variables("vNoRowCH01").SetContent rows, True 

      End Sub


      I've 16 variables that contain the numbers and I show them in the text box.


      In Document Event Triggers > OnPostReload I'm running all the macros.


      So when I reload the model all my text box are update.


      In this way the model takes a long time to refresh.


      I'm searching a faster way to do this.


      Any idea anyone?