FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Start program
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
Start program
Posted: Wed Feb 17, 2010 09:32 PM

Hi, all !

How to start the program in memory ?

Posts: 4840
Joined: Fri Nov 18, 2005 04:52 PM
Re: Start program
Posted: Thu Feb 18, 2010 02:24 AM

Hmm, the obvious answer is to double-click on the EXE, but I am guessing I don't understand your question.

James

FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
Re: Start program
Posted: Thu Feb 18, 2010 08:17 AM

Well, I will ask a question on another. Whether it is possible to start the program from a variable ?

Posts: 9020
Joined: Thu Oct 06, 2005 08:17 PM
Re: Start program
Posted: Thu Feb 18, 2010 08:26 AM
Something like

Code (fw): Select all Collapse
cVar = "MYAPP.EXE"

ShellExecute( 0, 0, cVar, 0, 0, 1 )


?

EMG
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
Re: Start program
Posted: Thu Feb 18, 2010 08:44 AM

No, I mean such variant

cVrb: = memoread ("myapp.exe")

As I can start the program from a variable cVrb ?

Posts: 9020
Joined: Thu Oct 06, 2005 08:17 PM
Re: Start program
Posted: Thu Feb 18, 2010 09:43 AM

Sorry, I don't know.

EMG

Posts: 1091
Joined: Thu Nov 17, 2005 11:08 AM
Re: Start program
Posted: Thu Feb 18, 2010 09:45 AM

What would you get?

Marco Boschi
info@marcoboschi.it
Posts: 9020
Joined: Thu Oct 06, 2005 08:17 PM
Re: Start program
Posted: Thu Feb 18, 2010 10:00 AM

He would want to execute the binary code stored in a variable.

EMG

Posts: 811
Joined: Tue May 06, 2008 04:28 AM
Re: Start program
Posted: Sat Feb 20, 2010 02:27 AM

Dear Natter,

If you are using a table with BLOB field support like ADS for example.
You can save the .exe to that field using AdsFile2Blob() function, export the content with AdsBlob2File() function. Then you can execute the exported binary (.exe).

It's like executing .exe from variable/field.

Just a thought with my 2Cents.

Regards,
FAP

Kind Regards,

Frances



Fivewin for xHarbour v18.07

xHarbour v1.2.3.x

BCC 7.3 + PellesC8 ( Resource Compiler only)

ADS 10.1 / MariaDB

Crystal Reports 8.5/9.23 DE

xMate v1.15
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: Start program
Posted: Sat Feb 20, 2010 03:09 AM
export the content with AdsBlob2File() function. Then you can execute the exported binary (.exe).

This amounts to writing the exe on the disk and executing the exe from disk. What Mr. Natter is interested to know is whether it is possible to directly execute the code in the memory, without writing it to the disk.
Regards



G. N. Rao.

Hyderabad, India
Posts: 6983
Joined: Fri Oct 07, 2005 07:07 PM
Re: Start program
Posted: Sat Feb 20, 2010 07:09 AM

http://boxedapp.com/boxedappsdk/
I found a description why it could be useful to execute a exe from memory.

Best regards,
Otto

Continue the discussion