473,386 Members | 2,078 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,386 software developers and data experts.

Wizard ActiveStep or MoveTo method Won't Navigate

The Wizard is on Step5 and some TextBox validation in Step5 has to be done
on the server so I've been thinking I need to use the OnActiveStepChanged
event. This server-side validation has to be done on the client too but for
now I'm trying to work it out on the server. Interesting to note a simple
return false; on the client keeps Step5 currently active -- but -- this news
article is about doing so on the server.

That is, when the validation test equates as true the Wizard must continue
to display the same step, i.e. Step5 must stay displayed but another step is
always displayed instead; Step6 for example when selecting the Next button.

Using the Previous button to navigate back to Step5 proves the validation
code is functioning because the Wizard1Label.Text property is changed as
expected.

But the damn step won't stay set to Step5 when trying to use the Next button
or when selecting a SideBar DataList item both of which raise the
OnActiveStepChanged event.
What can I do to keep Step5 displayed?

// OnActiveStepChanged event handler
public void OnActiveStepChanged(object sender, EventArgs e)
{
if (Wizard1.ActiveStepIndex
==
Wizard1.WizardSteps.IndexOf(this.Step5))
{
// Correctly Displays: 5
Page.Title = Wizard1.ActiveStepIndex.ToString();

if (Step5_EmailTextBox.Text.Length 0
&&
Step5_NameTextBox.Text.Length 0)
{
// Trying ActiveStepIndex won't keep Step5 active
Wizard1.ActiveStepIndex = 5;

// Trying MoveTo moves to other steps but
// won't keep Step5 active either
Wizard1.MoveTo(this.Step5);

Wizard1Label.Text =
"Only one TextBox may contain a data entry.";
}
else
{
Wizard1Label.Text = "-- or --";
}
}
}

I've searched around and haven't found any tips yet. I hope somebody
has some insight on this...

<%= Clinton Gallagher
NET csgallagher AT metromilwaukee.com
URL http://clintongallagher.metromilwaukee.com/
Mar 17 '07 #1
0 2306

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

Similar topics

4
by: Dabbler | last post by:
I have a Wizard control with each step using a user control. It seems the page_load of each user control is called everytime a postback event occurs in any step. Is there away to communicate to a...
3
by: John Mott | last post by:
Hi All, I'm trying to set the defaultbutton for a form to a button contained in a step template for a wizard control. This is the code in PreRender: switch (myWizard.ActiveStep.StepType) {...
0
by: clintonG | last post by:
OBJECTIVE: A Wizard control often needs two TextBoxes on specific steps. In this instance both Step5 and Step6 each require two TextBoxes in each step, that is, each step requires a TextBox to...
1
by: Nightcrawler | last post by:
I am using a Wizard control with 5 steps. On step 2 the user is present with a radiobuttonlist with two listitems in it. If the first radiobutton is selected I want to take the user to step 3, if...
0
by: =?Utf-8?B?TWFyaw==?= | last post by:
Hi, When redirecting to my aspx page, I check if user is authenticated. If user is authenticated I use the Wizard's MoveTo method to skip the first step. This works as expected only I get a...
3
by: M. Ali Qureshi | last post by:
Hi, I have a wizard in my aspx page, and i create steps programatically. There are about 8 steps in all. The default text for StepNextButton is "Next". But i want that only in step 4, the next...
1
by: Elmo Watson | last post by:
In my wizard, the user is 'creating' a new project - really only inserting into a master table in the database. Once they've done this, I don't want them to be able to come back to that first...
2
by: GaryDean | last post by:
In this event I can tell where I'm going via e.NextStepIndex but how can I tell where I am coming from? Do I have to setup Session and track it myself? -- Regards, Gary
0
by: Craig Buchanan | last post by:
I'm using the Wizard control in the 2.0 framework. I need to perform a validation on each of the steps of the wizard in the Finish button click event. This scenario would occur if the user...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

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.