Jump to content
Skysnake

[solved] List scroll horizontal - undocumented feature?

Recommended Posts

Skysnake

 

$ListLHT = GUICtrlCreateList("", 8, 152, 664, 279,BitOR($WS_GROUP,$WS_BORDER,$WS_VSCROLL,$WS_HSCROLL))

 

Hi, code works, but not documented.  Its not in the Help file, but HSCROLL works for List :)

3.3.12.0

If I am wrong, please point me in the right direction.

Have a nice day now

Edited by Skysnake
edit: solved

Skysnake

Why is the snake in the sky?

Share this post


Link to post
Share on other sites
Melba23

Skysnake,

Why would it not work - the style can be applied to any control with the ability to scroll horizontally. And why do you say it is "not documented"? It is not part of the default style AutoIt applies to the control, but there is nothing to say that it cannot be added if the coder so wishes.

M23


Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind._______My UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Share this post


Link to post
Share on other sites
Skysnake

am i being silly?

the Help file contains this for GuiCtrlCreateList

mk:@MSITStore:C:\Program%20Files\AutoIt3\AutoIt.chm::/html/functions/GUICtrlCreateList.htm

 

[optional] Defines the style of the control. See GUI Control Styles Appendix.
    default ( -1) : $LBS_SORT, $WS_BORDER, $WS_VSCROLL
    forced styles : $WS_TABSTOP, $LBS_NOTIFY

 

mk:@MSITStore:C:\Program%20Files\AutoIt3\AutoIt.chm::/html/appendix/GUIStyles.htm#ListBox

 

this section does not contain a reference to HScroll...

 

Undocumented

I was under the impression I could only use Style option defined.  If this is not so, which other Style options are available which the Help file does not list?  I look at the Help file to see which options are available - HScroll is not listed.

Have I expressed myself properly?

 

Edited by Skysnake

Skysnake

Why is the snake in the sky?

Share this post


Link to post
Share on other sites
jchd

$WS_HSCROLL is in due place in the help file under GUI control styles, just like $WS_VSCROLL. It's also used in a number of GUI examples.


This wonderful site allows debugging and testing regular expressions (many flavors available). An absolute must have in your bookmarks.
Another excellent RegExp tutorial. Don't forget downloading your copy of up-to-date pcretest.exe and pcregrep.exe here
RegExp tutorial: enough to get started
PCRE v8.33 regexp documentation latest available release and currently implemented in AutoIt beta.

SQLitespeed is another feature-rich premier SQLite manager (includes import/export). Well worth a try.
SQLite Expert (freeware Personal Edition or payware Pro version) is a very useful SQLite database manager.
An excellent eBook covering almost every aspect of SQLite3: a must-read for anyone doing serious work.
SQL tutorial (covers "generic" SQL, but most of it applies to SQLite as well)
A work-in-progress SQLite3 tutorial. Don't miss other LxyzTHW pages!
SQLite official website with full documentation (may be newer than the SQLite library that comes standard with AutoIt)

Share this post


Link to post
Share on other sites
Melba23

Skysnake,

Look at the headers of the style constants - the ListBox specific ones begin $LBS_*, while the Scroll styles begin $WS_* which can be applied to any "window".  So the styles are documented, but you have to look in the correct place.

M23


Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind._______My UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Share this post


Link to post
Share on other sites
Skysnake

Thank you.  I did not know that. 

$WS_HSCROLL0x00100000Creates a window that has a horizontal scroll bar.

I did not know that that "window" applies any controls... Made a note. Thank you 


Skysnake

Why is the snake in the sky?

Share this post


Link to post
Share on other sites
jchd

Yes, that seems surprising at first but that's how MS calls things.


This wonderful site allows debugging and testing regular expressions (many flavors available). An absolute must have in your bookmarks.
Another excellent RegExp tutorial. Don't forget downloading your copy of up-to-date pcretest.exe and pcregrep.exe here
RegExp tutorial: enough to get started
PCRE v8.33 regexp documentation latest available release and currently implemented in AutoIt beta.

SQLitespeed is another feature-rich premier SQLite manager (includes import/export). Well worth a try.
SQLite Expert (freeware Personal Edition or payware Pro version) is a very useful SQLite database manager.
An excellent eBook covering almost every aspect of SQLite3: a must-read for anyone doing serious work.
SQL tutorial (covers "generic" SQL, but most of it applies to SQLite as well)
A work-in-progress SQLite3 tutorial. Don't miss other LxyzTHW pages!
SQLite official website with full documentation (may be newer than the SQLite library that comes standard with AutoIt)

Share this post


Link to post
Share on other sites
Melba23

Skysnake,

In simple terms everything in Windows is a "window" with a unique handle - only in human parlance are they are called GUIs, dialogs, controls, etc.  So you can apply $WS_* styles to practically anything - but I would counsel against getting too adventurous as some styles might well not do what you expect and cause big problems!

M23

Edit: Bonsoir jchd - je vois que tes doigts sont les plus vites aujourd'hui!

Edited by Melba23

Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind._______My UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Share this post


Link to post
Share on other sites
jchd

Hi M23,

I'm in a bit of a hurry: we just had quadruplets(*) yesterday and they are very demanding! Feed them every 30 minutes for instance (night & day)...

* They are wren birds, aged 5 days.

  • Like 1

This wonderful site allows debugging and testing regular expressions (many flavors available). An absolute must have in your bookmarks.
Another excellent RegExp tutorial. Don't forget downloading your copy of up-to-date pcretest.exe and pcregrep.exe here
RegExp tutorial: enough to get started
PCRE v8.33 regexp documentation latest available release and currently implemented in AutoIt beta.

SQLitespeed is another feature-rich premier SQLite manager (includes import/export). Well worth a try.
SQLite Expert (freeware Personal Edition or payware Pro version) is a very useful SQLite database manager.
An excellent eBook covering almost every aspect of SQLite3: a must-read for anyone doing serious work.
SQL tutorial (covers "generic" SQL, but most of it applies to SQLite as well)
A work-in-progress SQLite3 tutorial. Don't miss other LxyzTHW pages!
SQLite official website with full documentation (may be newer than the SQLite library that comes standard with AutoIt)

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

  • Similar Content

    • argumentum
      By argumentum
      I'd like to add tab Stops to a previously created listbox. Maybe use a GUICtrlSendMsg() or _SendMessage() but I don't know. Help 
      #include <GUIConstantsEx.au3> #include <GuiListBox.au3> #include <WinAPI.au3> Example() Func Example() Local $aTabs[4] = [3, 100, 200, 300], $idListBox ; Create GUI GUICreate("List Box Set Tab Stops", 400, 296) $idListBox = GUICtrlCreateList("", 2, 2, 396, 296) ;, BitOR($LBS_STANDARD, $LBS_USETABSTOPS)) GUISetState(@SW_SHOW) Local $Style = _WinAPI_GetWindowLong(GUICtrlGetHandle($idListBox), $GWL_STYLE) ;Capture Existing Style ;~ Local $ExStyle = _WinAPI_GetWindowLong(GUICtrlGetHandle($idListBox), $GWL_EXSTYLE) ;Capture Existing ExStyle ConsoleWrite("- before $Style = 0x" & Hex($Style) & @CRLF) ;~ ConsoleWrite("- before $ExStyle = 0x" & Hex($ExStyle) & @CRLF) GUICtrlSetStyle($idListBox, BitOR($Style, $LBS_USETABSTOPS)) ; change the Style $Style = _WinAPI_GetWindowLong(GUICtrlGetHandle($idListBox), $GWL_STYLE) ;~ $ExStyle = _WinAPI_GetWindowLong(GUICtrlGetHandle($idListBox), $GWL_EXSTYLE) ConsoleWrite("- after $Style = 0x" & Hex($Style) & @CRLF) ; updated style but is not reflected in it's behaviour ;~ ConsoleWrite("- after $ExStyle = 0x" & Hex($ExStyle) & @CRLF) ; Set tab stops _GUICtrlListBox_SetTabStops($idListBox, $aTabs) ; Add tabbed string _GUICtrlListBox_AddString($idListBox, "Column 1" & @TAB & "Column 2" & @TAB & "Column 3") ; Loop until the user exits. Do Until GUIGetMsg() = $GUI_EVENT_CLOSE GUIDelete() EndFunc ;==>Example  
    • mLipok
      By mLipok
      In documentation for:
       
      #include <FTPEx.au3> _FTP_Connect ( $hInternetSession, $sServerName, $sUsername, $sPassword [, $iPassive = 0 [, $iServerPort = 0 [, $iService = $INTERNET_SERVICE_FTP [, $iFlags = 0 [, $fuContext = 0]]]]] ) There are two parameters for Passive:
       
      My question is: 

      What is a difference beetwen  using :
      $iPassive = 1
      and
      $iFlags =     $INTERNET_FLAG_PASSIVE
      Regards,
      mLipok
       
    • FrancescoDiMuro
      By FrancescoDiMuro
      Good morning
      I was looking around the forum if there were some customizable solutions about creating a PDF from "0" to something like a report...
      What I'd like to do is something with a header ( 2 logos and a title ), with a table which contains data read from a file
      At the moment, I was working with HTML, since I know it and it's very simple to do a table with some data inside...
      But know, I'm a bit stuck about the exporting the HTML page to PDF... And, here too, if someone knows how to do it, please, I'm here listening
      Thanks guys
       
    • AndreyS
      By AndreyS
      Please tell me, who knows how to apply and cancel styles in RTF?
      The following code does not work:
      #include <GuiRichEdit.au3> #include <WindowsConstants.au3> $hGUI = GUICreate("RichEdit Style", 500, 500, -1, -1) $hRichEdit = _GUICtrlRichEdit_Create($hGui, "Test", 20,40,460,400) GUISetState(@SW_SHOW, $hGUI) Sleep(3000) GUICtrlSetStyle($hRichEdit, $ES_RIGHT) Sleep(3000) GUICtrlSetStyle($hRichEdit, -1) Sleep(3000) Thanks!
    • AndreyS
      By AndreyS
      Tell me, please, why in the application of different styles($SS_BLACKFRAME, $SS_BLACKRECT, etc.) of frames stops working function Msg().
      And why in the application of certain frame styles($SS_BLACKFRAME) do not even picture displayed?
      #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #include <StaticConstants.au3> Opt("GUIOnEventMode", 1) Example() Func Example() GUICreate("My GUI picture", 350, 300, -1, -1) ; will create a dialog box that when displayed is centered GUISetOnEvent($GUI_EVENT_CLOSE,"Quit") $idPic = GUICtrlCreatePic("D:\Program Files\AutoIt3\Examples\GUI\mslogo.jpg", 50, 50, 200, 50, $SS_SUNKEN) GUICtrlSetOnEvent(-1,"Msg") GUISetState(@SW_SHOW) ; Loop until the user exits. While 1 WEnd EndFunc ;==>Example Func Msg() MsgBox(0,0,0) EndFunc Func Quit() Exit EndFunc  
×