I'm assuming that whenever you 'delete' a record, you are simply changing the 
status so that it doesn't show up on the table, then refreshing the table.

You could add a filter that runs on the child form, the one from which the 
table is pulling its data, and have that filter run whenever the status is set 
to inactive, delete, whatever it is getting set to. The filter will then do a 
push fields to the same form for any record where counter on the current ticket 
is less than the counter on any other ticket found. Then, simply do the push 
fields of Counter = Counter - 1.

I think that this should work for you.
Order ID        Value
1               Test
2               Test1
3               Test2
4               Test3

If you deleted 2, then the filter would decrement test2 and test3, giving you 
the following:

Order ID        Value
1               Test
2               Test2
3               Test3

I think this will work. There might be a timing issue, however, on the 
refreshing of the table. Since you are using a filter, I'm afraid that your 
table might refresh prior to all of the tickets in the child form getting 
decremented.

Let me know if it works.

Thanks,

Gary Opela, Jr.

-----Original Message-----
From: Action Request System discussion list(ARSList) 
[mailto:arsl...@arslist.org] On Behalf Of Amey Bhosale
Sent: Wednesday, December 24, 2008 10:21 AM
To: arslist@ARSLIST.ORG
Subject: Creating Decrementing value in Table

** 
Hi All,
 
I am currently working on ARS 7.1 and have a query to ask you all.
 
I have created a Regular Form on which i have added a table field(holding data 
into anothe form) which displays only those records which have a flag set to 
"Yes"
 
On this Regular Form i have added a "Add/Modify"  and Delete Button with some 
selection fields on top of this Table field which user will select and either 
add to the table or select any record from the table and delete it.
 
When user selects the value from selection field and clicks on Add button the 
record gets added into the Table Field with an incrementing Value i.e 1,2,3 and 
so on..which i managed to do so...
 
But now i have a problem in where in if i select a record from Table and click 
on Delete Button then that particular record show go from the table and then 
the next records order id shuld get updated to previous one and same follows 
through rest of the table.
 
for e.g Now suppose i have added records as below
 
Order Id     Value
 
1               Test 
2               Test1
3               Test2
4               Test3
5               Test4
 
Now if i want to delete second record i.e Order id = 2 then when it gets 
deleted the third record i.e Order id =3 shuld get updated as Order id = 2 and 
then all the below record shuld similarly get updated i.e fourth record i.e 
Order id =4 should get updated to 3 and Order id =5 to 4
 
Can someone let me know how this can be implemented?
 
 
Regards
 
Amey Bhosale
 
Remedy Application Developer
 
J . P. Morgan Services India Pvt. Ltd.
 
 

________________________________

Cricket on your mind? Visit the ultimate cricket website. Enter now! 
<http://in.rd.yahoo.com/tagline_cricket_1/*http://beta.cricket.yahoo.com>  
__Platinum Sponsor: www.rmsportal.com ARSlist: "Where the Answers Are" html___

Reply via email to