Welcome to the SRP Forum! Please refer to the SRP Forum FAQ post if you have any questions regarding how the forum works.

Grouping and ListExFormatted

When extracting via ListExFormatted, and with groups the content has peculiar field in brackets.

For example TRADES: 0060 [14] 13,815,660.92 The peculiar bit is the [14] in the text, which does not appear on screen.
Looks like it could be the column position of the totalling field (less 1 as this is column 15).

Comments

  • Let me explain what you're seeing, then we can discuss what could be done. The SRP ReportTable Control is based on a third party C++ control from CodeJock.com. They are the ones that built in support showing formulas within group rows. In order to do it, they require the above formatting, i.e., the group header followed by one or more formulas, each of which are prefixed with a column index (as you rightly guessed). The column indexes are zero-based, which is why they are one short. Behind the scenes, I am setting each group row's caption using the above formatting. When you read the ListExFormatted property, I am simply returning the caption as is.

    I can add logic to return the caption in a different formatting, but I'm wondering what formatting would best fit. Simple @FMs and @VMs doesn't quite work because the expectation is that the values will line up perfectly with regular rows, but in group rows, the first value is always the group header, even if the column being grouped is not column 1. I suppose I could use the same formatting as above with the difference that the column indexes would be 1-based.

    I'd be interested in your thoughts.
  • At first I just thought I would just like the value in brackets to be removed.
    Thinking a little more, if we could have the option to convert this to a specific value, then we could swap with a tab, so when pasting into Excel, the text and value are in separate columns.

    It might just be easiest to allow a swap to user defined characters, eg space, tab, or other.

    What I am doing is obtaining the data for reports, both via Clipboard to Excel and to my report generator.
    In these cases I will be reformatting anyway, as there are other things I need to do, such as strip hidden columns, so its no problem swapping the [14] with null, assuming the user has not entered this in the description for some obscure reason.
    As such, I don't actually need any change, but for general use I can see it being useful.
  • More on this issue.
    I have two columns being totalled, column 18 and 19.

    When grouped, this shows as Part: A [18] 69.23 [17] 140.78 The order is not in accordance with what I would expect, they are reversed, but I can deal with.
    Just mentioning for info.
Sign In or Register to comment.