z-index issue with showDialog()

speak newbie to me.
I have an application that has a wizard which is a dialog not a form, apparently this was done in order for it to freeze the application while the wizard is running. Now the thing is the wizard has 2 buttons, one brings up a showDialog using an openFileDialog and the other and Directory dialog - the directory one is opening up behind my wizard, and the other in front - what's up with that?
LVL 39
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

which did you call first?
blue-genieAuthor Commented:
doesn't matter which one i call first.
they're on button events. the directory one always pops to the back.
why do you have 2 dialogs open?
JavaScript Best Practices

Save hours in development time and avoid common mistakes by learning the best practices to use for JavaScript.

blue-genieAuthor Commented:
i dont' have 2 dialogs open. the user gets to pick to select a folder or a file, if they pick a file they click the file button, that opens the file dialog box which is fine, if they click the folder one, that one opens up behind the wizard!!!!
When you show OpenFileDialog or Directory dialog, use this as ShowDialog parameter. this points to wizard form.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
blue-genieAuthor Commented:
Now that is just sheer genius!!!!!!!!!!!!!!!!
Thanks this much!!!!
u're the sh*t!!!!
awesome i'm ur new number 1 fan!!!!!!
bg :-)
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.