Re: Paramstr

From: Peder Hanghøj (peder_at_hanghoej.dk)
Date: 11/19/03


Date: Wed, 19 Nov 2003 23:51:48 +0100

Thanks, you have solved my problem

Peder

"Rob Kennedy" <.> skrev i en meddelelse
news:vrn4cr21es1n28@corp.supernews.com...
> "Peder Hangh???????????????????????" wrote:
> > I am using Delphi 6
> > I am uding shellexecute in a program to start an other program with 3
> > parameters:
>
> Might I suggest you use CreateProcess instead? ShellExecute is designed
> to figure out the command line automatically by looking in the registry,
> and there is the potential for confusion if what it finds in the
> registry doesn't match what you tell it to use.
>
> > Shellexecute(Handle,pchar('open'),pchar('newprogram.exe'),pchar(param1+'
> > '+param2+' '+param3),Pchar(''),sw_normal)
> > In Newprogram.exe i am using jeg param(1)-param(3) reading the 3
parameters.
> > It works fine, but...
> >
> > On some - only some - windows 98 mashines it does not work.
>
> "It does not work" is a useless description. In what way does it not
> work? Does your program crash? Does ShellExecute return an error code?
> Are the images loaded upside-down? On what sorts of machines does it
> "work"? If you're looking at the difference between Windows 95 and
> Windows NT, the length of the command line may be a factor.
>
> --
> Rob
>



Relevant Pages

  • Re: ShellExecute fails when printing a document.
    ... For this I want to find the command which is to be given. ... >> Is there a way I can overcome this issue? ... > I suggest you check the registry before using ShellExecute. ...
    (microsoft.public.fox.programmer.exchange)
  • Re: Paramstr
    ... > I am uding shellexecute in a program to start an other program with 3 ... registry doesn't match what you tell it to use. ... Windows NT, the length of the command line may be a factor. ...
    (alt.comp.lang.borland-delphi)
  • Re: Communication Between Programs
    ... > Stefan, most of those examples are about how to use the ShellExecute ... specific command line parameter or without one. ... Create CreateProcess() structure and start it... ...
    (microsoft.public.win32.programmer.ui)
  • Re: New IE Instance
    ... Instead of using ShellExecute on the HTML ... > file itself it looks in the registry for the associated executable and ... > launches that instead with the URL as a command line parameter. ...
    (borland.public.delphi.nativeapi)
  • Re: execute dos command
    ... What would the command look like given the command line below? ... And while we are on the subject the Reg Load command is NO GOOD ... >Use CreateProcess or ShellExecute or ShellExecuteEx. ...
    (alt.comp.lang.borland-delphi)