Bug Report T283025
Visible to All Users

ASPxGridViewExporter - Custom formatting is not applied to summary cells in the XlsxExportOptionsEx.CustomizeCell event

created 10 years ago

[DevExpress Support Team: CLONED FROM T280404: ASPxGridViewExporter - e.Value is always null in the XlsxExportOptionsEx.CustomizeCell event]
Hello Nataly,
but your solution remove formula. For us it is the best solution to preserve formula.
but i don't understant why you add support for changing format  in data area
https://www.devexpress.com/Support/Center/Question/Details/T253075
and omit the same option for formulas in summary area
Thank you for the clarification

Show previous comments (3)
DevExpress Support Team 9 years ago

    Hello,

    Here is the project created based on my previous suggestion, where custom formatting is applied for the summary cells. See the attached screencast demonstrating it in action. Please note that e.Formatting.NumberFormat has no effect if e.Formatting.FormatString is defined.

      Hi Nataly,
      you don't understand my requirements. Your example not contain formula in exported cell.
      Thera are my requirements:

      1. Export summary cell over time column with formula (not replace formula with value, this approch is not much dataaware)
      2. Use custom format [h]:mm over this cell
        Code in my example which calculating custom summary is neccesary because your grid does not allow summary over time column.
        Export of time column with summary formula could be done by this two ways
      3. Set summary SummaryType="Sum" (like in my current example). Note: Summary is not displayed bellow grid, but export contains correct formula with incorrect formating.
      4. Set summary SummaryType="Custom" (like in my previous example in other report). Consequently, it is necessary to change  e.SummaryItem.SummaryType = DevExpress.Export.Xl.XlSummary.Sum in CustomizeCell in code behind.
        First and second approach produces the same output.
        Same requirements was in my first problem
        https://www.devexpress.com/Support/Center/Question/Details/T280404
        Unfortunately, it was not understood and then was created this clone.
        Thank you
      DevExpress Support Team 9 years ago

        Hello,

        Please accept my apologies for missing that. You are right, the workaround is not effective under such conditions. We will do our best to find another solution and are actively researching its source now.

        Answers approved by DevExpress Support

        created 9 years ago

        We have fixed the issue described in this ticket and will include the fix in our next maintenance update. To apply this solution before the official update, request a hotfix by clicking the corresponding link for product versions you require.

        Note: Hotfixes may be unavailable for beta versions and updates that are about to be released.

          Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

          Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.