beqa Posted December 11, 2011 Posted December 11, 2011 hi all please help me. i want to move file to one folder jaws screenreader is a program for reading information on screen. i have several versions of jaws. i want to display all installed versions of jaws in a listview with checkboxes, check versions which i want and then when i will press on start button file must be moved in jaws folders which i checked. sorry my english isn't very good
Developers Jos Posted December 11, 2011 Developers Posted December 11, 2011 So, where are you getting stuck with coding this script? Show what you have and be explicit in what the problem is with it and what you are looking for. Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
beqa Posted December 11, 2011 Author Posted December 11, 2011 (edited) hi this is my code #NoTrayIcon #include <GUIConstantsEx.au3> #include <ButtonConstants.au3> #include <EditConstants.au3> #include <GuiListView.au3> Opt('GUICloseOnESC', 1) $hGUI = GUICreate("spmvs configurator", 300, 200) $gJAWS = GUICtrlCreateListView("JAWS Versions", 10, 150, 140, 20) _GUICtrlListView_SetExtendedListViewStyle($gJAWS, BitOR($LVS_EX_FULLROWSELECT, $LVS_EX_CHECKBOXES)) $hSave = GUICtrlCreateButton("start", 50, 20) $hCancel = GUICtrlCreateButton("close", 50, 20) $hAbout = GUICtrlCreateButton("about", 50, 20) GUISetState() While 1 Switch GUIGetMsg() Case 3, $hCancel ExitLoop case $HSave case $hAbout MsgBox(64, "about", 'SpmvsConfigurator Author beqa') ; Will demonstrate Button 2 being pressed EndSwitch WEnd i don't know how to get jaws versions from registry to arai and then display it in the listview or if it isn't right please help me Edited December 11, 2011 by Jos added CODE tags
water Posted December 11, 2011 Posted December 11, 2011 (edited) Please post code in AutoIt tags [ autoit] and [ /autoit] (without the space). To retrieve data from the registry use functions RegRead or search the forum for one of the many registry UDFs. Using google I found the following: http://svn.haxx.se/tsvn/archive-2010-05/0005.shtml Ok, here is the way to find out that JAWS is installed and what version is used: Edited December 11, 2011 by water My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki
beqa Posted December 11, 2011 Author Posted December 11, 2011 ok, thanks very mutch, i know how to read information from the registry, i don't know how to display this subkeys in listview. Ok, here is the way to find out that JAWS is installed and what version is used: The registry key: HKEY_LOCAL_MACHINESOFTWAREFreedom ScientificJAWS contains all versions of JAWS that are located on this machine, that is the subkeys: 9.0, 10.0, 11.0 mean that the versions 9.0, 10.0, 11.0 are installed side by side - it is a very often practice in JAWS installations - a lot of people use a couple versions of JAWS at the same time for different reasons. please help me
Developers Jos Posted December 11, 2011 Developers Posted December 11, 2011 Moved from Examples to Support . so please read the forum purpose before creating a topic to ensure it is in the correct forum. When you know how to read the registry I wonder why that logic isn't in the posted script yet? What does the helpfile tell you about filling entries in the Control created by GUICtrlCreateListView? There is a nice simple example there and explaining how it works. SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
beqa Posted December 11, 2011 Author Posted December 11, 2011 i can't display jaws versions in listview i don't understand how to do that
beqa Posted December 11, 2011 Author Posted December 11, 2011 please help me to display subkeys from registry in listview. subkeys mean versions of jaws.
beqa Posted December 13, 2011 Author Posted December 13, 2011 hey guis please help me to display subkeys from registry in listview
water Posted December 13, 2011 Posted December 13, 2011 (edited) This short example should give you an idea: #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> Opt('MustDeclareVars', 1) Global $listview, $button, $item1, $item2, $item3, $input1, $msg ;Global $sKey = "HKEY_LOCAL_MACHINESOFTWAREFreedom ScientificJAWS" Global $sKey = "HKEY_LOCAL_MACHINESOFTWAREMicrosoftOffice" GUICreate("listview items", 220, 250, 100, 200, -1, $WS_EX_ACCEPTFILES) $listview = GUICtrlCreateListView("col1", 10, 10, 200, 150) _GetSubkey($skey) GUISetState() Do $msg = GUIGetMsg() Until $msg = $GUI_EVENT_CLOSE Func _GetSubkey($sKey) Local $iIndex = 1, $sSubKey While 1 $sSubKey = RegEnumKey($skey, $iIndex) If @error <> 0 Then ExitLoop ConsoleWrite($sSubkey & @CRLF) GUICtrlCreateListViewItem($sSubKey, $listview) $iIndex += 1 WEnd Return EndFunc ;==>_GetSubkey Edited December 13, 2011 by water My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki
Mikeman27294 Posted December 13, 2011 Posted December 13, 2011 $Version = RegRead('HKEY_LOCAL_MACHINESOFTWAREFreedom ScientificJAWS', 'Version');I dont know the name of the subkey so rename version to whatever it is. $Gui = GUICreate("ListView", 500, 500) ;Creates the GUI $ListView = GUICtrlCreateListView("Name|Value", 0, 0, 500, 500) ;Create a list view control $LVItem = GUICtrlCreateListViewItem("Version|"&$Version, $ListView) ;Create the required list view item - This is where the magic happens GUISetState(@SW_SHOW, $Gui) ;Show the GUI While 1 ;Infnite loop until the program is ended If GUIGetMsg() = -3 Then ;If the close button is clicked Exit ;Exit the program EndIf ;Declares the end of the if statement WEnd ;Declares the end of the while loop Since I don't have this JAWS program you talk about installed, I don't know whether the subkey in regread (version) is the correct name, so you will have to change that. I hope this works for you, but I dont quite understand EXACTLY what you need from it.
beqa Posted December 13, 2011 Author Posted December 13, 2011 thanks vater very mutch. it works for me very well
water Posted December 13, 2011 Posted December 13, 2011 My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki
beqa Posted December 13, 2011 Author Posted December 13, 2011 ok i understand. now another question. how i can move files in folders which are selected? e.g. i have jaws versions 12 and 13 installed i want to move files in this folders. my code is bellow. [ autoit] #NoTrayIcon #include <GUIConstantsEx.au3> #include <ButtonConstants.au3> #include <EditConstants.au3> #include <GuiListView.au3> Opt('GUICloseOnESC', 1) $hGUI = GUICreate("spmvs configurator", 300, 200) $sJAWS = "HKEY_LOCAL_MACHINESOFTWAREFreedom ScientificJAWS" $hJAWS = GUICtrlCreateListView("volume", 10, 150, 140, 20) _GUICtrlListView_SetExtendedListViewStyle($hJAWS, BitOR($LVS_EX_FULLROWSELECT, $LVS_EX_CHECKBOXES)) _GetSubkey($sjaws) $hSave = GUICtrlCreateButton("movefile", 50, 20) $hCancel = GUICtrlCreateButton("close", 50, 20) $hAbout = GUICtrlCreateButton("about", 50, 20) GUISetState() While 1 Switch GUIGetMsg() Case 3, $hCancel ExitLoop case $HSave ;i don't know what i must write case $hAbout MsgBox(64, "about", 'SpmvsConfigurator Author beqa') ; Will demonstrate Button 2 being pressed EndSwitch WEnd Func _GetSubkey($sjaws) Local $iIndex = 1, $sSubKey While 1 $sSubKey = RegEnumKey($sjaws, $iIndex) If @error <> 0 Then ExitLoop ConsoleWrite($sSubkey & @CRLF) GUICtrlCreateListViewItem($sSubKey, $hjaws) $iIndex += 1 WEnd Return EndFunc;==>_GetSubkey[ /autoit]
water Posted December 13, 2011 Posted December 13, 2011 Why do you want to move files? Doesn't JAWS (the screenreader) come with an installation program? My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki
beqa Posted December 13, 2011 Author Posted December 13, 2011 ok i will explain. yes jaws comes with installer, but in jaws you can write scripts to extend functional of screenreader. i wrote scripts for jetaudio and want to make an installer which will move script files in to userprofile's folder. it is %appdata%freedom scientificjawsversion. from subkeys i can get folder paths.
water Posted December 13, 2011 Posted December 13, 2011 To move files use the - you guessed it - FileMove function. I haven't done selecting entries of an ListView by checkboxes. But if you search the forum for $LVS_EX_CHECKBOXES you will find a lot of scripts which will show you how to code. My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki
beqa Posted December 13, 2011 Author Posted December 13, 2011 ok, and finally question. how i can display folders in scripts folder which is located in script folder. e.g. with script.exe is located folder scripts and in scripts are located folders with dates. e.g. jetaudio scriptsforjaws 2011.12.13. how i can display in first column all folders located in scripts and in second column dates?
beqa Posted December 15, 2011 Author Posted December 15, 2011 people please help me to display directories which are in scripts directory and scripts directory is in program directory
water Posted December 15, 2011 Posted December 15, 2011 _FileListToArray and then create the ListView from the returned array. My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now