Jump to content

Error : "subscript used on non-accessible variable" when use _ImageSearch

Recommended Posts


Hi everybody , this is my code


#include <MsgBoxConstants.au3>
#include <String.au3>
#include <Array.au3>
#include <Excel.au3>
#include <FileConstants.au3>
#include <GUIConstantsEx.au3>
#include <File.au3>
#include <IE.au3>
#include <Inet.au3>
#include <FTPEx.au3>
#include <Misc.au3>
#include <StringConstants.au3>
#include <Date.au3>
#include <ImageSearch.au3>
#include <WinAPIProc.au3>
#include <Constants.au3>

   While 1
      $x_IMG1 = 0
      $y_IMG1 = 0
      $x_IMG2 = 0
      $y_IMG2 = 0

      Local $search1 = _ImageSearch('LGL-Logo.png', 0, $x_IMG1, $y_IMG1, 0)

      if($search1 = 1) then
         MsgBox($MB_SYSTEMMODAL, 'ERROR - 34', "ERROR - 34"&"_")



This code is still work if I use SciTE.exe to run .

And when I use Aut2exe_x64.exe to Destination (.Exe) file, this code dont work and we have error "subscript used on non-accessible variable".

How to fix this ? 







Edited by kctvt
update code
Link to post
Share on other sites

Error line


You can debug from that line but in my head question is can included au3 file call his dll as x64 compiled...

Edited by bogQ

TCP server and client - Learning about TCP servers and clients connection
Au3 oIrrlicht - Irrlicht project
Au3impact - Another 3D DLL game engine for autoit. (3impact 3Drad related)

There are those that believe that the perfect heist lies in the preparation.
Some say that it’s all in the timing, seizing the right opportunity. Others even say it’s the ability to leave no trace behind, be a ghost.

Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...