.NET Newbie Question

  • Thread starter Thread starter Jeff Johnson
  • Start date Start date
J

Jeff Johnson

I"m updating an ASP site to ASP.NET and have a question....

My site is a vehicle configurator in which the user selects a image (paint
swatch), the colour code is submitted on a hidden page and the newly
selected paint swatch is highlighted, seamlessly, via JavaScript generated
from the hidden page.

So, in .NET I'm generating the paint swatches with the ImageButton server
control, and when the user selects a swatch, the page refreshes and I want
to know if I can use .NET and highlight the newly selected paint swatch
without seeing the flash of the page refresh.

Am I stuck using a hidden page generating JavaScript to avoid seeing this?

Thanks,

JJ
 
I think you can use SmartNavigation get stop the page flash, however
this only works with IE.

You can still use client side code on the ImageButton. What you need to
do is Register some client script then use the AddAttribute method to
run the javascript OnClick
 
I thought of that, but the click still requies a trip to the server in order
to set the new configuration.

JJ
 
So are you saying the way your code works you need to do a round trip to
the server? If you have to do that then SmartNavigation is your only
option. (and in my opinion not a good one, unless you have full control
over your deployment enviroment)

When i talked about the OnClick i was talking about a Client Side
function not the server side onClick event. (just making sure i was
being clear)
 
I'll investigate the SmartNavigation. That's the kind of information I was
looking for.

Thanks for taking the time to reply; I really appreciate it.

JJ
 
Back
Top