To explain some things, script was working perfectly by just making the mouse move to certain places and click, but even though it is harder and useless, for the sake of getting more advanced I decided to start off and try to replace the coordinates with searches for the bitmaps username and password. Did it, followed the stickied FAQ for it and made everything black except the word username and cropped it. Now I just replaced one of the Mouse functions to click username with the serch for the bitmap and I'm getting this error. I have no idea what the error means so any help appreciated.
Line 17: [Error] (14698:50): Type mismatch in script C:\Program Files\SCAR 3.12\Scripts\First try.scar
Failed when compiling
Code://First program program Afirstidea; {.include SRL/SRL.scar} var Username,Password,BitUsername,BitPassword: String; //-------------------------------------- procedure Setup;//Sets up the Integers begin Username:= ''; Password:= ''; end; //-------------------------------------- procedure Bitmapsetup;//Creates codes for Bitmaps begin BitUsername := BitmapFromString(55, 10, 'beNpjYBgq4P///1jZo' + '44c4Y6EyKKph3PhbGIMJF4lfkf+hwFMNyALYjoYUxemFjxGYXUtfu' + '+gWY1sLJGOxMrA4x2C8Y7Vkfi9QEVHMowCmgIAZnjyDg=='); BitPassword := BitmapFromString(53, 8, 'beNpjYPgPAwyDAGA6A+' + '62weBC/M4bcBficR5+ZUQaDteIxiZoKa4YxOU8zDRJUISg83A5mCS' + 'PEFSPP3lgem3AnYdfI0FD8Fg3qAEA343jHQ=='); //-------------------------------------- procedure Login;//Moving the Mouse var Ux,Uy,Px,Py: Integer; begin FindRS Mouse( -6,130,0,0,true) wait(300) Mouse( 464,294,0,0,true) wait(300) FindBitmapToleranceIn(BitUsername,Ux,Uy,271,254,345,365,25); Mouse(Ux,Uy,0,0,true) wait(100) SendKeysWait(Username,90,20) wait(1000) Mouse( 362,276,0,0,true) wait(1000) SendKeysWait(Password,90,20) end; //-------------------------------------- begin//Makes the Procedures do their job SetupSRL Bitmapsetup Setup Login end.


Reply With Quote


