Didonet Posted November 15, 2007 Share Posted November 15, 2007 How can i create a edit area with transperent background and when in it there is the code <b>text</b>oÝ÷ ÚÚ,"¶X¤y»^ÆßÛ.)®'!µìmyØ¢´áȬ'Ö«y§è®z0jëh×6$text = GUICtrlCreateEdit("", 35, 20, 280, 70, $ES_WANTRETURN, $WS_EX_TRANSPARENT ) It didn't have border and scrolls, but it still have background color. Is it possible to create the rich editor? Link to comment Share on other sites More sharing options...
_Kurt Posted November 16, 2007 Share Posted November 16, 2007 (edited) Global $Obj = ObjCreate("RICHTEXT.RichTextCtrl") Local $x = 0, $y = 0, $w = 300, $h = 300 GUICreate("test") $GUIActiveX = GUICtrlCreateObj($Obj, $x, $y) GUICtrlSetPos(-1, $x, $y, $w, $h) ;<== REQUIRED, MUST USE THIS!!! With $Obj .OLEObjects () .OLEDrag () .OLEDropMode = 2 .ScrollBars () .MultiLine () .SelStart = 0 .SelFontName = "Arial" .SelFontSize = 9 .HideSelection = False .BackColor = 0xFFFFFF EndWith GUISetState() While 1 Sleep(50) WEnd GUICtrlSetPos must be used or else the width and height of the object won't be correct (weird bug). Kurt Edited November 16, 2007 by _Kurt Awaiting Diablo III.. Link to comment Share on other sites More sharing options...
Didonet Posted November 16, 2007 Author Share Posted November 16, 2007 Thanks for the script... but it didn't work... I'm with Windows Vista and i'm seeing nothing.I think the Vista is the problem...And another problem:C:\Program Files\AutoIt3\Examples\rich.text.au3(11,12) : WARNING: $Notes: possibly used before declaration.With $Notes~~~~~~~~~~~^C:\Program Files\AutoIt3\Examples\rich.text.au3(11,12) : ERROR: $Notes: undeclared global variable.With $NotesI tried and that script but nothing happens...http://www.autoitscript.com/forum/index.php?showtopic=45077 Link to comment Share on other sites More sharing options...
_Kurt Posted November 16, 2007 Share Posted November 16, 2007 Sorry about that, forgot to switch $Notes to $Obj, copy/paste the code from my previous post and try that again, it should work this time.. Kurt Awaiting Diablo III.. Link to comment Share on other sites More sharing options...
goldenix Posted November 16, 2007 Share Posted November 16, 2007 And another problem: WARNING: $Notes: possibly used before declaration.if $Notes is declared in a function & you try to use it in anywhere else, exept the function where it is declared or on the line above you have declared it in current function, you get this error because autoit reads a functions only if certain conditions are met, like you press a button/hotkey/or put _finction() somewhere.But if you want to use the declared $Notes value somewhere else, you need to make $Notes a global value. So simply put global $Notes on the first line of your script My Projects:[list][*]Guide - ytube step by step tut for reading memory with autoitscript + samples[*]WinHide - tool to show hide windows, Skinned With GDI+[*]Virtualdub batch job list maker - Batch Process all files with same settings[*]Exp calc - Exp calculator for online games[*]Automated Microsoft SQL Server 2000 installer[*]Image sorter helper for IrfanView - 1 click opens img & move ur mouse to close opened img[/list] Link to comment Share on other sites More sharing options...
Didonet Posted November 16, 2007 Author Share Posted November 16, 2007 and... how to see the rich editor? I can't see it... vista... Link to comment Share on other sites More sharing options...
Didonet Posted November 17, 2007 Author Share Posted November 17, 2007 up Link to comment Share on other sites More sharing options...
_Kurt Posted November 17, 2007 Share Posted November 17, 2007 If this doesn't work in Vista then I do not know any other solutions, try it again.. Global $Obj = ObjCreate("RICHTEXT.RichTextCtrl") Local $x = 0, $y = 0, $w = 300, $h = 300 GUICreate("test") $GUIActiveX = GUICtrlCreateObj($Obj, $x, $y) GUICtrlSetPos(-1, $x, $y, $w, $h) ;<== REQUIRED, MUST USE THIS!!! With $Obj .OLEObjects () .OLEDrag () .OLEDropMode = 2 .ScrollBars () .MultiLine () .SelStart = 0 .SelFontName = "Arial" .SelFontSize = 9 .HideSelection = False .BackColor = 0xFFFFFF EndWith GUISetState() While 1 Sleep(50) WEnd Kurt Awaiting Diablo III.. Link to comment Share on other sites More sharing options...
Didonet Posted November 17, 2007 Author Share Posted November 17, 2007 >Running:(3.2.8.1):C:\Program Files\AutoIt3\autoit3.exe "C:\Program Files\AutoIt3\Examples\rich.text.test.au3" C:\Program Files\AutoIt3\Examples\rich.text.test.au3 (6) : ==> Only Object-type variables allowed in an "With" statement.: With $Obj With ^ ERROR ->22:50:56 AutoIT3.exe ended.rc:1 +>22:50:57 AutoIt3Wrapper Finished >Exit code: 1 Time: 2.550 Link to comment Share on other sites More sharing options...
Ranmaru Posted December 14, 2007 Share Posted December 14, 2007 >Running:(3.2.8.1):C:\Program Files\AutoIt3\autoit3.exe "C:\Program Files\AutoIt3\Examples\rich.text.test.au3" C:\Program Files\AutoIt3\Examples\rich.text.test.au3 (6) : ==> Only Object-type variables allowed in an "With" statement.: With $Obj With ^ ERROR->22:50:56 AutoIT3.exe ended.rc:1+>22:50:57 AutoIt3Wrapper Finished>Exit code: 1 Time: 2.550>"C:\Program Files\AutoIt3\SciTE\AutoIt3Wrapper\AutoIt3Wrapper.exe" /run /prod /ErrorStdOut /in "C:\Users\Ran\Desktop\richbox.au3" /autoit3dir "C:\Program Files\AutoIt3" /UserParams +>02:04:59 Starting AutoIt3Wrapper v.1.9.4>Running AU3Check (1.54.9.0) from:C:\Program Files\AutoIt3+>02:04:59 AU3Check ended.rc:0>Running:(3.2.9.3):C:\Program Files\AutoIt3\autoit3.exe "C:\Users\Ran\Desktop\richbox.au3" C:\Users\Ran\Desktop\richbox.au3 (6) : ==> Only Object-type variables allowed in an "With" statement.: With $Obj With ^ ERROR->02:04:59 AutoIT3.exe ended.rc:1+>02:05:00 AutoIt3Wrapper Finished>Exit code: 1 Time: 1.566I'm also running on Vista and I get this too and I really need this..Anyone found a solution to this? Link to comment Share on other sites More sharing options...
_Kurt Posted December 14, 2007 Share Posted December 14, 2007 Are you sure you have RichText installed on your computer? It should come with MS Word I think. Try downloading this from the microsoft website, maybe this will fix it:http://www.microsoft.com/downloads/details...;displaylang=enKurt Awaiting Diablo III.. 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