Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel 2007 DDE command send to PW5 Procomm

Status
Not open for further replies.

Zafferg

Technical User
Sep 7, 2016
1
GB
Hello All

Been lurking for a few weeks looking around the forums and Knob's website - all very good info! Written an aspect script for procomm that is literally saving me hundreds of terminal command entries every day! Come from more of a hardware support role and completely new to Aspect, but did C++ back at uni.. cough ... 10 years ago.

I am however having a wee issue that is so lacking in info when searching online it makes me think I'm hitting a brick wall before I even get started.

All I'm trying to do at the moment is create a VB script from within Excel 2007 to just start the Procom and DDE server - not even started passing any commands across yet (which is the end goal of course). The vb dde script works fine to start winword for expample so I know they can't have gimped DDE in excel 2007. The machine is 32bit Window 7 Pro.

Eg. (Code nabbed from somewhere - I'm just re-purposing it for this example)

Code:
Sub Using_DDE1()

      ' Dimension the variables.
      Dim Chan As Integer
      Dim RequestItems As Variant

      ' Start a channel to Word using the System topic.
      Chan = DDEInitiate("winword", "System")


      ' Terminate the DDE channel.
      DDETerminate Chan

      End Sub

Will start the winword2007 app

but

Code:
Sub Using_DDE1()

      ' Dimension the variables.
      Dim Chan As Integer
      Dim RequestItems As Variant

      ' Start a channel to Word using the System topic.
      Chan = DDEInitiate("pw5", "System")


      ' Terminate the DDE channel.
      DDETerminate Chan

      End Sub

Gives an "Run-time error '13: type mismatch.

Am I missing something obvious? I can find loads of examples of DDE scripts for aspect within Procomm manipulating excel spreadsheets but not a single example VB script starting Procomms dde server that works for me. Firing "PW5" into the run bar starts Procommm so I know the association is valid.

The end goal for this is a simple button next to every one of 6000 individual phone numbers within an .XLS that will pass the number, baud, parity, stop bit, data length to procomm to dial. (We are looking after ANCIENT tech!) I found out that the directory within 4.8 maxes out at 500 sites the hard way....
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top