Sign in to follow this  
Followers 0
Akton

Column width with GUICtrlCreateListView ?

5 posts in this topic

Is there no way to set column width with GUICtrlCreateListView (short of having autoit3 move the mouse and click etc).

By adding spaces at the end of text only seems to work to 25 characters.

Share this post


Link to post
Share on other sites



You have to use the GuiListView UDF functions in order to do anything with a listview. Specifically, I believe _GUICtrlListView_SetColumnWidth() is what you are looking for.

Well I think that if you look at the function it just sends a message which you can do without loading the whole udf. If you use Koda to design your forms you will see that the column width is set by Koda just using a simple message.


Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script.

Share this post


Link to post
Share on other sites

You have to use the GuiListView UDF functions in order to do anything with a listview. Specifically, I believe _GUICtrlListView_SetColumnWidth() is what you are looking for.

Ah - I was just looking in the help file.

Thanks, I'll try and see if i can find that.

Share this post


Link to post
Share on other sites

Of course, a lot of the UDFs do nothing more than make DLL Calls that you could do yourself. You can extract the relevant DLL Calls from the UDFs, if you know what you are doing and are willing to take the time to do it.

Well i don't know what I'm doing - and I'm not sure I have time to be a full fledged programmer (not even sure what udfs are).

Is it a problem that i have used the inbuilt functions documented in the manual?

For instance GUICtrlCreateListView returns a control pointer, but you apparently need a window pointer to set the width?

Calling _GUICtrlListView_SetColumnWidth has no effect.

Share this post


Link to post
Share on other sites

No, it should still work fine. I just did something similar a few days ago. Make sure your syntax is correct, and that you've included GuiListView.au3.

Must be because I didn't have a GUISetState() call.

Seems to be working now.

Thanks.

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