Sign in to follow this  
Followers 0
armoros

Run() function-Portable app

12 posts in this topic

Hi people i want to know how to create a script to run a portable application from my gui.

i know the [ Run() function ie. sRun = "c:\program files\....etc] to run a program from my pc.

But how to run a portable app that is compiled with my gui, so to be able to execute it in a pc in my school etc.

how the dir-location should look like that contains the portable app.

I hope i made you understand what i mean.

Thanks in advance


[font="verdana, geneva, sans-serif"] [/font]

Share this post


Link to post
Share on other sites



You can use FileInstall and install it to the @TempDir &""

Then Run(@TempDir & "portableapp.exe")

Thank you rogue5099 for the fast response i wil read about the Fileistall and i will test it.

Thank you.


[font="verdana, geneva, sans-serif"] [/font]

Share this post


Link to post
Share on other sites

Thank you rogue5099 for the fast response i wil read about the Fileistall and i will test it.

Thank you.

Well i tried but cant do it ;)

any advice?

thanks


[font="verdana, geneva, sans-serif"] [/font]

Share this post


Link to post
Share on other sites

Great, at least show what you tried though.


_AdapterConnections()_AlwaysRun()_AppMon()_AppMonEx()_BinaryBin()_CheckMsgBox()_CmdLineRaw()_ContextMenu()_ConvertLHWebColor()/_ConvertSHWebColor()_DesktopDimensions()_DisplayPassword()_DotNet_Load()/_DotNet_Unload()_Fibonacci()_FileCompare()_FileCompareContents()_FileNameByHandle()_FilePrefix/SRE()_FindInFile()_GetBackgroundColor()/_SetBackgroundColor()_GetConrolID()_GetCtrlClass()_GetDirectoryFormat()_GetDriveMediaType()_GetFilename()/_GetFilenameExt()_GetHardwareID()_GetIP()_GetIP_Country()_GetOSLanguage()_GetSavedSource()_GetStringSize()_GetSystemPaths()_GetURLImage()_GIFImage()_GoogleWeather()_GUICtrlCreateGroup()_GUICtrlListBox_CreateArray()_GUICtrlListView_CreateArray()_GUICtrlListView_SaveCSV()_GUICtrlListView_SaveHTML()_GUICtrlListView_SaveTxt()_GUICtrlListView_SaveXML()_GUICtrlMenu_Recent()_GUICtrlMenu_SetItemImage()_GUICtrlTreeView_CreateArray()_GUIDisable()_GUIImageList_SetIconFromHandle()_GUIRegisterMsg()_GUISetIcon()_Icon_Clear()/_Icon_Set()_IdleTime()_InetGet()_InetGetGUI()_InetGetProgress()_IPDetails()_IsFileOlder()_IsGUID()_IsHex()_IsPalindrome()_IsRegKey()_IsStringRegExp()_IsSystemDrive()_IsUPX()_IsValidType()_IsWebColor()_Language()_Log()_MicrosoftInternetConnectivity()_MSDNDataType()_PathFull/GetRelative/Split()_PathSplitEx()_PrintFromArray()_ProgressSetMarquee()_ReDim()_RockPaperScissors()/_RockPaperScissorsLizardSpock()_ScrollingCredits_SelfDelete()_SelfRename()_SelfUpdate()_SendTo()_ShellAll()_ShellFile()_ShellFolder()_SingletonHWID()_SingletonPID()_Startup()_StringCompact()_StringIsValid()_StringRegExpMetaCharacters()_StringReplaceWholeWord()_StringStripChars()_Temperature()_TrialPeriod()_UKToUSDate()/_USToUKDate()_WinAPI_Create_CTL_CODE()_WinAPI_CreateGUID()_WMIDateStringToDate()/_DateToWMIDateString()Au3 script parsingAutoIt SearchAutoIt3 PortableAutoIt3WrapperToPragmaAutoItWinGetTitle()/AutoItWinSetTitle()CodingDirToHTML5FileInstallrFileReadLastChars()GeoIP databaseGUI - Only Close ButtonGUI ExamplesGUICtrlDeleteImage()GUICtrlGetBkColor()GUICtrlGetStyle()GUIEventsGUIGetBkColor()Int_Parse() & Int_TryParse()IsISBN()LockFile()Mapping CtrlIDsOOP in AutoItParseHeadersToSciTE()PasswordValidPasteBinPosts Per DayPreExpandProtect GlobalsQueue()Resource UpdateResourcesExSciTE JumpSettings INISHELLHOOKShunting-YardSignature CreatorStack()Stopwatch()StringAddLF()/StringStripLF()StringEOLToCRLF()VSCROLLWM_COPYDATAMore Examples...

Updated: 04/09/2015

Share this post


Link to post
Share on other sites

Great, at least show what you tried though.

Thank you sir

iam trying this script n the same dire but isnot embeded in the gui

#Include <WindowsConstants.au3>
#include <WinAPI.au3>
#Include <Constants.au3>
$hGUI = GUICreate("Test", 500, 500)
GUISetState()
Run("ddd.bat")
Sleep(2000)
$hHandle = WinGetHandle("ddd")
_WinAPI_SetWindowLong($hHandle, $GWL_STYLE, BitOr($WS_POPUP, $WS_VISIBLE))
_WinAPI_SetParent($hHandle, $hGUI)
Do
    Sleep(200)
Until GUIGetMsg() = -3

[font="verdana, geneva, sans-serif"] [/font]

Share this post


Link to post
Share on other sites

Hi, armoros. Try specifying the path to your batch file.

Run(@Scriptdir & "ddd.bat")

√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
Share on other sites

Hi, armoros. Try specifying the path to your batch file.

Run(@Scriptdir & "ddd.bat")

Hi JLogan3o13 i put it like you say but nothing it open the bat file with the gui but is not embeded in the parent window.
#Include <WindowsConstants.au3>
#include <WinAPI.au3>
#Include <Constants.au3>
$hGUI = GUICreate("Test", 800, 500)
GUISetState()
Run(@Scriptdir & "ddd.bat")
Sleep(2000)
$hHandle = WinGetHandle("ddd")
_WinAPI_SetWindowLong($hHandle, $GWL_STYLE, BitOr($WS_POPUP, $WS_VISIBLE))
_WinAPI_SetParent($hHandle, $hGUI)
Do
    Sleep(200)
Until GUIGetMsg() = -3

I thing i gona stop trying scripting and start bodybuilding ;)

Thank you anyway for your effort ...


[font="verdana, geneva, sans-serif"] [/font]

Share this post


Link to post
Share on other sites

Maybe if you provide us with what your batch file is accomplishing, we can assist further? It is difficult to help completely with only half the puzzle ;)


√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
Share on other sites

Maybe if you provide us with what your batch file is accomplishing, we can assist further? It is difficult to help completely with only half the puzzle ;)

thanks for you patience JLogan

the ddd.bat is just a cmd command k/ipconfig..is just for test...

the whole thing that i want, is to be able to make a portable program that i have [ portableapps cmd ] to run inside the gui that i made. [ to open and close together ] and if i ever made it to have prebuilt commands and sent them in the cmd window.

Thank you again JLogan for bearing with me..


[font="verdana, geneva, sans-serif"] [/font]

Share this post


Link to post
Share on other sites

I'm still not 100% sure if I am getting what you're attempting to accomplish, but it sounds as though you want to run an external portable app, but encase it's window in an AutoIt GUI. Someone much more intelligent than I may come along and be able to tell you how to do it, but I have never seen it done. The only thing I have seen with embedding would be to use _IECreateEmbedded to embed a web page into a GUI, but I am guessing that is not what you're after.


√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
Share on other sites

I'm still not 100% sure if I am getting what you're attempting to accomplish, but it sounds as though you want to run an external portable app, but encase it's window in an AutoIt GUI. Someone much more intelligent than I may come along and be able to tell you how to do it, but I have never seen it done. The only thing I have seen with embedding would be to use _IECreateEmbedded to embed a web page into a GUI, but I am guessing that is not what you're after.

Thank you again JLogan probably is me that i cant explain what i want....

i will try it the _IE.

Thank you again JLogan and the other people for the assistance.


[font="verdana, geneva, sans-serif"] [/font]

Share this post


Link to post
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
Sign in to follow this  
Followers 0