Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Report Control
  New Posts New Posts RSS Feed - GroupFormula
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

GroupFormula

 Post Reply Post Reply
Author
Message
flado View Drop Down
Groupie
Groupie


Joined: 30 October 2009
Status: Offline
Points: 10
Post Options Post Options   Thanks (0) Thanks(0)   Quote flado Quote  Post ReplyReply Direct Link To This Post Topic: GroupFormula
    Posted: 26 September 2011 at 4:58pm
I recently updated to 15.1.3 thinking that it would solve my groupformula problems, but I can't seem to figure it out...

Here are my problems:
1. I use space as thousand separator - ie 1,000 becomes 1 000  - the control doesn't seem to be able to calculate this. Or is there a sepcial formula I should use?
2. I have a report in which I want to show the subsums of up to 12 columns in the group row. It seems I can't show more than 6 columns. Is this a limitation?

Please help as I have been struggling with this for a LOOONG time now...

using VDF 151 and CJ15.1.3 ActiveX COM

thanks
/Leif

Back to Top
flado View Drop Down
Groupie
Groupie


Joined: 30 October 2009
Status: Offline
Points: 10
Post Options Post Options   Thanks (0) Thanks(0)   Quote flado Quote  Post ReplyReply Direct Link To This Post Posted: 20 October 2011 at 10:16am
Anyone?
Thanks....
Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 04 November 2011 at 9:18am
Hi,
 
I don't see problem....
 
Here's test project, maybe it will help you:   uploads/3701/Formulas.zip
 
Good luck Wink
 
 
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0

Zero replies is not an option....
Back to Top
flado View Drop Down
Groupie
Groupie


Joined: 30 October 2009
Status: Offline
Points: 10
Post Options Post Options   Thanks (0) Thanks(0)   Quote flado Quote  Post ReplyReply Direct Link To This Post Posted: 30 November 2011 at 6:49am
Thank you for your answer! I looked at your test project, but it seems that even there the formats of the totals are not correct:

Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 06 December 2011 at 9:28am
Hi,
 
I don't see problem... Can you be more specific?
 
Thanks
 
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0

Zero replies is not an option....
Back to Top
Willowmaster View Drop Down
Senior Member
Senior Member
Avatar

Joined: 12 July 2010
Location: Netherlands
Status: Offline
Points: 180
Post Options Post Options   Thanks (0) Thanks(0)   Quote Willowmaster Quote  Post ReplyReply Direct Link To This Post Posted: 06 December 2011 at 9:41am
In the BeforeDrawRow event the Grouprows are excluded from formatting. That's why the grouprow is not showing the right formatting.
This is some very bad programming and it has a small bug in it. But i shows it is possible to fix the formatting.
 
Private Sub wndReportControl_BeforeDrawRow(ByVal Row As XtremeReportControl.IReportRow, ByVal Item As XtremeReportControl.IReportRecordItem, ByVal Metrics As XtremeReportControl.IReportRecordItemMetrics)
Dim lngGroupOrder       As Long
Dim lngStartPos         As Long
    If Not Row.groupRow Then
        Metrics.Text = Format(Item.Caption, "### ### ###")
    Else
        lngStartPos = InStr(1, Metrics.Text, "[" & wndReportControl.GroupsOrder.Count & "]")
        If lngStartPos > 0 Then
            Metrics.Text = wndReportControl.GroupsOrder.Column(wndReportControl.GroupsOrder.Count - 1).Caption & ": " & Format(Mid(Metrics.Text, Len(wndReportControl.GroupsOrder.Column(wndReportControl.GroupsOrder.Count - 1).Caption) + 2, lngStartPos - Len(wndReportControl.GroupsOrder.Column(wndReportControl.GroupsOrder.Count - 1).Caption) - 2), "### ### ###") & " [" & wndReportControl.GroupsOrder.Count & "]" & Format(Mid(Metrics.Text, (lngStartPos + Len("[" & wndReportControl.GroupsOrder.Count & "]"))), "### ### ###")
        Else
            Metrics.Text = wndReportControl.GroupsOrder.Column(wndReportControl.GroupsOrder.Count - 1).Caption & ": " & Format(Mid(Metrics.Text, Len(wndReportControl.GroupsOrder.Column(wndReportControl.GroupsOrder.Count - 1).Caption) + 2), "### ### ###")
        End If
    End If
End Sub
Product: Xtreme SuitePro (ActiveX) version 15.3.1

Platform: Windows XP (32bit) - SP 3 (on VMWare)

Language: Visual Basic 6.0



Back to Top
Andrew666 View Drop Down
Groupie
Groupie


Joined: 15 October 2008
Status: Offline
Points: 27
Post Options Post Options   Thanks (0) Thanks(0)   Quote Andrew666 Quote  Post ReplyReply Direct Link To This Post Posted: 16 February 2012 at 9:00am
I have this same problem --- it appears that SUMSUB uses the Caption of the item, not its Value property - so if I format the Caption in any way, the SUMSUB gives the wrong number.  Surely this is a bug?
 
Also, the SUMSUB behaviour doesn't appear to be as documented.  If I use SUMSUB(C3:C6) for example, this appears to cause the total to be displayed in column 3 of the GroupRow, and sums the column 6 values.
 
Using v15.2.1
Back to Top
mihey View Drop Down
Groupie
Groupie
Avatar

Joined: 14 May 2003
Location: Germany
Status: Offline
Points: 45
Post Options Post Options   Thanks (0) Thanks(0)   Quote mihey Quote  Post ReplyReply Direct Link To This Post Posted: 12 May 2014 at 4:06am
Hi everyone,

I've fixed this issue in my case by patching the method StringToDouble of the CXTPReportRecordItem.

double CXTPReportRecordItem::StringToDouble(CString strText)
{

        TCHAR chSep[4];
        GetLocaleInfo(LOCALE_USER_DEFAULT, LOCALE_STHOUSAND, chSep, 4);
     strText.Replace(chSep, "");

     TCHAR* locale = _tsetlocale(LC_NUMERIC, NULL);

     if (locale == NULL || _tcscmp(locale, _T("C")) == 0) // Not set
     {
          strText.Replace(',', '.');
     }

     double res = atof(XTP_CT2CA(strText));

     return res;
}

Maybe CJ could take it over into their next release.
Best regards, Mikhail
Back to Top
mcmastl View Drop Down
Admin Group
Admin Group
Avatar

Joined: 14 April 2015
Status: Offline
Points: 79
Post Options Post Options   Thanks (0) Thanks(0)   Quote mcmastl Quote  Post ReplyReply Direct Link To This Post Posted: 20 April 2015 at 12:47pm
Thank you for bringing this to our attention, we have informed our development team and we will be looking into the issue.  If the matter has been resolved please let us know.  
Luke McMasters, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.172 seconds.