?
Solved

Removing wizardsteps in vb.net gives the error "Argument out of rabge exception"

Posted on 2009-07-13
3
Medium Priority
?
213 Views
Last Modified: 2013-11-26
I have 6 wizardsteps, represented as 6 buttons in the SideBar (not using Next and Previous buttons)
For some records in the db I do not need wizardstep 5 an 6
If I click on wizardstep 5 or 6 and then move to a record which doesn't need step 5 and 6, I do:
 wizardStep.RemoveAt(6)
 wizardStep.RemoveAt(5)

This gives the crash error "Argument out of range exception".
If I move to wizardstep 4, before moving on to changing record, things goes well
I hav tried all ways of workarounds I feel, with no success
0
Comment
Question by:Joar
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 8

Expert Comment

by:dericstone
ID: 24843428
It's not clear why you want to remove wizard steps. Don't you just want to skip over some?

In any case, I think the wizard steps are indexed with a base zero index. So index 6 might not exist - use indices 0 - 5. You can check this by calling IndexOf on the wizard steps you are interested in skipping.

If I'm not helping here, please post some code.
0
 

Author Comment

by:Joar
ID: 24843657
No, I want to remove the steps, because they are meaningless for some records.
I know about the zero based step index, so in the example above I ment to remove steps 4 and 5...

May be I should use another technique than wizardsteps, for example multiview??
The only thning I want is having some buttons in the left margin.
Clicking on different buttons, I want to display different windows in the right part of the page.

0
 

Accepted Solution

by:
Joar earned 0 total points
ID: 24847659
The MultiView was the answer to my problem
0

Featured Post

Setting up LaraDock for Laravel

Learn how to set up LaraDock in a Laravel project - LaraDock gives us an easy way to run a Laravel application using Docker in a single command.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
This article shows how to deploy dynamic backgrounds to computers depending on the aspect ratio of display
Google currently has a new report that is in beta and coming soon to Webmaster Tool accounts. This Micro Tutorial will highlight new features for Google Webmaster Tools.
Shows how to create a shortcut to site-search Experts Exchange using Google in the Chrome browser. This eliminates the need to type out site:experts-exchange.com whenever you want to search the site. Launch the Search Engine Menu: In chrome, via you…
Suggested Courses

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question