Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Excel export and hidden fields

    Hi, I have a quick question.

    I have a grid with one hidden field, which I'd like to include in export. Traditionally we have to do that by setting the exportFields value. It would be neat if there was, in addition to setExportAll, a way to say "export all, including hidden fields".

    That's not possible right now, right? If not, it would be a neat feature.

    #2
    You can do what you want right now in SmartGWT, with something like this (Java 8+):
    Code:
    List<ListGridField> fields = Arrays.asList(myGrid.getAllFields());
    List<String> fieldNames = fields.stream().map(
        field -> field.getName()).collect(Collectors.toList());
    myGrid.exportClientData(new DSRequest() {{
        setExportFields(fieldNames.toArray(new String[fieldNames.size()]));
    }});

    Comment


      #3
      Yeah, that's how we do it today (although we call exportdata). Thanks!

      Comment

      Working...
      X