Achilles Posted July 30, 2006 Share Posted July 30, 2006 I've looked through GuiSetState for these but I haven't had any luck. It looks like you can only chose one style and one advanced style. Am I wrong? Thanks, Piano_Man My Programs[list][*]Knight Media Player[*]Multiple Desktops[*]Daily Comics[*]Journal[/list] Link to comment Share on other sites More sharing options...
Vivvic Posted July 30, 2006 Share Posted July 30, 2006 Never played around with it before, but maby, @SW_DISABLE [quote name='DaleHohm']You have a strange habit of posting error messages that don't match your code.[/quote][quote name='SmOke_N']Forget the learning... straight to the scripting :lol: (laugh.gif)[/quote] Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted July 30, 2006 Moderators Share Posted July 30, 2006 (edited) You really need to look at GUICtrlSetState() for centering and such, everything else is done by hand in the GUI itself. Also look at the $ES_READONLY style and $SS_CENTER / $ES_CENTER in the GUI Control Styles that I've told you look at before . Edited July 30, 2006 by SmOke_N Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
Achilles Posted July 30, 2006 Author Share Posted July 30, 2006 You really need to look at GUICtrlSetState() for centering and such, everything else is done by hand in the GUI itself. Also look at the $ES_READONLY style and $SS_CENTER / $ES_CENTER in the GUI Control Styles that I've told you look at before .Sorry I worded that wrong. It's not GuiSetState I want to look at, I want to apply it to a editbox. I've already used the $ss_center and the $es_readonly for other boxes. However the box that has $es_readonly doesn't look good because the text is directly in the top left of the Editbox. That's why I was wondering if there's a way to combine them. Thanks, Piano_Man My Programs[list][*]Knight Media Player[*]Multiple Desktops[*]Daily Comics[*]Journal[/list] Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted July 30, 2006 Moderators Share Posted July 30, 2006 BitOr($ES_READONLY, $ES_CENTER) Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
Achilles Posted July 30, 2006 Author Share Posted July 30, 2006 (edited) BitOr($ES_READONLY, $ES_CENTER) Hmm, well sorry but that doesn't help me. I haven't used and Bit stuff yet... If you would like to show me here's the script that's relevant... I want the one edit box that I have to be centered/read only. #include <GUIConstants.au3> GUICreate(" Photo Resizing", 460, 160, -1, -1, $WS_CAPTION, $WS_EX_TOOLWINDOW) GUISetBkColor (0xA29CFE) $Foldername = "C:\Documents and Settings\test\My Documents\My Pictures\Resizing" GuiCtrlCreateLabel("Insert how many pictures you want resized and then insert the percentage of the new picture compared to the old picture. You can also chose which folder the program gets pictures from.", 10, 5, 445, 30 ) $exit = GuiCtrlCreateButton("Exit", 235, 110, 90, 30) GuiCtrlCreateButton("OK", 350, 110, 90, 30) GUICtrlCreateEdit($Foldername, 10, 45, 405, 15, $ES_Readonly,$WS_EX_STATICEDGE) ;this is where I want to add in the $es_center. GUISetState(@SW_Show) While 1 $msg = GuiGetMSg() Select Case $msg = $exit Exit Endselect Wend Thanks, Piano_Man Edited July 30, 2006 by Piano_Man My Programs[list][*]Knight Media Player[*]Multiple Desktops[*]Daily Comics[*]Journal[/list] Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted July 30, 2006 Moderators Share Posted July 30, 2006 (edited) Hmm, well sorry but that doesn't help me. I haven't used and Bit stuff yet... If you would like to show me here's the script that's relevant... I want the one edit box that I have to be centered/read only.Sometimes you have to help yourself... You asked how do you combine the two, I showed how to do that, and you made NO effort to even put it in there. Blah... just put what I gave you where you have $ES_READONLY at now!! Edit: #include <GUIConstants.au3> GUICreate(" Photo Resizing", 460, 160, -1, -1, $WS_CAPTION, $WS_EX_TOOLWINDOW) GUISetBkColor (0xA29CFE) $Foldername = "C:\Documents and Settings\test\My Documents\My Pictures\Resizing" GuiCtrlCreateLabel("Insert how many pictures you want resized and then insert the percentage of the new picture compared to the old picture. You can also chose which folder the program gets pictures from.", 10, 5, 445, 30 ) $exit = GuiCtrlCreateButton("Exit", 235, 110, 90, 30) GuiCtrlCreateButton("OK", 350, 110, 90, 30) GUICtrlCreateEdit($Foldername, 10, 45, 405, 15, BitOr($ES_READONLY, $ES_CENTER),$WS_EX_STATICEDGE) ;this is where I want to add in the $es_center. GUISetState(@SW_Show) While 1 $msg = GuiGetMSg() Select Case $msg = $exit Exit Endselect WendI shouldn't assume anyone has the common sense to take the appropriate actions on a question they asked specifically so I gave you the example. Edited July 30, 2006 by SmOke_N Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
Achilles Posted July 30, 2006 Author Share Posted July 30, 2006 Blah... just put what I gave you where you have $ES_READONLY at now!! Sweet, sorry it took me so long...Thanks a ton,Piano_Man My Programs[list][*]Knight Media Player[*]Multiple Desktops[*]Daily Comics[*]Journal[/list] Link to comment Share on other sites More sharing options...
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