IGUIFileOpenDialog can`t find file in another driver

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
h++
Posts: 12
Joined: Fri Dec 04, 2009 9:13 am

IGUIFileOpenDialog can`t find file in another driver

Post by h++ »

I am using IGUIFileOpenDialog and it works well! But I found the IGUIFileOpenDialog seems can only find file in current disk driver. Hence how to change the working directory by code?

I found someones code like this:

env->addFileOpenDialog(L"Please select a model file to open");

IGUIFileOpenDialog* dialog =
(IGUIFileOpenDialog*)event.GUIEvent.Caller;
loadModel(core::stringc(dialog->getFilename()).c_str());

but I don`t know what dose it means?

Can somebody so a hand for me!
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Post by CuteAlien »

You should be able to type the drive-letter in the editbox where it shows the path. FileOpen dialog is not yet that much advanced, but that should at least work.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
h++
Posts: 12
Joined: Fri Dec 04, 2009 9:13 am

Post by h++ »

CuteAlien wrote:You should be able to type the drive-letter in the editbox where it shows the path.
Can you tell me further details
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Post by CuteAlien »

h++ wrote:
CuteAlien wrote:You should be able to type the drive-letter in the editbox where it shows the path.
Can you tell me further details
Uhm... I don't think there is more to it. You type in the new driveletter (like "d:" and that's it.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
JP
Posts: 4526
Joined: Tue Sep 13, 2005 2:56 pm
Location: UK
Contact:

Post by JP »

I made a much better fileopen (and save) dialog class in the code snippets forum which might be of use to you.
Image Image Image
h++
Posts: 12
Joined: Fri Dec 04, 2009 9:13 am

Post by h++ »

Yet, Thank you!
But I wanted to let the window which can change disk when it arrived at the root directory.
Post Reply