473,246 Members | 3,243 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,246 software developers and data experts.

Page Display

In brief am using javascript to enable show/hide layers in an ASP web
appplication.
but its not working.
I made a small web application, which is a web form that has many input
fields. There are many fields that rely on the value of the previous
entries.

The application worked fine, but i tried to register a javascript
function to hide the parts of the page that fillled, but after the page
reloads the fields only disappear for a second.

//stage 1
has 2 input fields and one btn
//stage 2 relies on the previous input
has 2 fields and a button

I need to have all the fields on one page. The javascript fucntion am
using is:
<SCRIPT language="javascript">
function DoToggle(s) {
var theStage = s;
//alert(s);//String(<% = Application["stage"] %>);
var stages = new Array(5);
stages[0]= "stage1";
stages[1]= "stage2";
stages[2]= "stage3";
stages[3]= "stage4";
stages[4]= "stage5";
for ( ii=0; ii < 5; ii++ ) {
p = stages[ii];
if (theStage == p) {
document.getElementById(p).className='csShow';}
else {
document.getElementById(p).className='csHide';}
}
}
</SCRIPT>

/////////////////////////////////////

when the function is called it hides the other layers but then the
layers reappear again...
Help!!

Feb 20 '06 #1
1 1135
On 19 Feb 2006 23:22:14 -0800, "Mr. Bean" <mk*****@gmail.com> wrote:
In brief am using javascript to enable show/hide layers in an ASP web
appplication.
but its not working.
I made a small web application, which is a web form that has many input
fields. There are many fields that rely on the value of the previous
entries.

The application worked fine, but i tried to register a javascript
function to hide the parts of the page that fillled, but after the page
reloads the fields only disappear for a second.

//stage 1
has 2 input fields and one btn
//stage 2 relies on the previous input
has 2 fields and a button

I need to have all the fields on one page. The javascript fucntion am
using is:
<SCRIPT language="javascript">
function DoToggle(s) {
var theStage = s;
//alert(s);//String(<% = Application["stage"] %>);
var stages = new Array(5);
stages[0]= "stage1";
stages[1]= "stage2";
stages[2]= "stage3";
stages[3]= "stage4";
stages[4]= "stage5";
for ( ii=0; ii < 5; ii++ ) {
p = stages[ii];
if (theStage == p) {
document.getElementById(p).className='csShow';}
else {
document.getElementById(p).className='csHide';}
}
}
</SCRIPT>

/////////////////////////////////////

when the function is called it hides the other layers but then the
layers reappear again...
Help!!

This appears to be an ASP.NET question. Have you tried the ASP.NET news groups?

Otis Mukinfus
http://www.arltex.com
http://www.tomchilders.com
Feb 20 '06 #2

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

Similar topics

6
by: laura | last post by:
I'm doing a page which gathers some text in the form of a text box in a <form>. This text is saved to a text file, notices.txt and I want to be able to display the saved text on the page, as soon...
7
by: Sens Fan Happy In OH | last post by:
I'm having majour issues with FrontPage 2K and a webpage that I am having to create from scratch based on someone else's prior work. I hope someone can look at the source code for the page in...
7
by: Brian Paul | last post by:
When a user clicks on a linkbutton on a page, i would like to render a printer-friendly version of the asp.net page and download it as an html attachment to the browser. The code below works great,...
0
by: Niks | last post by:
Hi, I am creating a simple .aspx page to add some fields with validation. I have used different .NET validations like REquiredFieldValidator, RegularExpressionValidator and showed the summary...
3
by: Arun K | last post by:
Hi, I am creating a simple .aspx page to add some fields with validation. I have used different .NET validations like REquiredFieldValidator, RegularExpressionValidator and showed the summary...
0
by: bindslind | last post by:
The script does most of what it's supposed to do, but I have what seems to be a simple problem that I can't figure out. When the page intitially loads the first page does not display images. The same...
1
by: Benny Ng | last post by:
Dear All, Now I met one problem in the development of my one application. I have one ASP.NET page. It's for disply the information of customer. But now I have one new requirement. It's to...
2
by: erag | last post by:
Hi im newbie to java, and i want to set the language change according to main page..how to create it? here is my coding: main page: import org.eclipse.swt.SWT; import...
2
by: stevemtno | last post by:
I've got a problem with a web page I'm working on. I have 4 modules - one of them has 2 tabs, two of them have 4 tabs. When the user clicks on the tabs, the content below them changes. However, when...
7
by: imtmub | last post by:
I have a page, Head tag Contains many Scripts and style sheet for Menu and Page. This code working fine and displaying menus and page as i wanted. Check this page for reference....
0
by: abbasky | last post by:
### Vandf component communication method one: data sharing ​ Vandf components can achieve data exchange through data sharing, state sharing, events, and other methods. Vandf's data exchange method...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: stefan129 | last post by:
Hey forum members, I'm exploring options for SSL certificates for multiple domains. Has anyone had experience with multi-domain SSL certificates? Any recommendations on reliable providers or specific...
0
Git
by: egorbl4 | last post by:
Скачал я git, хотел начать настройку, а там вылезло вот это Что это? Что мне с этим делать? ...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
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
by: Aftab Ahmad | last post by:
Hello Experts! I have written a code in MS Access for a cmd called "WhatsApp Message" to open WhatsApp using that very code but the problem is that it gives a popup message everytime I clicked on...
0
by: Aftab Ahmad | last post by:
So, I have written a code for a cmd called "Send WhatsApp Message" to open and send WhatsApp messaage. The code is given below. Dim IE As Object Set IE =...

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.