Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   Win32/Win64 API (native code) (https://www.delphipraxis.net/17-win32-win64-api-native-code/)
-   -   Delphi ShellExecute kommt nicht mit %USERPROFILE% klar (https://www.delphipraxis.net/143315-shellexecute-kommt-nicht-mit-userprofile-klar.html)

Hedge 13. Nov 2009 09:29


ShellExecute kommt nicht mit %USERPROFILE% klar
 
Habe das Problem, dass er scheinbar %USERPROFILE% etc. nicht auflösen kann.
Was kann man da machen?

himitsu 13. Nov 2009 09:36

Re: ShellExecute kommt nicht mit %USERPROFILE% klar
 
Wenn was nicht automatisch geht, dann mach es einfach manuell :angel:
MSDN-Library durchsuchenExpandEnvironmentStrings

Hedge 13. Nov 2009 09:46

Re: ShellExecute kommt nicht mit %USERPROFILE% klar
 
Du entwickelst dich zu meinem Personal Trainer hier.
Na hoffentlich kommt am Ende des Monats nicht die Rechnung :roll:

Das funktioniert super.

MathiasSimmack liefert in einem anderen Thema auch die passende Delphi-Funktion:

Delphi-Quellcode:
function ExpandEnvStr(const szInput: string): string;
  const
    MAXSIZE = 32768;
  begin
    SetLength(Result,MAXSIZE);
    SetLength(Result,ExpandEnvironmentStrings(pchar(szInput),
      @Result[1],length(Result)));
  end;

himitsu 13. Nov 2009 10:07

Re: ShellExecute kommt nicht mit %USERPROFILE% klar
 
Zitat:

Zitat von Hedge
Na hoffentlich kommt am Ende des Monats nicht die Rechnung :roll:

Keine Sorge, die ist schon raus und sollte morgen/übermorgen eintreffen :angel:

QuickAndDirty 13. Nov 2009 10:28

Re: ShellExecute kommt nicht mit %USERPROFILE% klar
 
[OT]
*ich schmeiß mich weg*
[/OT]


Alle Zeitangaben in WEZ +1. Es ist jetzt 13:36 Uhr.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz