Jump to content

Recommended Posts

Posted

Hi i have create a setup script  for deploy  my application , i  try to use Fileinstall  but  when arrive to complie  tell me one exe  in error adding file  , the exe  is free and  i am in admin mode , not have antivirus ,i not understund  why  is possible  have more detail about error 

A part of my code 

#AutoIt3Wrapper_icon=Install.ico
#AutoIt3Wrapper_UseUpx=n

#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#include <ProgressConstants.au3>
#include <File.au3>

#RequireAdmin

; === FILE PRINCIPALI ===
FileInstall("C:\MeteoraBuild\Alert_FXBLUE_V3.exe", @TempDir & "\Meteora\Alert_FXBLUE_V3.exe", 1)
FileInstall("C:\MeteoraBuild\Cockpit_FXBLUE_V3.exe", @TempDir & "\Meteora\Cockpit_FXBLUE_V3.exe", 1)
FileInstall("C:\MeteoraBuild\CopyTrade_ExchangeTG.exe", @TempDir & "\Meteora\CopyTrade_ExchangeTG.exe", 1)
FileInstall("C:\MeteoraBuild\MarketWatch_BAR_FXBLUE_V3.exe", @TempDir & "\Meteora\MarketWatch_BAR_FXBLUE_V3.exe", 1)
FileInstall("C:\MeteoraBuild\NtoN.exe", @TempDir & "\Meteora\NtoN.exe", 1)
FileInstall("C:\MeteoraBuild\Starter_V3.exe", @TempDir & "\Meteora\Starter_V3.exe", 1)
FileInstall("C:\MeteoraBuild\TerminalGui_FXBLUE_V3.exe", @TempDir & "\Meteora\TerminalGui_FXBLUE_V3.exe", 1)
FileInstall("C:\MeteoraBuild\CopyTradeV4.exe", @TempDir & "\Meteora\CopyTradeV4.exe", 1)
FileInstall("C:\MeteoraBuild\FXBlueQuickChannel64.dll", @TempDir & "\Meteora\FXBlueQuickChannel64.dll", 1)
FileInstall("C:\MeteoraBuild\sqlite3_x64.dll", @TempDir & "\Meteora\sqlite3_x64.dll", 1)
FileInstall("C:\MeteoraBuild\Config.ini", @TempDir & "\Meteora\Config.ini", 1)
FileInstall("C:\MeteoraBuild\ConfigTelegram.ini", @TempDir & "\Meteora\ConfigTelegram.ini", 1)
FileInstall("C:\MeteoraBuild\MarketWatchConfig.ini", @TempDir & "\Meteora\MarketWatchConfig.ini", 1)

; === LANGUAGE ===
FileInstall("C:\MeteoraBuild\Language\Italiano.lang", @TempDir & "\Meteora\Language\Italiano.lang", 1)
FileInstall("C:\MeteoraBuild\Language\English.lang", @TempDir & "\Meteora\Language\English.lang", 1)

; === COPYTRADE ===
FileInstall("C:\MeteoraBuild\CopyTrade\Italiano.lang", @TempDir & "\Meteora\CopyTrade\Italiano.lang", 1)
FileInstall("C:\MeteoraBuild\CopyTrade\English.lang", @TempDir & "\Meteora\CopyTrade\English.lang", 1)

; === SOUND ===
FileInstall("C:\MeteoraBuild\Sound\alert-33762.mp3", @TempDir & "\Meteora\Sound\alert-33762.mp3", 1)
; ... (continua con tutti i file audio)

; === MQL5 ===
FileInstall("C:\MeteoraBuild\MQL5\Experts\CONTROLLER_V2.ex5", @TempDir & "\Meteora\MQL5\Experts\CONTROLLER_V2.ex5", 1)
FileInstall("C:\MeteoraBuild\MQL5\Experts\DEMON_TRADE.ex5", @TempDir & "\Meteora\MQL5\Experts\DEMON_TRADE.ex5", 1)
FileInstall("C:\MeteoraBuild\MQL5\Files\MonitorTrade.db", @TempDir & "\Meteora\MQL5\Files\MonitorTrade.db", 1)
FileInstall("C:\MeteoraBuild\MQL5\Indicators\RPC.ex5", @TempDir & "\Meteora\MQL5\Indicators\RPC.ex5", 1)
FileInstall("C:\MeteoraBuild\MQL5\Libraries\FXBlueQuickChannel64.dll", @TempDir & "\Meteora\MQL5\Libraries\FXBlueQuickChannel64.dll", 1)
FileInstall("C:\MeteoraBuild\MQL5\Profiles\Templates\DEFAULT_METEORA.tpl", @TempDir & "\Meteora\MQL5\Profiles\Templates\DEFAULT_METEORA.tpl", 1)

 

Posted (edited)

from the help file

The destination directory path must already exist before this function is called, or the FileInstall() will fail, returning 0 and not creating the file, nor path. See DirCreate() for information about creating the directory path.

:unsure:

I didn't see anywhere to check If Not FileExists(@TempDir& "\Meteora") Then DirCreate(@TempDir& "\Meteora")

Edit: e.g.

#AutoIt3Wrapper_icon=Install.ico
#AutoIt3Wrapper_UseUpx=n

#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#include <ProgressConstants.au3>
#include <File.au3>

#RequireAdmin

Local $sSetUpDir = @TempDir & "\MySetUp"
DirRemove($sSetUpDir, 1)
DirCreate($sSetUpDir)


; === FILE PRINCIPALI ===
DirCreate($sSetUpDir & "\Meteora")
FileInstall("C:\MeteoraBuild\Alert_FXBLUE_V3.exe", $sSetUpDir & "\Meteora\Alert_FXBLUE_V3.exe", 1)
FileInstall("C:\MeteoraBuild\Cockpit_FXBLUE_V3.exe", $sSetUpDir & "\Meteora\Cockpit_FXBLUE_V3.exe", 1)
FileInstall("C:\MeteoraBuild\CopyTrade_ExchangeTG.exe", $sSetUpDir & "\Meteora\CopyTrade_ExchangeTG.exe", 1)
FileInstall("C:\MeteoraBuild\MarketWatch_BAR_FXBLUE_V3.exe", $sSetUpDir & "\Meteora\MarketWatch_BAR_FXBLUE_V3.exe", 1)
FileInstall("C:\MeteoraBuild\NtoN.exe", $sSetUpDir & "\Meteora\NtoN.exe", 1)
FileInstall("C:\MeteoraBuild\Starter_V3.exe", $sSetUpDir & "\Meteora\Starter_V3.exe", 1)
FileInstall("C:\MeteoraBuild\TerminalGui_FXBLUE_V3.exe", $sSetUpDir & "\Meteora\TerminalGui_FXBLUE_V3.exe", 1)
FileInstall("C:\MeteoraBuild\CopyTradeV4.exe", $sSetUpDir & "\Meteora\CopyTradeV4.exe", 1)
FileInstall("C:\MeteoraBuild\FXBlueQuickChannel64.dll", $sSetUpDir & "\Meteora\FXBlueQuickChannel64.dll", 1)
FileInstall("C:\MeteoraBuild\sqlite3_x64.dll", $sSetUpDir & "\Meteora\sqlite3_x64.dll", 1)
FileInstall("C:\MeteoraBuild\Config.ini", $sSetUpDir & "\Meteora\Config.ini", 1)
FileInstall("C:\MeteoraBuild\ConfigTelegram.ini", $sSetUpDir & "\Meteora\ConfigTelegram.ini", 1)
FileInstall("C:\MeteoraBuild\MarketWatchConfig.ini", $sSetUpDir & "\Meteora\MarketWatchConfig.ini", 1)

; === LANGUAGE ===
DirCreate($sSetUpDir & "\Meteora\Language")
FileInstall("C:\MeteoraBuild\Language\Italiano.lang", $sSetUpDir & "\Meteora\Language\Italiano.lang", 1)
FileInstall("C:\MeteoraBuild\Language\English.lang", $sSetUpDir & "\Meteora\Language\English.lang", 1)

; === COPYTRADE ===
DirCreate($sSetUpDir & "\Meteora\CopyTrade")
FileInstall("C:\MeteoraBuild\CopyTrade\Italiano.lang", $sSetUpDir & "\Meteora\CopyTrade\Italiano.lang", 1)
FileInstall("C:\MeteoraBuild\CopyTrade\English.lang", $sSetUpDir & "\Meteora\CopyTrade\English.lang", 1)

; === SOUND ===
DirCreate($sSetUpDir & "\Meteora\Sound")
FileInstall("C:\MeteoraBuild\Sound\alert-33762.mp3", $sSetUpDir & "\Meteora\Sound\alert-33762.mp3", 1)
; ... (continua con tutti i file audio)
...
...

 

Edited by ioa747

I know that I know nothing

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