Jump to content

Setup.exe


Recommended Posts

Guy, I have looked around for the past 2 hours with out any luck. Maybe someone here can help. I have a GUI that has buttons that starts Excel files and JPEGs on other buttons.. How can I get my compiled script and file packaged together so I can give the EXE file to someone. They install it and it would download the files and give them shortcuts and program icons? How can I make my file paths in my script bullet proof where if someone installs the exe file in a location that I did not script them to be. Hope that is clear.

Thanks in advance.

Obone.

Link to comment
Share on other sites

Guy, I have looked around for the past 2 hours with out any luck. Maybe someone here can help. I have a GUI that has buttons that starts Excel files and JPEGs on other buttons.. How can I get my compiled script and file packaged together so I can give the EXE file to someone. They install it and it would download the files and give them shortcuts and program icons? How can I make my file paths in my script bullet proof where if someone installs the exe file in a location that I did not script them to be. Hope that is clear.

Thanks in advance.

Obone.

FileInstall will allow you to include files in your compiled app, and you can choose where, and even when, those files get placed on the user's computer. You could use things like @tempdir or @desktop to make placement easy, or specify where yourself.

Ian

My projects:

  • IP Scanner - Multi-threaded ping tool to scan your available networks for used and available IP addresses, shows ping times, resolves IPs in to host names, and allows individual IPs to be pinged.
  • INFSniff - Great technicians tool - a tool which scans DriverPacks archives for INF files and parses out the HWIDs to a database file, and rapidly scans the local machine's HWIDs, searches the database for matches, and installs them.
  • PPK3 (Persistent Process Killer V3) - Another for the techs - suppress running processes that you need to keep away, helpful when fighting spyware/viruses.
  • Sync Tool - Folder sync tool with lots of real time information and several checking methods.
  • USMT Front End - Front End for Microsoft's User State Migration Tool, including all files needed for USMT 3.01 and 4.01, 32 bit and 64 bit versions.
  • Audit Tool - Computer audit tool to gather vital hardware, Windows, and Office information for IT managers and field techs. Capabilities include creating a customized site agent.
  • CSV Viewer - Displays CSV files with automatic column sizing and font selection. Lines can also be copied to the clipboard for data extraction.
  • MyDirStat - Lists number and size of files on a drive or specified path, allows for deletion within the app.
  • 2048 Game - My version of 2048, fun tile game.
  • Juice Lab - Ecigarette liquid making calculator.
  • Data Protector - Secure notes to save sensitive information.
  • VHD Footer - Add a footer to a forensic hard drive image to allow it to be mounted or used as a virtual machine hard drive.
  • Find in File - Searches files containing a specified phrase.
Link to comment
Share on other sites

Ok .. I did the build from tools.. I dont think that did anything.. let me try explaining it again. I have my gui code below. You will notice that 4 of the buttons do not work because the files are not with it. How do I package up associated files and the script to a setup.exe file. I want the user to then run the setup exe file and have everything they need to run this little gui.

#NoTrayIcon
#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_icon=logo.ico
#AutoIt3Wrapper_outfile=C:\Documents and Settings\Ben\Desktop\ALT.exe
#AutoIt3Wrapper_UseX64=y
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#include <GuiConstants.au3>
Global $storegui
; Hides tray icon

; Change to OnEvent mode
Opt('GUIOnEventMode', 1)

; GUI Creation

Creategui()

; Shows the GUI after the function completes
GUISetState()

While 1
    Sleep(500)
WEnd




; Button 1

; --------------- FUNCTIONS ---------------------

Func Creategui()

    Local $font

    $font = "Comic Sans MS"
    GuiCreate("ALT Fabrication Toolbox", 700, 590)
    GUISetBkColor(0x4682b4)
    GuiSetIcon("logo.icon")
    ; Runs the GUIExit() function if the GUI is closed
    GUISetOnEvent($GUI_EVENT_CLOSE, 'GUIExit')
    ; Logo / Pic
 GuiCtrlCreatePic("altlogo2.jpg",0,0,700,590)
 GuiCtrlSetState(-1,$GUI_DISABLE)



    ; Button1
    GUICtrlCreateButton("Locations", 10, 430, 158, 50)
    GUICtrlSetOnEvent(-1,'storeinfo' ) ; Runs website() when pressed
    GUICtrlSetBkColor(-1,0x000080)
    GUICtrlSetColor(-1,0xffffff)
    ; Button2
    GUICtrlCreateButton("Contacts", 10, 280, 158, 50)
    GUICtrlSetOnEvent(-1, 'contacts') ; Runs email() when pressed
    GUICtrlSetBkColor(-1,0x000080)
    GUICtrlSetColor(-1,0xffffff)
    ; Button3
    GUICtrlCreateButton("ALT Website",10,480,158,50)
    GUICtrlSetOnEvent(-1,'ALTwebsite')
    GUICtrlSetBkColor(-1,0x000080)
    GUICtrlSetColor(-1,0xffffff)
    ; Button4
    GUICtrlCreateButton("Quote Builder",10,180,158,50)
    GUICtrlSetOnEvent(-1,'quotebuilder')
    GUICtrlSetBkColor(-1,0x000080)
    GUICtrlSetColor(-1,0xffffff)
    ; Button5
    GUICtrlCreateButton("Cut Sheets",10,330,158,50)
    GUICtrlSetOnEvent(-1,'cutsheets')
    GUICtrlSetBkColor(-1,0x000080)
    GUICtrlSetColor(-1,0xffffff)
    ; Button6
    GUICtrlCreateButton("Price Checker",10,230,158,50)
    GUICtrlSetOnEvent(-1,'pricechecker')
    GUICtrlSetBkColor(-1,0x000080)
    GUICtrlSetColor(-1,0xffffff)
    ; Button7
    GUICtrlCreateButton("Houston Store Directions",10,380,158,50)
    GUICtrlSetOnEvent(-1,'directions')
    GUICtrlSetBkColor(-1,0x000080)
    GUICtrlSetColor(-1,0xffffff)
    ; Button8
    GUICtrlCreateButton("Email Sales Contact",10,530,158,50)
    GUICtrlSetOnEvent(-1,'emailsalescontact')
    GUICtrlSetBkColor(-1,0x000080)
    GUICtrlSetColor(-1,0xffffff)
EndFunc


; Button 1
Func storeinfo()

 If IsHWnd($storegui) Then Return;only allow one store gui
    $storegui = GUICreate("ALT Locations",400,336)
    GuiCtrlCreatePic("altlocations.jpg",0,0,400,336)
 GuiCtrlSetState(-1,$GUI_DISABLE)

    GUISetOnEvent($GUI_EVENT_CLOSE, 'GUI2Exit')
    GUISetState()
EndFunc

Func gui2exit()
    GUIDelete($storegui)
    $store = 0
EndFunc  ;==>gui2exit



; Button 2
Func contacts()

 If IsHWnd($storegui) Then Return;only allow one store gui
    $storegui = GUICreate("Contacts",400,336)
    GuiCtrlCreatePic("Contacts.jpg",0,0,400,336)
 GuiCtrlSetState(-1,$GUI_DISABLE)

    GUISetOnEvent($GUI_EVENT_CLOSE, 'GUI2Exit')
    GUISetState()
EndFunc

; Button 3
Func ALTwebsite()
    Run("C:\Program Files\Internet Explorer\iexplore.exe www.altfabrication.com")

EndFunc
; Button 4
func quotebuilder()
GUISetState(@SW_SHOW)
Run(@comspec & ' /c "C:\Documents and Settings\Ben\Desktop\ALT Gui\quotebuilder.xls"','',@sw_hide)
EndFunc
;Button 5
Func cutsheets()
    Run("C:\Program Files\Internet Explorer\iexplore.exe www.altfabrication.com")

EndFunc
;Button 6
Func pricechecker()
    GUISetState(@SW_SHOW)
    Run(@comspec & ' /c "C:\Documents and Settings\Ben\Desktop\ALT Gui\pricechecker.xls"','',@sw_hide)
EndFunc


;Button 7
Func directions()
    Run("C:\Program Files\Internet Explorer\iexplore.exe http://www.google.com/maps?f=q&source=s_q&hl=en&geocode=&q=7611+F+Kempwood,+Houston,+TX+77055&sll=29.817232,-95.4838&sspn=0.007577,0.01649&ie=UTF8&z=17&iwloc=A")

EndFunc
;Button 8
Func emailsalescontact()
ShellExecute('mailto:ben@hitesales.com')
EndFunc



While 1
    Sleep(500)
WEnd

Func GUIExit()
    Exit
EndFunc
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...