Wilson WindowWare Tech Support

WinBatch WinBatch+Compiler WebBatch
Home | Tech Database | Tech BBS | White Papers | Purchase


Netscape and DDEExecute

Keywords:     DDEExecute

Question:

I use a text-based editor to edit my HTML files with Netscape running in the background. When I press a button the script below is run which (used to) load the current file.

Recently, I upgraded both Netscape Communicator (4.01-->4.02) AND WinBatch (97b-->97d) and since then this script hasn't worked. The DDEExecute() function just returns 0 even though a channel was initiated.

PS. Running under Win95.

WinTitle("",`Loading %param1%`)

Terminate(param0!=1, "NetscapeLoad","Usage: NetscapeLoad \path\file.html")
channel=DDEInitiate("Netscape","WWW_ShowFile")

If channel != 0
  DDEExecute(channel,param1)
  DDETerminate(channel)
Else
  Run("C:\Program Files\Netscape\Communicator\Program\Netscape.exe",'-P"offline" %param1%')
EndIf

title="~ - Netscape"
If WinWaitExist(title,15) Then WinActivate(title)
Exit

Any ideas why this might be happening? Is it a Netscape or WinBatch problem? Thanks.

Answer:

None of the WinBatch DDE stuff changed between 97B and 97D. In fact it has not changed in years.

If you search through your registry, you'll see that Netscape uses the DDE application name "NSShell" instead of "Netscape" now. Plug that in, and everything should work again.


Article ID:   W13352
Filename:   Netscape and DDEExecute.txt