By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,543 Members | 2,085 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,543 IT Pros & Developers. It's quick & easy.

slider control

P: n/a
How can I create a slider control or visual scale control which fires a
server-side event when a selection is made?

I would appreciate any tips.

Thanks
Bill


Jul 18 '06 #1
Share this Question
Share on Google+
4 Replies


P: n/a
What sort of tips are you looking for? Ideas for building one, or
third-party tools?

--
HTH,

Kevin Spencer
Microsoft MVP
Professional Chicken Salad Alchemist

What You Seek Is What You Get.
"bill" <be****@datamti.comwrote in message
news:ur*************@TK2MSFTNGP03.phx.gbl...
How can I create a slider control or visual scale control which fires a
server-side event when a selection is made?

I would appreciate any tips.

Thanks
Bill


Jul 18 '06 #2

P: n/a
I would prefer to find a way to create my own, since the functionality I
need is minimal - click on a scale and return a numeric value between 1 and
100 to the server.

Currently I am using a table with 100 cells, each containing a button with a
command argument between 1 and 100.

The table is created dynamically, and the buttons are wired to an event
handler which saves the value. Other types of dynamically created controls
(radio buttons, check boxes, dropdown lists, etc.) also use this event
handler.

It works fine, except that I would rather the scale selection did not post
back immediately. Instead, I would rather wait until the page is posted
back by a Save button and process all event handlers at the same time. This
does not appear to be possible, though, as discussed in my post about
preventing autopostback for a button click.

Thanks
Bill
"Kevin Spencer" <uc*@ftc.govwrote in message
news:OE**************@TK2MSFTNGP03.phx.gbl...
What sort of tips are you looking for? Ideas for building one, or
third-party tools?

--
HTH,

Kevin Spencer
Microsoft MVP
Professional Chicken Salad Alchemist

What You Seek Is What You Get.
"bill" <be****@datamti.comwrote in message
news:ur*************@TK2MSFTNGP03.phx.gbl...
>How can I create a slider control or visual scale control which fires a
server-side event when a selection is made?

I would appreciate any tips.

Thanks
Bill



Jul 18 '06 #3

P: n/a
find a dhtml slider control on the web somewhere

it should either have a hidden form control that it writes to (which
you can grab on the server side), or it will have a client side event
that is raised when the user lets go of the mouse. you can then write
to a hidden form field in the event handler.

in either case you could use:

string sliderPercent = Request.Form["myHiddenSliderValue"];

on the server
bill wrote:
I would prefer to find a way to create my own, since the functionality I
need is minimal - click on a scale and return a numeric value between 1 and
100 to the server.

Currently I am using a table with 100 cells, each containing a button with a
command argument between 1 and 100.

The table is created dynamically, and the buttons are wired to an event
handler which saves the value. Other types of dynamically created controls
(radio buttons, check boxes, dropdown lists, etc.) also use this event
handler.

It works fine, except that I would rather the scale selection did not post
back immediately. Instead, I would rather wait until the page is posted
back by a Save button and process all event handlers at the same time. This
does not appear to be possible, though, as discussed in my post about
preventing autopostback for a button click.

Thanks
Bill
"Kevin Spencer" <uc*@ftc.govwrote in message
news:OE**************@TK2MSFTNGP03.phx.gbl...
What sort of tips are you looking for? Ideas for building one, or
third-party tools?

--
HTH,

Kevin Spencer
Microsoft MVP
Professional Chicken Salad Alchemist

What You Seek Is What You Get.
"bill" <be****@datamti.comwrote in message
news:ur*************@TK2MSFTNGP03.phx.gbl...
How can I create a slider control or visual scale control which fires a
server-side event when a selection is made?

I would appreciate any tips.

Thanks
Bill

Jul 18 '06 #4

P: n/a
Yes, in fact, the following article details how to create a slider that
employs JavaScript to render HTML and handle the client-side interaction. It
could easily be adopted to a Server Control:

http://www.phys.uu.nl/~hofman/jsexp/explslider.html

--
HTH,

Kevin Spencer
Microsoft MVP
Professional Chicken Salad Alchemist

What You Seek Is What You Get.
<ne**********@gmail.comwrote in message
news:11**********************@p79g2000cwp.googlegr oups.com...
find a dhtml slider control on the web somewhere

it should either have a hidden form control that it writes to (which
you can grab on the server side), or it will have a client side event
that is raised when the user lets go of the mouse. you can then write
to a hidden form field in the event handler.

in either case you could use:

string sliderPercent = Request.Form["myHiddenSliderValue"];

on the server
bill wrote:
>I would prefer to find a way to create my own, since the functionality I
need is minimal - click on a scale and return a numeric value between 1
and
100 to the server.

Currently I am using a table with 100 cells, each containing a button
with a
command argument between 1 and 100.

The table is created dynamically, and the buttons are wired to an event
handler which saves the value. Other types of dynamically created
controls
(radio buttons, check boxes, dropdown lists, etc.) also use this event
handler.

It works fine, except that I would rather the scale selection did not
post
back immediately. Instead, I would rather wait until the page is posted
back by a Save button and process all event handlers at the same time.
This
does not appear to be possible, though, as discussed in my post about
preventing autopostback for a button click.

Thanks
Bill
"Kevin Spencer" <uc*@ftc.govwrote in message
news:OE**************@TK2MSFTNGP03.phx.gbl...
What sort of tips are you looking for? Ideas for building one, or
third-party tools?

--
HTH,

Kevin Spencer
Microsoft MVP
Professional Chicken Salad Alchemist

What You Seek Is What You Get.
"bill" <be****@datamti.comwrote in message
news:ur*************@TK2MSFTNGP03.phx.gbl...
How can I create a slider control or visual scale control which fires
a
server-side event when a selection is made?

I would appreciate any tips.

Thanks
Bill


Jul 19 '06 #5

This discussion thread is closed

Replies have been disabled for this discussion.