Results 1 to 8 of 8

Thread: Creating form?

  1. #1
    Join Date
    Mar 2013
    Location
    0100111001001100
    Posts
    56
    Mentioned
    1 Post(s)
    Quoted
    9 Post(s)

    Default Creating form?

    Hey Villavu, i'm trying to add an Form for my woodcutting script, but when its starts its just terminate the script?

    Could anyone take look at it Thanks

    @ file is in the attachment.

    - Maikel233.
    Attached Files Attached Files

  2. #2
    Join Date
    Apr 2012
    Location
    Canada, Bc
    Posts
    1,593
    Mentioned
    6 Post(s)
    Quoted
    356 Post(s)

    Default

    It would be better to post it in Code tags

    [code] Here [ / code]<without spaces

  3. #3
    Join Date
    Nov 2011
    Location
    England
    Posts
    3,072
    Mentioned
    296 Post(s)
    Quoted
    1094 Post(s)

    Default

    you can't have two "main begins and ends"

    Simba Code:
    begin
      SafeInitForm;        // those 2 function are the action form setup. Thise one creates your form
      SafeShowFormModal;  // and this one makes it visible
    end.

    will call that and nothing else.

    why not do

    Simba Code:
    procedure showForm();
    begin
      SafeInitForm;        // those 2 function are the action form setup. Thise one creates your form
      SafeShowFormModal;  // and this one makes it visible
    end;

  4. #4
    Join Date
    Mar 2013
    Location
    0100111001001100
    Posts
    56
    Mentioned
    1 Post(s)
    Quoted
    9 Post(s)

    Default

    Quote Originally Posted by Ollybest View Post
    you can't have two "main begins and ends"

    Simba Code:
    begin
      SafeInitForm;        // those 2 function are the action form setup. Thise one creates your form
      SafeShowFormModal;  // and this one makes it visible
    end.

    will call that and nothing else.

    why not do

    Simba Code:
    procedure showForm();
    begin
      SafeInitForm;        // those 2 function are the action form setup. Thise one creates your form
      SafeShowFormModal;  // and this one makes it visible
    end;
    Thanks for the reply but it still gives an error, Sucks that simba cant say line: .... is the problem...

  5. #5
    Join Date
    Sep 2012
    Location
    Australia.
    Posts
    839
    Mentioned
    16 Post(s)
    Quoted
    225 Post(s)

    Default

    Quote Originally Posted by maikel233 View Post
    Thanks for the reply but it still gives an error, Sucks that simba cant say line: .... is the problem...
    Don't just tell us you got an error! Tell us what it was!

    After creating the procedure Olly showed you, did you then call it in your mainloop?

  6. #6
    Join Date
    Mar 2013
    Location
    0100111001001100
    Posts
    56
    Mentioned
    1 Post(s)
    Quoted
    9 Post(s)

    Default

    Quote Originally Posted by Chris! View Post
    Don't just tell us you got an error! Tell us what it was!

    After creating the procedure Olly showed you, did you then call it in your mainloop?
    Yes of course: Simba says that the player info is incorrect now.

    Procedure DeclarePlayers;
    begin
    HowManyPlayers := 1;
    NumberOfPlayers(1);
    CurrentPlayer := 0;

    // PLAYER INFO, TIP Your RS Username, Password, Pin IS NOT REQUIRED SIMPLY DISABLE SMART when Runescape Loads.
    // Wielding_Axe:= False;
    wielding_axe :=Checkbox1.checked;
    Players[0].Name :=Edits[0].text;
    Players[0].Pass :=Edits[1].text;
    Players[0].Nick :=Edits[2].text;
    Players[0].Pin :=Edits[3].text;
    Players[0].Active:=True;
    Players[0].LampSkill:= skill_woodcutting;


    SetScreenName(Players[0].Nick);
    end;

  7. #7
    Join Date
    Sep 2012
    Location
    Australia.
    Posts
    839
    Mentioned
    16 Post(s)
    Quoted
    225 Post(s)

    Default

    If you're getting the "Identifier Expected" error, then at lines 141->143 you have close your procedure using end;!

    Remember, whenever you have a begin, it must have an end;!

    So just add three end;'s on lines 141, 142 and 143 and it compiles for me.

  8. #8
    Join Date
    Mar 2013
    Location
    0100111001001100
    Posts
    56
    Mentioned
    1 Post(s)
    Quoted
    9 Post(s)

    Default

    Quote Originally Posted by Chris! View Post
    If you're getting the "Identifier Expected" error, then at lines 141->143 you have close your procedure using end;!

    Remember, whenever you have a begin, it must have an end;!

    So just add three end;'s on lines 141, 142 and 143 and it compiles for me.
    So i redownloaded this script for my laptop, Added three ends and works fine... Thanks Criss, Ollybest!!!!!

Thread Information

Users Browsing this Thread

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

Posting Permissions

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