Sign in to follow this  
Followers 0
ideleon007

Collect, display & use TreeView data

3 posts in this topic

hello,

I'm looking for a way to read the directory structure and then automatically display whatever

the user is selecting right beneath the directory tree.

1.)Is there a way to do this?

2.) When you do a drop down list, how do you alphebetize your selection?

Under "Select Drive," I have the letter "L" but when you hit the up/down arrow I get numbers.

Doesn't this do the alphabet as it does numbers?

3.) But after all this, how do I read the information that I have collected?

- path

- drive

- Act when DONE button is pressed

I have spent a coupld of hours looking over the help files and web site examples,,,

any help appreciated,,,

here's the code:

#AutoIt3Wrapper_au3check_parameters=-d -w 1 -w 2 -w 3 -w 4 -w 5 -w 6

#include <GuiConstantsEx.au3>

#include <GuiConstants.au3>

#include <GuiTreeView.au3>

#include <GuiImageList.au3>

#include <WindowsConstants.au3>

; GUI

GuiCreate("The X-Files, Xythos", 500, 500)

GuiSetIcon(@SystemDir & "\mspaint.exe", 0)

GuiCtrlCreateLabel("1. Select a directory you want to map.", 10, 5, 200, 20)

GuiCtrlCreateLabel("2. Select the drive you want to map it to.", 10, 20, 200, 20)

GuiCtrlCreateLabel("3. Key in your Net ID and your AD Password.", 240, 5, 215, 30)

GuiCtrlCreateLabel("4. Click DONE.", 240, 20, 200, 20)

; UPDOWN

GuiCtrlCreateLabel("Select Drive:", 425, 60)

GuiCtrlCreateInput("L", 450,75, 40, 20)

GuiCtrlCreateUpDown(-1)

; TREEVIEW ONE

$treeOne = GuiCtrlCreateTreeView(10, 80, 425, 270)

$treeItem = GuiCtrlCreateTreeViewItem("Shared", $treeOne)

; $idChild = GUICtrlCreateTreeViewItem("Child " & $c, $idItem)

$AS = GuiCtrlCreateTreeViewItem("Administrative Services", $treeItem)

$ASBS = GuiCtrlCreateTreeViewItem("Business Services", $AS)

$ASER = GuiCtrlCreateTreeViewItem("Employee Resources", $AS)

$ASF = GuiCtrlCreateTreeViewItem("Facilities", $AS)

$ASPR = GuiCtrlCreateTreeViewItem("Public Relations", $AS)

$CSI = GuiCtrlCreateTreeViewItem("Collection Services and Innovation", $treeItem)

$CSIER = GuiCtrlCreateTreeViewItem("Electronic Resources", $CSI)

$CSIMAA = GuiCtrlCreateTreeViewItem("Monographs and Automated Acquisitions", $CSI)

$CSICSS = GuiCtrlCreateTreeViewItem("Collection and Support Services", $CSI)

$CSICSSCRS = GuiCtrlCreateTreeViewItem("Catalog Record Support", $CSICSS)

$CSICSSC = GuiCtrlCreateTreeViewItem("Cataloging", $CSICSS)

$CSICSSS = GuiCtrlCreateTreeViewItem("Shelving", $CSICSS)

$CSIDSC = GuiCtrlCreateTreeViewItem("Digital and Scholarly Communications", $CSI)

$CSIDDS = GuiCtrlCreateTreeViewItem("Document and Delivery Services", $CSI)

$CSILOS = GuiCtrlCreateTreeViewItem("Learning and Outreach Services", $CSI)

$CSIPSEL = GuiCtrlCreateTreeViewItem("Policy Sciences and Economic Library", $CSI)

$CSIPRS = GuiCtrlCreateTreeViewItem("Public and Research Services", $CSI)

$CSIPRSPS = GuiCtrlCreateTreeViewItem("Public Services", $CSIPRS)

$CSIPRSPSMR = GuiCtrlCreateTreeViewItem("Media and Reserves", $CSIPRSPS)

$CSISELS = GuiCtrlCreateTreeViewItem("Science and Engineering Liasion Services", $CSI)

