Jump to content

#Include not working


Recommended Posts

Hi guys,

I am still learning the ropes, so apologies if I have missed something obvious.

Basically, the #include statement is not working for me (not even when I include the full pathname)

e.g.

#include <Date.au3> 
MsgBox(0,'',"The time is:" & _NowTime())

The above example returns the following error;

#include <Date.au3>

Error opening the file

I tried removing/reinstalling Autoit3, but  to no avail.

I have tried installing AutoIt3 firstly in Programs & then when that didn't work, I un-installed it again and re-installed it in Programs(x86).

Have also tried using both AutoIt3.exe and AutoIt3_x64.exe versions, but each time it is the same error.

The only way that the above script (or any script) works is if I run it from within SciTE.

Has anyone else encountered such problems?

Many thanks,

Pete

Edited by pete_wilde
Link to comment
Share on other sites

Hmmm,  I don't have AutoUpdateIt, but I do have AU3Info, Aut2Exe and AutoIt.  Look like you have some bad install, but I cannot be sure.  Maybe someone else could help...

Link to comment
Share on other sites

  • Developers

So you have a standard directory structure in program files(x86)\AutoIt\includes and it contains all files?
Any security settings issue or something? 
Try running SciTE as Admin and test again, just to see if that changes anything.

Jos

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

Link to comment
Share on other sites

Hi Jos,

I un-installed it again, downloaded a fresh version and re-installed it in Programs(x86). Still no luck.

SciTE still works ok.

I did however, navigate to the AutoIt3 folder and ran the Autoit3_x64.exe from there. When it prompted me for the ".au3" file to open I picked the script and it ran ok (?)

Therefore, double-clicking on an ".au3" script seems to fail, but openning either SciTE or running Autoit3_x64.exe works!!!

The Registry entries are still the same as above.

Kind regards,

Pete

Edited by pete_wilde
Link to comment
Share on other sites

Got it sorted !!!!!!!!!!!!!!!   🙂

I ran the ".au3" script and got the error message.

However, I then went into Task Manager and clicked on the Autoit3.exe process.

Then I selected "Open File Location".

It was running an old version of Autoit3 located within a folder (it was for a small portable app that I created for my memory stick).

I deleted that version and when I ran the script again it worked!!!!

Really weird as the default pointed to the Programs(x86) folder, and I also tried the "open with" menu option (and navigated to the Programs(x86) folder).

Anyway, it is all working again 🙂

Many thanks for all your help.

Hopefully, one day I will be as knowledgable as you guys 🙂

Best regards,
Pete

Edited by pete_wilde
Link to comment
Share on other sites

  • Developers

I am sure you have done a right-mouse-click on a *.au3 file and done a "Run With" that old version and ticked the "alway use this program box".

Install the full SciTE4AutoIt3 version, run SciTEConfig (Ctrl+1 when you have a au3 file opened); Select Other tools tab and press button: "Run AutoIt3/SciTE check".
This will show a separate window  with all registry information found and report on any deviations from the default.

Jos

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

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...