Page 1 of 1
ExplorerTree - Windows Open Window
Posted: Mon Dec 01, 2008 11:23 am
by reisve
I need to make a Explorer Tree to work as the Windows Open (new file) Explorer or I can use the Windows Open Explorer.
Can any one point me to a solution?
Posted: Mon Dec 01, 2008 11:48 am
by Inf0Byt3
Is this what you need?
Code: Select all
If OpenWindow(0, 0, 0, 300, 300, "ExplorerTreeGadget", #PB_Window_SystemMenu | #PB_Window_ScreenCentered)
ExplorerTreeGadget(0, 10, 10, 280, 280, "*.*")
Repeat
Event = WaitWindowEvent()
If Event = #PB_Event_Gadget
Select EventGadget()
Case 0
If EventType() = #PB_EventType_LeftDoubleClick
Item = GetGadgetState(0)
If Item = #PB_Explorer_File
FilePath.s = GetGadgetText(0)
If FilePath <> ""
If RunProgram(FilePath) <> 0
Debug FilePath+" was launched"
Else
Debug "Error running: "+FilePath
EndIf
EndIf
EndIf
EndIf
EndSelect
EndIf
Until Event = #PB_Event_CloseWindow
EndIf
I hope I understood correctly.
Posted: Mon Dec 01, 2008 2:19 pm
by reisve
The code just give me an empty window.
I need sometng to let me save/create a file, with options to navigate in the directory tree, and create a new folder if necessary
Posted: Mon Dec 01, 2008 3:47 pm
by harff182
reisve wrote:The code just give me an empty window.
Not here. It opens an Explorer-like TreeView.
What version of PB are you using?
I need sometng to let me save/create a file, with options to navigate in the directory tree, and create a new folder if necessary
Why don't
OpenFileRequester() and
SaveFileRequester() fit your needs?
Posted: Tue Dec 02, 2008 10:15 am
by reisve
Thanks
OpenfileRequester was exactely what I was looking for