$CSIWCL = GuiCtrlCreateTreeViewItem("West Campus Library", $CSI)

$C = GuiCtrlCreateTreeViewItem("Committees", $treeItem)

$CU = GuiCtrlCreateTreeViewItem("Cushing", $treeItem)

$CUCG = GuiCtrlCreateTreeViewItem("Cushing Gifts", $CU)

$CUCRM = GuiCtrlCreateTreeViewItem("Cushing Records Management", $CU)

$DI = GuiCtrlCreateTreeViewItem("Digital Initiatives", $treeItem)

$DICS = GuiCtrlCreateTreeViewItem("Consortia Systems", $DI)

$DIOCS = GuiCtrlCreateTreeViewItem("Operations and Client Services", $DI)

$DIRT = GuiCtrlCreateTreeViewItem("Research and Technology", $DI)

$DISN = GuiCtrlCreateTreeViewItem("Systems and Networking", $DI)

$DIWSe = GuiCtrlCreateTreeViewItem("WEB Services", $DI)

$DIWSy = GuiCtrlCreateTreeViewItem("WEB Systems", $DI)

$MSL = GuiCtrlCreateTreeViewItem("Medical Sciences Library", $treeItem)

$MSLAS = GuiCtrlCreateTreeViewItem("Administration Services", $MSL)

$MSLCS = GuiCtrlCreateTreeViewItem("Client Services", $MSL)

$MSLRS = GuiCtrlCreateTreeViewItem("Resource Management", $MSL)

GuiCtrlSetState($treeItem, $GUI_EXPAND)

;GUICreate ( "title" [, width [, height [, left [, top [, style [, exStyle [, parent]]]]]]] )

; BUTTON

;GuiCtrlCreateButton("DONE", L/Right, height, Width of box, Height of box)

$donebutton = GuiCtrlCreateButton("DONE", 425, 465, 50, 30)

; DATE

GuiCtrlCreateDate("", 5, 465, 200, 20)

;GuiCtrlCreateLabel("(Date control expands into a calendar)", 10, 305, 200, 20)

;GuiCtrlCreateLabel("PATH :", 10, 350)

;GuiCtrlCreateLabel("PATH :", 10, 362)

GuiCtrlCreateLabel("Psycho PATH Selected :", 10, 350)

Share this post


Link to post
Share on other sites



I'm looking for a way to read the directory structure and then automatically display whatever

the user is selecting right beneath the directory tree.

have a look here for an autoit script that does pretty much everything ou are looking for.


Wallpaper Rotatorwith overlay, Loop through a folder of wallpaper & another of overlay, then create a combined image and set it as the wallpaperE-Mail passthru, Send any file, even executables via e-mail as plain text. The recipient can then later re-construct them.Slideshow widget, A slideshow widget similar to the Vista onePredictive typing using the Numpad, Predictive typing using the numpad of a keyboar similar to that on a mobile phone (the key is the .t16 file).PSTools Front End, For Remote Admin. Just makes life a lot easier (Demonstrates executing external programs and passing parameters, tabbed form Handling STDIN/STDERR)FTP Helper application Up and Download files from an FTP server demonstrates this and Tooltray TipsShow a Map of your Post-codes/Zip Codes, Uses the Clipboard, Hotkeys, the system tray (incl. menus)Disc/CD/DVD Catalogue, Ideal for all those Covermount Discs (Demonstrates Array handling, executing DOS programs, handling STDIN/STDOUT recursive directory reads, file searching.)YAST , Yet another Stopwatch/Timer (Uses a hotkey, Copies to clipboard, handles multiple events and stays on top)Keyboard Status Indicator , Indicates status of NumLock, Caps Lock and Scroll Lock Keys, demonstrates API calling & System tray Icon Toggling

Share this post


Link to post
Share on other sites

have a look here for an autoit script that does pretty much everything ou are looking for.

thanks for the note,,,,

I looked at it, but I'm a little confused with the coding.

I've lived too long in the AutoIt 2 and early 3 years.

How did you read what you were selecting from the tree and display it realtime?

I was trying to make sense of the $FullPath and the $dirclicked variable, but to no avail.

thanks again,

israel

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0