 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Volker Nabholz Guest
|
Posted: Tue May 11, 2004 3:26 pm Post subject: file association Win98 problem |
|
|
Hi Group,
we are programming with Delphi 6 + 7 and we have a problem with
"DDEServerConv". I don't know if it's a problem with this component
or if the error is somewhere else.
We want to start our application (proplan3.exe) and load a plan when
we doubleklick on a plan (*.ppl) in the explorer wich is related to our
program. Therefore we made the changes in the registry.
[HKEY_LOCAL_MACHINESoftwareCLASSES.ppl]
@="proplan3.Document"
[HKEY_LOCAL_MACHINESoftwareCLASSESproplan3.Document]
@="pro-Plan3 Document"
[HKEY_LOCAL_MACHINESoftwareCLASSESproplan3.Documentshell]
[HKEY_LOCAL_MACHINESoftwareCLASSESproplan3.Documentshellopen]
[HKEY_LOCAL_MACHINESoftwareCLASSESproplan3.Documentshellopenddeexec]
@="[FileOpen(%1)]"
[HKEY_LOCAL_MACHINESoftwareCLASSESproplan3.DocumentshellopenddeexecAp
plication]
@="PROPLAN3"
[HKEY_LOCAL_MACHINESoftwareCLASSESproplan3.DocumentshellopenddeexecTo
pic]
@="DDESystem"
[HKEY_LOCAL_MACHINESoftwareCLASSESproplan3.Documentshellopencommand]
@="C:\Programme\proPlan3\proplan3.exe"
We use "DDEServerConv" and this is what we do when ExecuteMacro will be
started.
procedure TfrmHaupt.DDESystemExecuteMacro(Sender: TObject; Msg: TStrings);
var
xFileName : string;
begin
if Pos('FileOpen', Msg.Strings[0]) > 0 then
begin
xFileName := Copy(Msg.Strings[0], Pos('(', Msg.Strings[0]) + 1,
Length(Msg.Strings[0]));
xFileName := Copy(xFileName, 1, Pos(')', xFileName) - 1);
if xFileName[1] = '"' then
xFileName := Copy(xFileName, 2, Length(xFileName));
if xFileName[Length(xFileName)] = '"' then
SetLength(xFileName, Length(xFileName) - 1);
WaitForInfoDlgClosed;
OpenFilename(xFileName);
end;
end;
The problem now is:
On W2k machines all will work fine.
On Win9x machines it will work only when proplan3.exe was started before.
It doesn't matter how it was started, via the Explorer oder Desktop-Icon.
I have a clean Win98 SE Image to try everytime with a new System.
That means when I reboot the machine and doubleclick a .ppl file,
proplan3.exe will start but NOT load the plan. It doesn't jump into the
DDESystemExecuteMacro. Long before the first screen of of proplan3.exe
will be shown, win9x shows a message:
---------------------------------------------------------------
C:ProgrammeproPlan3ProjekteTest.ppl
---------------------------------------------------------------
The file C:ProgrammeproPlan3ProjekteTest.ppl or one of it's
components is not found. Please confirm that all path- and
filenames are correct and all libraries are available.
---------------------------------------------------------------
If I try this then a second time all will work fine. So can you tell me
if we do something wrong.
Thanks in advance for your help!
Volker Nabholz
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|