DDE Poke Excel to PLC

xC0MMAND0x

Member
Join Date
Jul 2013
Location
Minnesota
Posts
265
I know there are other topics on this, but I'm trying to get an already working Macro in Excel to run on my machine (Win 7 64-Bit). I'm thinking there might be a problem with the 64 bit system, as it works okay on other 32bit systems.

Here is the code, as well as 2 screenshots of the errors. It is having problems with RSLinx.

Code:
Private Sub CommandButton1_Click()

'open dde link:
Dim RSIchan As Long

RSIchan = DDEInitiate("RSLinx", "Test_Pin_Push_App")

'write data thru channel
DDEPoke RSIchan, "TagValue", Range("A1")

'close dde channel
DDETerminate (RSIchan)


End Sub
And here are the 2 errors:





I have tried explicitly adding the following code, but it didn't work either.

Code:
Dim RSLinx as String
RsLinx = "C:\Program Files (x86)\Rockwell Software\RSLinx\RSLINX.EXE"
Any thoughts/ideas? Is it a 64-bit OS issue?
 
Your code worked on my W7x64 machine. The first time I ran it though, I hadn't created the DDE topic Test_Pin_Push_App in RSLinx and I got errors similar to yours.
 
Your code worked on my W7x64 machine. The first time I ran it though, I hadn't created the DDE topic Test_Pin_Push_App in RSLinx and I got errors similar to yours.


o_Oo_Oo_O I had my topic name wrong! I had Test_App_Pin_Push.

Thank you for testing that and pointing our my careless mistake! I'll reconfigure and test it when I have time.
 

Similar Topics

I know this has been covered many times and I have tried EVERY code snip-it that I have found to no avail... First off I have data already setup...
Replies
16
Views
21,995
Hello all, first time posting here. I am writing a VBA routine to write tag values in Logix Designer 5000 V30 using DDE poke. The tags in want to...
Replies
2
Views
1,630
Hi. I am having trouble writing to an address in Control Logix using Visual Basic if it is inside a UDT tag. For example if I create a new tag...
Replies
1
Views
2,642
Hi , I've managed to get a DDEpoke comand set up to send the string data from cell A1 in an Excel sheet to ST15:0 in a Micro logix via RSLinx...
Replies
2
Views
8,506
I need to support some old data collection that is running on Excel, but I need to get it running on LibreOffice. The following statement works...
Replies
0
Views
85
Back
Top Bottom