Jump to content
Daka

when compile and move that .exe file to other map ERROR

Recommended Posts

Daka

Hello there,

 

When I compile script and use it out of the map where 
the source code is. So just moving main.exe to
other map, then source code is.
It breaks with error:
Line10010
Error: Subscript used on non-accessible variable

So I wonder what kind of file do I need to 
include with .exe file? Or should I do something else?

Because people that are using needs only .exe file
just start it and use it, with out source code.

 

Share this post


Link to post
Share on other sites
Daka

O I tested with compile script to exe (x64)
and I unchecked compile to x64

then I compile it

and if it is in that map where the code is 
it works perfect as much as I move it to other map
it breaks.

You ae saying got to source code and see what is going on.
How? It all works fine.

Only thing how to debug it would be to find out what kind of 
linecode at that .exe file is? But how to do that?
How to see exactly what line of code is not working at .exe file?

Share this post


Link to post
Share on other sites
Daka

ok I figure it out it needs the .dll files in my case it was md5_hash.dll and md5_hash.bas file.
If I take these files to new map it works fine :)

Share this post


Link to post
Share on other sites
Jos

What I am trying to tell yyou is to run the script with SciTE interactively as that will give you the exact information on this issue.
Are you using the Full Scite4AutoIt3 installation? 
Have you checked your script with au3check, which is automatically when you have this installed?

Anyway, try replicating the issue when running it from SciTE for better information.

Jos 


SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource        Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites
Daka

Ok I was just testing script on windows 10 and it gives me troubles.

Jos you said: "What I am trying to tell you is to run the script with SciTE interactively as that will give you the exact information on this issue."

So my question is:
can you see from .exe script some information, like debugging? can it be done with SciTE interactively?

Other question:
I was debugging with teamviewer with client on his windows 10 with only .exe file.
and it didn't work well!

So only thing I was able to do is to get v3 window info and check why it doesn't work!

So now the problem is, I have no idea, what program is doing!

Here is the solution that maybe could work:
To have another window that will open if I click to see debugging of my code.
then I can say, what exactly code is doing and then that print out in debugging window.

But is there some debugger from autoit like you said "SciTE interactively"
is SciTE what I need here? to can debug on .exe and see what the problem may be?

Share this post


Link to post
Share on other sites
Jos

There is no Debugger as such, but one could always have a debug option by checking for a INI value or exe parameter and then do detailed logging to a LOG file. This is quite common practice for Compiled programs.

When you can replicate the issue locally, you could indeed do some interactive debugging by using the standard available:

#AutoIt3Wrapper_Run_Debug_Mode=                 ;(Y/N) Run Script with console debugging. Default=N

This will trigger detailed steps about the program steps taken in the SciTE Outputpane. It could be that this is way too much information. In that case you can add your own ConsoleWrite statements by going into the source and hitting Ctrl+D on the Var or Func you want to have debug information displayed in t he outputpane.

These lines can be easily commented/removed by using the available options under tools. 
This all is only available in the Full version of SciTE4AutoIt3!

Jos


SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource        Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


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

  • Similar Content

    • Dreamfire
      By Dreamfire
      Hi,
      Since today, exe's are being flagged as having a trojan by Windows Defender (Fuery.B!cl)
      Version:  3.3.14.3 - SciTE Version 3.7.3



       

    • drapdv
      By drapdv
      So, I have this odd issue happening with UIAWrappers.  When I run simplespy.au3 through SciTE, it finds the object I'm trying to work with, no problem. But, when I compile simplespy.exe, it can't find it.  Another script that utilizes UIAWrappers is experiencing the same phenomenon. EDIT: Compiling as 32-bit or 64-bit does not affect this behavior.
      The trouble starts at the very first object I try to get via _UIA_getObjectByFindAll, so I included the $properties2Match array and the object properties that were returned by _UIA_getPropertyValue for that first object both when running from SciTE and when compiled.
      It always finds the matches for the title and control type properties.  But when compiled, it fails to find the Automation ID property.  Any ideas as to why this would be happening?  Hoping junkew will see this and have an idea.
       
      These are the $properties2Match
      30005|Screen/PVN - ###.###.##.## - CDK Drive|0|False
      30003|50032|0|False
      30011|Portal|0|False
       
      Object properties when running from SciTE:
      <propertymatching>       
              j:1 propID:[30005] expValue:[Screen/PVN - ###.###.##.## - CDK Drive]actualValue:[Screen/PVN - ###.###.##.## - CDK Drive]1
              j:2 propID:[30003] expValue:[50032]actualValue:[50032]1
              j:3 propID:[30011] expValue:[Portal]actualValue:[Portal]1  
      </propertymatching>
       
      Object properties when script is compiled:
      <propertymatching>
              j:1 propID:[30005] expValue:[Screen/PVN - ###.###.##.## - CDK Drive]actualValue:[Screen/PVN - ###.###.##.## - CDK Drive]1
              j:2 propID:[30003] expValue:[50032]actualValue:[50032]1
              j:3 propID:[30011] expValue:[Portal]actualValue:[]0  
      </propertymatching>
       
    • FrancescoDiMuro
      By FrancescoDiMuro
      Good evening everyone
      I was trying to compile my executable, adding #pragma directives instead of #AutoIt3Wrapper* directives, and, I don't know why the #pragma compile doesn't add the Author field to the executable.

      These are the directives:
      #pragma compile(Author, 'Surname Name') ; or #pragma compile(Author, Surname Name)
      and this is the output, in both cases:
       
      - #pragma directive Author found but don't understand it so will ignore: #pragma compile(Author, 'Surname Name') - #pragma directive Author found but don't understand it so will ignore: #pragma compile(Author, Surname Name) What am I missing?
      Thanks

      Francesco
    • Barrtrek
      By Barrtrek
      I get the "Unable to add resources" error related to AppData\Local\AutoIt v3\Aut2Exe when compiling with a large FileInstall of a 1.5GB file.  Is there a size limit I need to be aware of?  I've also disabled or removed Trend from three different machines and had the same results.  I've had issues like this in the past but have compiled after the Aut2Exe folder was excluded in AV.  That doesn't seem to be the problem this time around.  If I comment out the FileInstall the script compiles successfully.
    • Earthshine
      By Earthshine
      This baby can do almost any language! I found Gleany on this site and set it up on a fresh win10 install. all i would need to do to make it build an exe of the search files app we discovered is the .NET Target Framework download to build 100 % but the exe works and generates! You also need to add the path the the version of csc.exe that you want to run. MSBuild is part of .NET and can read your .csproj file.
      YOU can develop .NET OR C/C++ on this baby!
      Super lightweight (fit for crappy laptops), and you can use any dev compilers you wish, Ming, MS, etc, whatever.
      To use the build, you need to open the csproj file, else, to check your syntax it can compile individual files as well. The warning are because I do not have the .NET 4.6 Targeting Pack installed... LOL, and I could get rid of the Core warning, yes, I did not want to build a .NET Core.dll I wanted a live x64 exe! Told you MSBUILD could handle .CSPROJ, .VBPROJ, and all others Microsoft. Don't let Visual Code or Visual Studio slow you down, although, this works with Visual Code as well but there is only debugging in CORE.DLL projects

      ListFiles Example.zip
       

×