AutoHotkey Community

It is currently May 27th, 2012, 12:24 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 21 posts ]  Go to page Previous  1, 2
Author Message
 Post subject:
PostPosted: May 28th, 2009, 10:09 am 
Offline

Joined: March 27th, 2008, 7:46 pm
Posts: 129
Location: France
Sean wrote:
This is what I'm using. 100% AHK made.

:wink: Big good!Sean,
-> it's a combobox, like i looking for!
-> good presentation, and i like the resizing (0x4000 ? dont't run on my gui)
:?: Can you say us some more?

_________________
with ahk, all is different!...<img>


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: May 28th, 2009, 11:04 am 
Online
User avatar

Joined: December 26th, 2005, 4:40 pm
Posts: 8776
soggos wrote:
but it's retrieve the number of the line, not the Line!


Remove AltSubmit in the following line:

Code:
Gui, Add, ComboBox, w640 R25 Simple AltSubmit vSelected, %commands%


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: May 28th, 2009, 2:04 pm 
Offline

Joined: March 27th, 2008, 7:46 pm
Posts: 129
Location: France
SKAN wrote:
Remove AltSubmit in the following line..

:D SKAN very good !
And Now i know many thing...
(the Simple signification 0x1 , and more...)
At this time, i have that:
Code:
#noenv
     SetTimer ,UPDATEDSCRIPT,1000   
;   ===========================================================

Menu, Tray, Click, 1
Menu, Tray, Add,
Menu, Tray, Add, Show_Hide
Menu, Tray, Add, info
Menu, Tray, Standard
Menu, Tray, Default , Show_Hide
;   ===========================================================

   CONSOLE:

Gui, Add, ComboBox,x-1 y-1 w400 Simple  vSelected gclick ,    ;; AltSubmit   for> number line   ;; & Simple=0x1   ;;
                                                ;; ? And for adding graphical resize ? at the right-bottom

 gui -caption                           ; No Tile-Bar
   CoordMode, Mouse , Screen                 ; coord sreen
   MouseGetPos,x,y                       ; coord souris
   gui show,x%x% y%y% w400 h300, NOM_du_PROGRAM   ; SHOW gui under Mouse

SplitPath, A_AhkPath,, A_AhkDir
le_Fichier_de_Lecture=  %A_AhkDir%\Extras\Editors\Syntax\Commands.txt
   gosub CHARGER_le_Fichier_de_Lecture      ; Charger le Fichier Cmd de départ
   ControlFocus, Selected, NOM_du_PROGRAM    ; Set focus to the ComboBox
Return
;   =========================================================== //
;   =========================================================== //


;   =========================================================== // Show_Hide the gui
   Show_Hide:
Gui , +LastFoundExist
IfWinExist ,
   {
      WinGetPos , SCT_X, , , , NOM_du_PROGRAM
      If SCT_X=
      {   Gui , Show
       WinActivate ,NOM_du_PROGRAM
      }
      Else
         Gui  Hide
   }
   else
   Gosub CONSOLE
Return
;   =========================================================== //

;   =========================================================== HOTKEY gui Show_Hide
    #p:: goto Show_Hide
;    ~#p:: goto Show_Hide
   info:
   MsgBox , 4160 , ,  windows+P => Show_Hide`nOne Left-Click to See the Line`nDble Left-Click => copy to clipboard`nRight-Click to Hide the Gui.
Return
;   ===========================================================//

;   =========================================================== ; IfWinActive (ENTER)
#IfWinActive NOM_du_PROGRAM
   enter::
   GuiControlGet , Selected
   ; ??? BUT  HOW-To just save the "selected" of the vSelected ???
   clipboard := Selected
   gui hide
Return
#IfWinActive
;   ===========================================================//

;   =========================================================== ; click ; Just for a Double/Clique
   click:
   if A_GuiEvent = Normal      
      return
   GuiControlGet , Selected
   clipboard := Selected
   gui hide
Return
;   ===========================================================//

;   =========================================================== ; GuiSize
   GuiSize:
   if ErrorLevel = 1
      return
   WinGetPos , ,, large, haut, NOM_du_PROGRAM
   ; haut:=haut-22         ; with my titlbar
   ; large:=large-5      ;
   GuiControl , Move, Selected, W%large% H%haut%
Return
;   ===========================================================//

   
;   =========================================================== ; GuiDropFiles
;    ²BUT The AUTOcomplet dont't run after the drop !! ?why¿
;
   GuiDropFiles:
   Loop, parse, A_GuiEvent, `n
      SelectedFileName = %A_LoopField%
   FileGetAttrib ,attribs, %SelectedFileName%   
    IfInString , attribs, D         ; si dossier/Directory
      Return                  ; si dossier!> return
   GuiControl , , Selected, |               ; remize à zero
   le_Fichier_de_Lecture= %SelectedFileName%   ; Définir le Fichier de Cmd
   Gosub CHARGER_le_Fichier_de_Lecture         ; charger le Fichier de Cmd
   return
;   ===========================================================//


;   =========================================================== ; Guiclose
GuiContextMenu:  ; Launched in response to a RIGHT-CLICK or press of the Apps key.
   Guiclose:
   GuiEscape:
   gui hide
return
;   ===========================================================//


;   =========================================================== ;  CHARGER_le_Fichier_de_Lecture
   CHARGER_le_Fichier_de_Lecture:
   FileRead , Commands, %le_Fichier_de_Lecture%
   StringReplace , Commands, Commands, |, \, All
   StringReplace , Commands, Commands, `r, , All
   StringReplace , Commands, Commands, `n,| , All
   GuiControl , , Selected, %Commands%
return
;   =========================================================== //


;   =========================================================== ; the so good UPDATEDSCRIPT
   UPDATEDSCRIPT:
      FileGetAttrib,attribs,%A_ScriptFullPath%
      IfInString,attribs,A
      {
        FileSetAttrib,-A,%A_ScriptFullPath%
        posX = %A_CaretX%
        posY = %A_CaretY%
        ToolTip, Updated script> %A_ScriptName%, %posX%, %posY%
        Sleep,500
        Reload
      }
   Return
;   =========================================================== //
; END.soggos 28 Mai 2009


little img:
Image

_________________
with ahk, all is different!...<img>


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: May 29th, 2009, 3:41 am 
Offline

Joined: February 12th, 2007, 7:54 am
Posts: 2462
I posted it as a demonstration that you can do what you want to do. I have no intention to release the code. I can only tell that it's based on the script (:don't use the script as it is as it contains an error which may leak memories).
http://www.autohotkey.com/forum/topic21179.html


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: October 1st, 2009, 11:09 pm 
Offline

