qwertylol Posted May 20, 2007 Share Posted May 20, 2007 Dim $green = 10 Dim $red = 20 Dim $blue = 10 If $green > $red & $green > $blue Then ;MsgBox ( 0, "$loop_point", $loop_point ) ;$degree = IniRead ( "radar_loc.ini", "degree", 'rim_point_' & $loop_point, "default" ) MsgBox ( 0, "before return" , "green" ) ;Return ; EndIf I need multiple condition to be true, but I guess I messed up. Please correct me Link to comment Share on other sites More sharing options...
Uriziel01 Posted May 20, 2007 Share Posted May 20, 2007 just use logical AND for multiple, OR for one of few. ex. If $green > $red & $green AND $red & $green > $blue Then... Link to comment Share on other sites More sharing options...
qwertylol Posted May 20, 2007 Author Share Posted May 20, 2007 just use logical AND for multiple, OR for one of few. ex. If $green > $red & $green AND $red & $green > $blue Then...uh, could you clarify?is that au3 you are posting? Link to comment Share on other sites More sharing options...
qwertylol Posted May 20, 2007 Author Share Posted May 20, 2007 your quite amazing, having joined 50minutes ago. Link to comment Share on other sites More sharing options...
Uriziel01 Posted May 20, 2007 Share Posted May 20, 2007 (edited) I'm writing in Autoit for long time (2 months is long i think), i just have'nt acc on this board... and, yes this is the au3 script and it will be working, for ex. Dim $jeden=4 Dim $dwa=3 Dim $trzy=6 if $jeden > $dwa AND $jeden > $trzy then Msgbox(0,"","jeden is the biggest value") endif if $jeden > $dwa AND $jeden < $trzy then Msgbox(0,"","trzy is the biggest value") endif if $jeden < $dwa AND $jeden > $trzy then Msgbox(0,"","dwa is the biggest value") endif p.s-yes, yes i now that the dim's prefix arent nesseseary... Edited May 20, 2007 by Uriziel01 Link to comment Share on other sites More sharing options...
Zedna Posted May 20, 2007 Share Posted May 20, 2007 uh, could you clarify?is that au3 you are posting?Did ypu open Autoit Helpfile?I highly recommend it to you. Resources UDF Â ResourcesEx UDF Â AutoIt Forum Search Link to comment Share on other sites More sharing options...
Uriziel01 Posted May 20, 2007 Share Posted May 20, 2007 Yeap, Autoit help is the best "source" of knowledge and code. Link to comment Share on other sites More sharing options...
Vindicator209 Posted May 21, 2007 Share Posted May 21, 2007 If $green > $red Then If $green > $blue Then ;MsgBox ( 0, "$loop_point", $loop_point ) ;$degree = IniRead ( "radar_loc.ini", "degree", 'rim_point_' & $loop_point, "default" ) MsgBox ( 0, "before return" , "green" ) ;Return EndIf EndIf Put the second inside the other one =P [center]"When you look at old, classic games like Snake, you often put it off because it's such a simple game, but it's only when you actually try and create your own unique game from scratch, do you finally appreciate those games."[/center][center]Don't ask for answers if you haven't TRIED yet![/center][center]Most answers can be answered in the help file! Use it![/center] Link to comment Share on other sites More sharing options...
The Kandie Man Posted May 21, 2007 Share Posted May 21, 2007 Yeap, Autoit help is the best "source" of knowledge and code.I can't tell you how true that statement is. If you have a question spend a while looking through the help file. Even if you don't find what you are looking for right away you will end up finding new ways to do things and in some cases you will even find ways to solve other problems that you have.It is important that you(anybody who is reading this post) don't use the forum every time you have the smallest problem because then other people get irritated with you and stop looking at your posts and threads.Use the forum as a last resort when there is no other way.That is just my $0.02 as we like to say.- The Kandie Man ;-) "So man has sown the wind and reaped the world. Perhaps in the next few hours there will no remembrance of the past and no hope for the future that might have been." & _"All the works of man will be consumed in the great fire after which he was created." & _"And if there is a future for man, insensitive as he is, proud and defiant in his pursuit of power, let him resolve to live it lovingly, for he knows well how to do so." & _"Then he may say once more, 'Truly the light is sweet, and what a pleasant thing it is for the eyes to see the sun.'" - The Day the Earth Caught Fire Link to comment Share on other sites More sharing options...
Gif Posted May 21, 2007 Share Posted May 21, 2007 Yeap, Autoit help is the best "source" of knowledge and code.yeap agreed, also Au3Lib and functions page here pretty same the help file Link to comment Share on other sites More sharing options...
nfwu Posted May 21, 2007 Share Posted May 21, 2007 (edited) Dim $green = 10 Dim $red = 20 Dim $blue = 10 If $green > $red AND $green > $blue Then ;MsgBox ( 0, "$loop_point", $loop_point ) ;$degree = IniRead ( "radar_loc.ini", "degree", 'rim_point_' & $loop_point, "default" ) MsgBox ( 0, "before return" , "green" ) ;Return ; EndIf AutoIt uses different logical operators from other languages: Logical Operators: && => And || => Or ! => Not Binary Operators: & => BitAnd(a, b) | => BitOr(a, b) #) Edited May 21, 2007 by nfwu TwitterOut of date stuff:Scripts: Sudoku Solver | Webserver | 3D library (Pure AutoIt) | Wood's GadgetsUDFs: _WoodUniqueID() | _DialogEditIni() | _Console*() | _GetIPConfigData() | _URLEncode/Decode() 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