Skip to main content

Hi,

 

I've created a SmartBox SMO and trying to summarize the values stored in there and display the total in a SmartForm DataLabel.

 

For example there are three rows returnd by the GetList-Method in the following manner:

 

ID, Description, Value

1, Value1, 10

2, Value2, 20

3, Value3, 30

 

Now I want to display the value "60" in a DataLabel in a SmartForm. Is there an approach how to accomplish this?

 

Thanks in advance!

Christian

Hi,


Take a look at this link, it explains how to create an expression to summarize the value of differnt  values within a list.

 

http://help.k2.com/onlinehelp/K2smartforms/UserGuide/1.0.7/default.htm#Using_Expressions_on_an_Editable_List_View.html?Highlight=expressions

 

Regards

 


Hi all


 


When using a list view to display the total on a column you can select the column you want the total to be calculated on, select the column tab in the properties window and select the add option next to sum.


 



 


Kind Regards


Raymond


Will the sum be the total of what is visible in the list view, or across all data in the SmartObject?

 

For instance, if I have 1,200 rows in a SharePoint list, and the List View is showing 100, when I apply the Sum to the column will it give me a total across all 1,200 rows, or just 100?

 

I'd love to use SharePoint and not a SQL database with stored procedures for this (we have access to both) -- the proposed solution is very basic so SQL would be overkill. The most records we'd probably have is in the thousands.


"For instance, if I have 1,200 rows in a SharePoint list, and the List View is showing 100, when I apply the Sum to the column will it give me a total across all 1,200 rows, or just 100?"

Ans : It will show you only 100 (summary of only records on screen).

So, if you need to show summary of total records, you need to check out of paging of your list view (show all records) and maybe hide your list view on the form. This method may affected your form performance if you have a ton of records. I always use sql view / stored to summary the value and get it from SmartObject for better performance.

Reply