Daniel W. Posted June 5, 2006 Share Posted June 5, 2006 (edited) Hi, i want to write an Install Programm but i got a problem. The programm should be a UDF so it works with Variables but with the Fileinstall function i cant use variables ... i already tried this Global $name = @ScriptDir & "\keks.gif" FileInstall( FileGetLongName($name ), @ScriptDir & "\kek.gif") oÝ÷ ٩ݶ§÷¥¶X¤z+wöYgz÷«Âäjwm®'¶¬jëh×6 #include <string.au3> Global $name = @ScriptDir & "\keks.gif" FileInstall( _stringencrypt( 1 , _stringencrypt(0, $name , "abc"), "abc" ), @ScriptDir & "\kek.gif") How can i get rid of that variable shit? Regards Edited June 5, 2006 by Daniel W. --------------------------------------------------------------------------------------------------------------------------------Scripts : _Encrypt UDF_UniquePCCode UDF MS like calculatorInstall programm *UPDATED* --------------------------------------------------------------------------------------------------------------------------------[quote name='Helge' post='213117' date='Jul 26 2006, 10:22 AM']Have you ever tried surfing the internet with a milk-carton ?This is similar to what you're trying to do.[/quote] Link to comment Share on other sites More sharing options...
ChrisL Posted June 5, 2006 Share Posted June 5, 2006 If you look in the help file at fileinstall, it tells you that the file to install can not be a variable it must be the full path to the file, however the path can be relative to the script, so if the file was in the same directory as the script you could Fileinstall ("myFile.dll", @tempdir & "\MyFile.dll",1) [u]Scripts[/u]Minimize gui to systray _ Fail safe source recoveryMsgbox UDF _ _procwatch() Stop your app from being closedLicensed/Trial software system _ Buffering Hotkeys_SQL.au3 ADODB.Connection _ Search 2d Arrays_SplashTextWithGraphicOn() _ Adjust Screen GammaTransparent Controls _ Eventlogs without the crap_GuiCtrlCreateFlash() _ Simple Interscript communication[u]Websites[/u]Curious Campers VW Hightops Lambert Plant Hire Link to comment Share on other sites More sharing options...
Daniel W. Posted June 5, 2006 Author Share Posted June 5, 2006 No it should work on another way. A window pops up where you can choose what you want to install: for example - Exe of file - Source code of file etc And this window is called with a function --------------------------------------------------------------------------------------------------------------------------------Scripts : _Encrypt UDF_UniquePCCode UDF MS like calculatorInstall programm *UPDATED* --------------------------------------------------------------------------------------------------------------------------------[quote name='Helge' post='213117' date='Jul 26 2006, 10:22 AM']Have you ever tried surfing the internet with a milk-carton ?This is similar to what you're trying to do.[/quote] Link to comment Share on other sites More sharing options...
Nomad Posted June 5, 2006 Share Posted June 5, 2006 No it should work on another way.A window pops up where you can choose what you want to install:for example- Exe of file- Source code of fileetcAnd this window is called with a function That is a different concept. FileInstall is used to install files included with your script. They cannot contain a variable in the source path. To do what you want, at least what I think you want, you can set a FileInstall for every file contained within your .exe and execute them under specific conditions. Like a user selecting the file. But you will still need the full source path in the FileInstall. Nomad Link to comment Share on other sites More sharing options...
Daniel W. Posted June 5, 2006 Author Share Posted June 5, 2006 i know how fileinstall works ... but i want to do it that way that when someone wants to upload a programm that he can create a little autoit programm like this #include <GUIConstants.au3> #include <installer.au3> _install( @ScriptDir & "\keks.gif", "C:\andthistoo.jpg") And then the parameters that are called with _install are included in the .exe and when someone downloads the autoit programm he starts it he gets gui where he can choose the files he want to install ( in this case the both files from parameters ) and then clicks "OK" . THen he chooses the path where he want to install it and than the FileInstall function is called with the first parameter and then again with the second parameter --------------------------------------------------------------------------------------------------------------------------------Scripts : _Encrypt UDF_UniquePCCode UDF MS like calculatorInstall programm *UPDATED* --------------------------------------------------------------------------------------------------------------------------------[quote name='Helge' post='213117' date='Jul 26 2006, 10:22 AM']Have you ever tried surfing the internet with a milk-carton ?This is similar to what you're trying to do.[/quote] Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now