473,325 Members | 2,785 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,325 software developers and data experts.

ASP:Reader client side totally

Hi,

I have a repeater on a asp.net (c#) page that holds the details of
daily bed occupancy for a hostpital ward for any given date. For each
hostpital there are a number of wards. So a hostiptal with 5 wards has
5 elements each containing a textbox for occupied and another for
remaining available.
As the user cycles through the txtboxs I want to catch the textchanged
and add all the occupied values together and the same with the
available. I tried plain old postback but it interferes with the data
input for the user. I need to do it client side but I can't work out
how I cycle through each textbox and work out if it is a occupied or
available box. All txtboxs on in the repeater need evaluating at the
same time incase any of them are changed again following error.

Any susggests or direction to a more appropriate group would be
gratefully recieved.

Thanks

Owen

Mar 22 '06 #1
1 1250
you need to learn javascript and the browser dom. your local bookstore
should have several books.

you need some way for the client script to find the textboxes, sometime in
the name, add an additional attribute. you probably want to call you client
routine on the onblur, and on submit. making a client validation control
makes sense.

if you put _OC_ in the occupied names and _AV_ in the avaliable you could
(air code):

function sumWards()
{
for (int i=0; i < document.forms[0].elments.length; ++i)
{
var totOC = 0;
var totAV = 0;
el = document.forms[0].elments[i];
if ((el.name + '').indexOf('_OC_') >= 0)
totOC += el.value;
if ((el.name + '').indexOf('_AV_') >= 0)
totAV += el.value;
}
}

-- bruce (sqlwork.com)


"owen79" <ow*********@tiscali.co.uk> wrote in message
news:11**********************@g10g2000cwb.googlegr oups.com...
Hi,

I have a repeater on a asp.net (c#) page that holds the details of
daily bed occupancy for a hostpital ward for any given date. For each
hostpital there are a number of wards. So a hostiptal with 5 wards has
5 elements each containing a textbox for occupied and another for
remaining available.
As the user cycles through the txtboxs I want to catch the textchanged
and add all the occupied values together and the same with the
available. I tried plain old postback but it interferes with the data
input for the user. I need to do it client side but I can't work out
how I cycle through each textbox and work out if it is a occupied or
available box. All txtboxs on in the repeater need evaluating at the
same time incase any of them are changed again following error.

Any susggests or direction to a more appropriate group would be
gratefully recieved.

Thanks

Owen

Mar 22 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

27
by: Mike MacSween | last post by:
Some of my users are getting 'Disk or Network Errors'. I've raised it with the network admins, they're looking into it. In the meantime... My 'standard' error handlers logs errors to a table...
1
by: Remo | last post by:
Hi, I want to know the possiblity and process of an ASP client, which needs to get some UDT from a ATL Server component implemented in VC++. The UDT is basically a C++ class consisting of a BSTR...
10
by: Betina Andersen | last post by:
I have inherited a VB.NET dll that I am using from common asp. My problem is to get the messages from the dll to the Ie client, I can see the messages in the Eventlog on the IIS server so I know...
3
by: majlandt | last post by:
I have the below function witch I use to send mail to reciptents on my maillist from an .asp side I am about to make a bounce back system - and would therefore like to make one extra MailHeader...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.