Jump to content

Recommended Posts

Posted

Hmmm, mysterious ..., if I do it like this it works. oO

; main.au3

#include <include.au3>

Global $szAppPath = 'C:\AppPath\'
Global $szAppFolder = 'AppFolder'

If Not FileExists($szAppPath & $szAppFolder) Then Function($szAppPath & $szAppFolder)

Exit

; include.au3

Func Function($szDestDir)
    
    If Not FileExists($szDestDir & '\Au3Zipc.dll') Then
        FileInstall('Au3Zipc.dll', $szDestDir & '\Au3Zipc.dll')
    EndIf
    
EndFunc

Hmmm, ... *sniff-snoop* ..., smells like bug in my code ... :)

Greetz

Posted

Hmmm, mysterious ..., if I do it like this it works. oO

Hmmm, ... *sniff-snoop* ..., smells like bug in my code ... :)

Greetz

Been there... done that... got the t-shirt, the collector's mug, and the commemorative plate...

:)

Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Posted

OK, the problem is still alive :)

If I compile this

#Region;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_outfile=moin.exe
#EndRegion;**** Directives created by AutoIt3Wrapper_GUI ****


#include 'include.au3'

Global $szDir = @ScriptDir & '\AutoIt3p'

Func get()
    
    Function($szDir)
    
EndFunc
Exit

; include.au3

Func Function($szDestDir)
    
;If Not FileExists($szDestDir & '\Au3Zipc.dll') Then
        FileInstall('Au3Zipc.dll', $szDestDir & '\Au3Zipc.dll')
;EndIf
    
EndFunc

Sometimes the DLL is put to the resources, sometimes not !

But never the DLL is extracted !!

I played all scenarios trough and trough, so my resume is that it is NOT a code bug in my script.

At first I will take an altenative for FileInstall().

Thanx for notice. :)

Greetz

  • Developers
Posted

I am not surprised this posted script doesn't work:

Where in your example script are performing the get() func ?

Try:

Global $szDir = @ScriptDir & '\AutoIt3p'
DirCreate($szDir)
Get()
Func get()
    Function($szDir)
EndFunc  ;==>get
Exit

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.
  :)

Posted

I am not surprised this posted script doesn't work:

Where in your example script are performing the get() func ?

Try:

Global $szDir = @ScriptDir & '\AutoIt3p'
DirCreate($szDir)
Get()
Func get()
    Function($szDir)
EndFunc ;==>get
Exit
Yes you're right, old boy. :)

I was too tired yesterday and sometimes I'm too blind to see the most essentials things. :)

But why does the FileInstall sometimes work and then not !?

I noticed that if I delete the AutoIt3Wrapper directives and compile it new the DLL will be 'FileInstalled',

if I don't delete the lines and compile the script new then mostly the FileInstall fails -> No changes made.

At evening I will try on, I still have the problem in my script with the errormessage of my first post. :)

Greetz

Greenhorn

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...