Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 20
Default Calling executables from VB

What is the best way to exchange data between an executable and VB?

For example, I have an executable (Test.exe) that takes two input variables
and then returns their sum. I use the Shell function:

RetVal = Shell(€śC:\Test.exe 3 4€ť)

Test.exe returns 7 (3+4) but this value is not passed to VB (The value
returned by Shell is a Task ID number). How do I get the returned value of
Test.exe in VB? Is there a better way to exchange data than using the Shell
function?

The big picture objective here is to be able write computationally intensive
routines in C and call them from within Excel VB.


Tx,

Randall

  #2   Report Post  
Posted to microsoft.public.excel.programming
moi moi is offline
external usenet poster
 
Posts: 27
Default Calling executables from VB

Why choose for an .exe instead of a .dll?


"Randall" schreef in bericht
...
What is the best way to exchange data between an executable and VB?

For example, I have an executable (Test.exe) that takes two input
variables
and then returns their sum. I use the Shell function:

RetVal = Shell("C:\Test.exe 3 4")

Test.exe returns 7 (3+4) but this value is not passed to VB (The value
returned by Shell is a Task ID number). How do I get the returned value
of
Test.exe in VB? Is there a better way to exchange data than using the
Shell
function?

The big picture objective here is to be able write computationally
intensive
routines in C and call them from within Excel VB.


Tx,

Randall



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
HELP!!!! Calling a sub from Workbook_BeforeSave RocketMan[_2_] Excel Discussion (Misc queries) 4 May 31st 07 11:47 PM
Calling an Add-In BillCPA Excel Discussion (Misc queries) 2 August 11th 05 09:32 PM
Calling SUB Peter Longstaff Excel Programming 2 February 23rd 04 08:04 PM
Embedding Executables in Excel File? nano_electronix[_5_] Excel Programming 1 February 15th 04 10:28 PM
Calling certain functions within VBA Ron de Bruin Excel Programming 0 August 11th 03 10:32 PM


All times are GMT +1. The time now is 05:30 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"