NetTalk Central
NetTalk Web Server => Web Server - Ask For Help => Topic started by: kevin plummer on May 16, 2010, 08:14:07 PM
-
Hi All,
I have a browse embedded in a form. I have tagging on the browse records. I have added a field to the form called TotalSelectedRecords and made this read only.
I would like to update/refresh this field when the user tags a record.
Is this possible?
Cheers,
Kevin
-
on tagging column you have a server side code, there you can call routines for refresh value in this field
do Value::FieldToBeRefreshed
-
My problem is that the total field is on the form not the browse - I don't think I can refresh a field on the form by an action on the browse.
I'm playing around with the custom total on the templates which is part of the browse footer as I may be able to just display the total there instead.
-
Hi Kevin,
From memory - you can refresh other fields on the form using the Client side tab. It should work for a browse just like any other field.
cheers
Bruce
-
The Tag Field is on the browse.
The SelectedTotal Field is on the form.
None of the fields on the form appear on the client side tab in the browse.
Clicking the Tag checkbox is the event to recalc selected records and refresh the selectedtotal on the form.
Is there a way to detect if the user has checked/unchecked the tag in the browse from the form?
Cheers,
Kev
-
i,ve not used tags, but done something similar for totals.
if in your browse you get the total to a sessionvalue. Then on your netwebform you can get to your embedded browse referenced as a field and then reset the things(yourtotalfield) on your form (send to server, servercode etc) - when the browse is clicked.
(its been a while and i recall i had to add some additional code to ensure it was acurate in all circumstances)
-
Thanks Poul. I had missed the Client Side Tab for the Browse. My problem now is that it refreshes the total field before I have calculated the total so it is always off by one records amount.
Any suggestions?
Cheers,
Kevin
-
i recall it a challenge - i had somethings that was ok but was able to compartmentalize (the total on the first tab) and the browse was on a second tab - which allowed me to cheat.
My final solution was: because i was using sql I opted to fire a stored procedure - but you could do the same in clarion i suppose - when the browse updated something I would recalculate my own total and update a sessionvalue. and do this same logic when i opened the form - so the session value would always be accurate. Tags my be different but the info must be persisted somewhere - so i'd say recalc/count them
-
I think I either need to switch off Async or add a timer before it refreshes the selected records total field.
Anyone know how to switch Async on and off?
Cheers,
Kev