Results 1 to 9 of 9

Thread: Need Scar Help!

  1. #1
    Join Date
    Oct 2007
    Posts
    28
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default Need Scar Help!

    Hi. I am making a scar program that DOES include SRL. It always comes up at the end with, "Identifier Expected". Can anyone help? I am still open to answers because the other people's input didn't work.

    SCAR Code:
    program NextAutoClicker;
    {.include SRL/SRL.scar}

    var
    x: integer;

    procedure TypeSendNow;
    begin
     repeat
     x:=2;
      if (x=2) then
      begin
      TypeSend('cyan: are you okay?'+chr(13));
      Wait(4000);
      if (x=3) then
      begin
      TypeSend('blue: good day world'+chr(13));
      Wait(4000);
      if (x=5) then
      begin
      TypeSend('purple: hi world'+chr(13));
      Wait(4000);
      end else
      TypeSend('hi'+chr(13));
      wait(4000);
      end;
     
      begin
      SetUpSRL;
      repeat
      TypeSendNow;
      until(false);
     end;
    end.

    Thanks,
    Camdo Clark

  2. #2
    Join Date
    Apr 2007
    Location
    The Netherlands
    Posts
    5,553
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    you need more end in your procedure typesend the number of begins is always teh same as ends

    -_- 4 begins.... 2 ends....

  3. #3
    Join Date
    Feb 2007
    Location
    Access Violation at 0x00000000
    Posts
    2,865
    Mentioned
    3 Post(s)
    Quoted
    18 Post(s)

    Default

    That will be:

    SCAR Code:
    program NextAutoClicker;
    {.include SRL/SRL.scar}
     
    var
    x: integer;
     
    procedure TypeSendNow;
    begin
     repeat
     x:=2;
      if (x=2) then
      begin
      TypeSend('cyan: are you okay?'+chr(13));
      Wait(4000);
      if (x=3) then
      begin
      TypeSend('blue: good day world'+chr(13));
      Wait(4000);
      if (x=5) then
      begin
      TypeSend('purple: hi world'+chr(13));
      Wait(4000);
      end else
      TypeSend('hi'+chr(13));
      wait(4000);
      end;
      end;
      end;
     
      begin
      SetUpSRL;
      repeat
      TypeSendNow;
      until(false);
    end.
    Ce ne sont que des gueux


  4. #4
    Join Date
    Oct 2007
    Posts
    28
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Thanks everyone, I'll try this out now.
    Thanks, but it didn't work. I'm really not sure why.

    Thanks for all the input,
    Camdo Clark

  5. #5
    Join Date
    Mar 2007
    Posts
    3,042
    Mentioned
    1 Post(s)
    Quoted
    14 Post(s)

    Default

    Both of them forgot to mention that you need an until in your procedure as well. Put it before the last end.
    :-)

  6. #6
    Join Date
    Apr 2007
    Location
    The Netherlands
    Posts
    5,553
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    here
    SCAR Code:
    program NextAutoClicker;
    {.include SRL/SRL.scar}

    var
      x: integer;

    procedure TypeSendNow;
    begin
     repeat
      x:=2;
      if (x=2) then
      begin
        TypeSend('cyan: are you okay?'+chr(13));
        Wait(4000);
        if (x=3) then
        begin
          TypeSend('blue: good day world'+chr(13));
          Wait(4000);
          if (x=5) then
          begin
            TypeSend('purple: hi world'+chr(13));
            Wait(4000);
          end else
            TypeSend('hi'+chr(13));
            wait(4000);
        end;
      end;
     until(False);
    end;

    begin
      SetUpSRL;
      TypeSendNow;
    end.

    remember there must be in a procedure or what ever always, even much begins as ends, okay?and if there 1 repeat always an 1until and there equal whith eachother

  7. #7
    Join Date
    Oct 2007
    Posts
    28
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Line 28: [Error] (14709:1): Identifier expected in script C:\Documents and Settings\camden\My Documents\Next Talker.scar

    SCAR Code:
    program NextAutoClicker;
    {.include SRL/SRL.scar}

    var
    x: integer;

    procedure TypeSendNow;
    begin
     repeat
     x:=2;
      if (x=2) then
      begin
      TypeSend('cyan: are you okay?'+chr(13));
      Wait(4000);
      if (x=3) then
      begin
      TypeSend('blue: good day world'+chr(13));
      Wait(4000);
      if (x=5) then
      begin
      TypeSend('purple: hi world'+chr(13));
      Wait(4000);
      end else
      TypeSend('hi'+chr(13));
      wait(4000);
      end;
      end;  
      end;
     
      begin
      SetUpSRL;
      repeat
      TypeSendNow;
      until(false);
    end.

  8. #8
    Join Date
    Oct 2007
    Posts
    28
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Thanks to all of you, my program now works! Thanks!

  9. #9
    Join Date
    Apr 2007
    Location
    The Netherlands
    Posts
    5,553
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    np, read my above post then you know what was the bug

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 15
    Last Post: 09-22-2008, 12:32 PM
  2. SCAR Divi 3.01 DONT associate .scar files!!!
    By chimpy in forum News and General
    Replies: 1
    Last Post: 04-21-2007, 08:49 PM
  3. Replies: 28
    Last Post: 06-22-2006, 04:27 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •