Solved

ExecuteFile

Posted on 1997-06-26
8
705 Views
Last Modified: 2008-03-17
ExecuteFile wont work
It says it is an undeclared identifier
What do I need to do to fix this?
I'm using Delphi 3.
0
Comment
Question by:Evil
8 Comments
 

Author Comment

by:Evil
Comment Utility
Edited text of question
0
 
LVL 3

Expert Comment

by:sperling
Comment Utility
You need to add FMXUtils to your 'uses' clause. FMXUtils should be located somewhere in the demo subdirectory tree.

Regards,

Erik.
0
 
LVL 5

Expert Comment

by:ronit051397
Comment Utility
on the directory
C:\Program Files\Borland\Delphi 3\Demos\DOC\FILMANEX
there is an example project of how to use ExecuteFile.
0
 

Expert Comment

by:dr_gonzo
Comment Utility
Use
ShellExecute(handle, "explore", "path_to_folder", NULL, NULL, SW_SHOWNORMAL);

or why not

WinExec('myfile.exe', SW_SHOWNORMAL);
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 

Author Comment

by:Evil
Comment Utility
is there anyway to close the outside application?
0
 
LVL 5

Expert Comment

by:ronit051397
Comment Utility
sendmessage([application handle or window handle],wm_close,0,0);
0
 

Author Comment

by:Evil
Comment Utility
How do I know the Application handle or Window Handle?
0
 
LVL 3

Accepted Solution

by:
mirek071497 earned 50 total points
Comment Utility
function FindWindow(Classname, WindowName: PChar): HWnd

if You need close You'r application then You know ClassName and WindowName.

this example find Progman handle

var
  a : array[0..40] of char
  h : thandle;
begin
   StrPCopy( a, 'Progman' );
   h := FindWindow( a, nil );
end;

0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now