U++ framework
Do not panic. Ask here before giving up.

Home » Community » Newbie corner » Calculated column in a SqlArray
Calculated column in a SqlArray [message #49747] Thu, 19 April 2018 17:58 Go to previous message
Giorgio is currently offline  Giorgio
Messages: 218
Registered: August 2015
Experienced Member
Hi there,
in a SqlArray I need to add a column that contains a simple calculation from two other columns, something like this:

...
        //lstSamples is the SqlArray control
	lstSamples.AddColumn(TOTSAMPLES, t_("Tot number of samples collected"), 10).SetFormat("%2!,n");
	lstSamples.AddColumn(GOODSAMPLES, t_("Good samples collected"), 10).SetFormat("%2!,n");
	lstSamples.AddColumn(([GOODSAMPLES]/[TOTSAMPLES]), t_("Percentage"), 10).SetFormat("%2!,n");
...


but of course [GOODSAMPLES]/[TOTSAMPLES] does not work.
is there a way to do that?
Thankls,
gio
 
Read Message
Read Message
Previous Topic: linking has failed
Next Topic: Building for Windows XP sp3
Goto Forum:
  


Current Time: Tue Apr 28 21:08:32 GMT+2 2026

Total time taken to generate the page: 0.00508 seconds