Joined: September 6th, 2009, 4:22 pm
Posts: 20
SKAN wrote:
Code:
Gui, Add, Combobox, x7 y7 w550 h21 Choose1 hwndhSHAC vtFolder, %tFolder%
ControlGet, hMyEdit, hWnd,, Edit1, ahk_id %hSHAC%
DllCall( "ole32\CoInitialize", UInt,0 )
DllCall( "shlwapi\SHAutoComplete", UInt,hMyEdit, UInt,0x1|0x10000000 )
Gui, Add, Button, x+5 w30 hp +Default gExecute, Go
Gui, Show, h130, ShAutoComplete
Return

Execute:
 ControlGetText,cmdLine,, ahk_id %hSHAC%
 Run, %CmdLine%
Return

; Above code taken from IconEx-v1.00: www.autohotkey.com/forum/topic31670.html
; Originally, Sean posted at : www.autohotkey.com/forum/viewtopic.php?p=121621#121621

Quick question, If I add:
Code:
tFolder = C:\
(1)How can I start in this drive, without showing "C:" it in the comboBox?
(2)How do you get the comboBox to auto expand, as soon as the script is run?


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: May 25th, 2011, 9:26 am 
Offline
User avatar

Joined: November 19th, 2010, 9:54 am
Posts: 184
SKAN wrote:
Code:
Gui, Add, Combobox, x7 y7 w550 h21 Choose1 hwndhSHAC vtFolder, %tFolder%
ControlGet, hMyEdit, hWnd,, Edit1, ahk_id %hSHAC%
DllCall( "ole32\CoInitialize", UInt,0 )
DllCall( "shlwapi\SHAutoComplete", UInt,hMyEdit, UInt,0x1|0x10000000 )
Gui, Add, Button, x+5 w30 hp +Default gExecute, Go
Gui, Show, h130, ShAutoComplete
Return

Execute:
 ControlGetText,cmdLine,, ahk_id %hSHAC%
 Run, %CmdLine%
Return

; Above code taken from IconEx-v1.00: www.autohotkey.com/forum/topic31670.html
; Originally, Sean posted at : www.autohotkey.com/forum/viewtopic.php?p=121621#121621


Any idea how to make it work with entries from a list? Not paths though, I want to make it work in a fuzzy search script.

Help is appreciated.


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 21 posts ]  Go to page Previous  1, 2

All times are UTC [ DST ]


Who is online

Users browsing this forum: Bing [Bot], chaosad, Exabot [Bot], jrav and 14 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group