Problem with comand:else

Discussion in 'Scar/Simba Help' started by hunter3325, Feb 2, 2008.

Problem with comand:else
  1. Unread #1 - Feb 2, 2008 at 10:04 AM
  2. hunter3325
    Referrals:
    0

    hunter3325 Guest

    Problem with comand:else

    hi..

    i have noticed that 'else' isnt working..

    here is my script:

    1 program New;
    2 begin
    3 if getcolor(561,51) = 10841658 then
    4 MoveMouse(961,26)
    5 ClickMouse(961,26,false)
    6 else
    7 Writeln('didnt find the color')
    8 end.


    and heres the error:
    Failed when compiling
    Line 6: [Error] (6:1): Identifier expected in script


    can any1 help me please? i dont got any idea whats wrong with it.. have i done something wrong? :confused:
     
  3. Unread #2 - Feb 2, 2008 at 10:54 AM
  4. hunter3325
    Referrals:
    0

    hunter3325 Guest

    Problem with comand:else

    i did some exchanges in the script:

    program New;
    begin
    if getcolor(561,51) = 10841658 then
    begin
    MoveMouse(961,26)
    ClickMouse(961,26,false)
    end; else
    begin
    Writeln('didnt find the color')
    end;
    end.


    but now aggain there is an error:

    Failed when compiling
    Line 7: [Error] (7:6): Identifier expected in script


    :eek: :eek: :eek: :eek: :( :confused: :confused:


    Sorry for double post..
     
  5. Unread #3 - Feb 2, 2008 at 7:14 PM
  6. Town
    Joined:
    Jan 21, 2007
    Posts:
    3,776
    Referrals:
    3
    Sythe Gold:
    5

    Town Grand Master
    Scar Programmers

    Problem with comand:else

    Take away the semi-colon after end.
     
< Collaberating with lag.. | Adding onto a script. >

Users viewing this thread
1 guest


 
 
Adblock breaks this site