Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

In straight table I want to add values dynamically through selection

Dear All,

            I have a table Info which contains 2 fields

             1.Name and

             2.Value.

The fields contain values--

Header 1Header 2
NameValue
a10
b20


I want to create a straight table.In that table whenever I click on 'a' 10 comes.but

when we click 'b' 10+20=30 comes.How to do that?

Please give me an idea.

I am waiting here for your fast response...

what will be the expression?

Thanks & Regards,

Koushik.

7 Replies
SunilChauhan
Champion
Champion

if(Name='a',Value,if(Name='b',sum( all Value)))

Sunil Chauhan
Not applicable
Author

Thanks for your reply Sunil.

But I want something more.If there are many name like a,b,c,d,e,f,g,h etc.

When I click on the forth/fifth or sixth name,automatically the previous

value including that selected name will come as a total.I dont want to write

a fixed code depending upon the names.It will be a dynamic expression.

Please help me out.

Thanks & Regards,

Koushik.

SunilChauhan
Champion
Champion

see the attached file hope this help

Sunil Chauhan
Not applicable
Author

Hi,

   Try with the below Expression:

   if(rowno()=1,Sum(Value),Sum(Value)+Above(Sum(Value)))

Regards,

Santhosh

Not applicable
Author

Thanks my dear friend.But your code do just a sum of two rows.I want a cumulative sum.

Is it possible in expression?

Please help me.

Thanks & Regards.

Koushik.

Not applicable
Author

Hello,

I added a row number as RowNo to the table and use this for order and selection.

sum( {1                     //use all datarows

        < RowNo=            //modifierer RowNo =

            {                //

            "< $(#=only(RowNo))",  //select all rows before

            "= $(#=only(RowNo))"   //and the selected row

            }

         >

     }       Value )

P.S. The operator "<=" doesn´t work. Any ideas?  (  "<= $(#=only(RowNo))"   )

Not applicable
Author

Thanks everybody.