Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to Expand & Collapse Text? 2

Status
Not open for further replies.

mark929

Programmer
Nov 30, 2001
67
US
I'm re-writing a web form in ASP.Net that was written in HTML & Perl. The old form had sections that would open or roll down when clicked. Can anyone suggest how I might do this in ASP.Net, or somewhere to research it?

Please see the link below to see the old form, and an example of what I'm trying to do. The form expands or collapses by clicking on the delta bullets.


Thanks very much,

Mark Roberts
 
The effect is created using javascript. If you view the source of the page you linked to there is a javascript function called expandit. This is called by an onclick event which passes in the name of the div to show. You can use panels in asp.net to output divs to the page or just use a div in your aspx. Its just a case of attaching the script, the relevant css and the onclick event.

Everything you need to do this is already in the source of the page you linked to.

Rob

Go placidly amidst the noise and haste, and remember what peace there may be in silence - Erhmann 1927
 
You can also use a collapsable panel which you should be able to find online for free...

dlc
 
Thanks Rob, that sounds pretty straightforward. I'll give it a try. Thanks for the fast response.

Mark
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top