Make a hotlink between Access 2000 and RSLinx

mulderm

Member
Join Date
Jun 2003
Location
Netherlands
Posts
298
Hello,

I want to make a hotlink between Access 2000 and RSLinx Professional.
I want sending some parameters from Access 2000 database to the
Allen Bradley PLC-5.

Who can tell me how to do this?
What is the VBA-code for this?

Greetings,

mulderm
 
You do this as follows:

1) Make sure that you've got an RSLinx license and not RSLinx Lite.
2) In the Access VBA editor select Tools -> References
3) Select the RSLinx OPC object model

Sample code for the object model is available from Rockwell. I won't be able to get you this because I won't be in the office until later this week. If you can wait until then I'll try and send it to you. If not I'm sure that there are other people in the forum who've done this.

Once you're connected to the object model you use simple VBA commands to read and write to/from RSLinx.

As for accessing (no pun intended) the Access database I like to use the DAO object model (select it the same way as you did the RSLinx OPC object model). If you need help here, just ask.

Good Luck,

(8{)} ( .)
 
Hello (8{)} ( .) ,

Thank you for help me.
I have in the Access VBA editor select Tools -> References, but the RSLinx OPC object model
is not in the list.
What is DAO object model and how must I configure this?
When you at office, please send me the sample code.
Will you help me exactly how to get data from access
to the plc-5, I am new to do with access-handling.
I know to make a topic with excel by RSLinx but with access
is it difficult.

Greetings,

mulderm
 
Last edited:
Hi Mulderm,

You mention that you've got some experience getting data to Excel. If I read into this statement correctly this means that you've got some experience using DDE. I don't recommend DDE for communications with the PLC unless you have no choice.

1st of all, let's see if you've got a choice.

Before going the OPC route you must let us know what RSLinx license you've got. If you've got RSLinx-Lite you won't be able to use RSLinx to get your data.

The next step is to set up Access VBA to recognize the objects you'll need. You do this by selecting Tools -> References from the Access VBA menu. Select the following references:

1) Rockwell Software OPC Automation
2) Microsoft DAO 3.6 Object Library

#1 Allows you to connect to RSLinx using OPC automation. #2 allows you to reference data from within access.

To make a long story short (I'll have to get you code somehow) you will have to set up a topic in RSLinx. You do this by selecting DDD/OPC -> Topic Configuration... tab within RSLinx. You then point to a PLC and give it a name. You will use this name inside your VBA program as a means of accessing the PLC.

You then have to write a program to set up OPC automation between Access VBA and the PLC. You do this by creating OPC Groups and OPC Items. An OPC group is a bunch of data that you read from a single PLC. An OPC Item is a reference to an address in the PLC.

I'll send you what I've got when I'm back in the office.

Till then.

Good Luck,

(8{)} ( .)
 
Need help in this area as well...

Hello (8{)} ( .),
I am in need of help with this as well. I have the OPC Topic all set up and configured (the easy part). I would like to get me IT guys some help with the access part (VB). If you could get me some sample code that would be awesome. I am hoping to get data to-from Compactlogix 1769-L33ER to Access if at all possible.

Thank you,
djmiller
 
Hi DJ,

So much time has passed and the technology has gotten so much easier to implement. What OPC server are you using?

Thanks and regards,

(8{)} ( .)
 
RSLinx Classic OEM. I really don't want to use DDE, I was hoping to go OPC. If there is another method, I researched Prosoft Modbus TCP/IP, but, I really don't want the cost of purchasing a $2000 per controller in chassis solution. Any help you could provide would be greatly appreciated.

Dan Miller
 
OK. What I would do is check out KepWare's sample code. It should be easy enough to modify for RSLink.

Here's a link.

https://www.kepware.com/en-us/suppo...kepware-support-the-visual-basic-net-develop/

As you can imagine I haven't done this in a while but it really isn't too complicated. You create an OPC object, a group, and a tag. If you have any issues we can contact me and I'll be glad to look at your code.

(8{)} ( .)
(Yosi)
 
Yes Kepware sample code is pretty good, I ported it to Delphi. Also, if your IT Dept have SQL Server as Access is dead in the water I believe.
 
Yes, Access is no longer an option, but, unfortunately our who production system was built onthis platform. I have to work within the confines of what I am given.

Djmiller
 
https://hmisys.com has an OPC server for Logix platforms for $159 US The programmer will also assist via e-mail with any questions to help out.

Have not used the OPC server, but have the PeakHMI communicating to 34 AD Clicks over Modbus TCP/IP and have tested it with CompactLogix - worked very well.

Not a big fan of RS Linx. Many times Linx creates communication problems. Especially when connecting to other devices on the PC.
 

Similar Topics

I want to create a hotlink in Microsoft Access from a remote RSlinx OPC server. Does anybody have sample VBA code to accomplish this?
Replies
1
Views
2,810
OK....I've very recently set up a DH+ Network. I have 1 Machine ran by an A/B 5/04, it's got a Panelview on it, then I have 1 more 5/04 in my...
Replies
4
Views
1,907
I am completing a project that ties an excel spreadsheet to a micrologix through RSLinx. I want to limit the traffic and take advantage of block...
Replies
8
Views
4,877
Hello Everyone, I have a issue with communication between two different PLCs. So here is the facts, The Master PLC is Guard Logix 5069 with IP...
Replies
4
Views
39
i have two plc 1. s7-1212dc/dc/dc ip; 192.168.0.1 2. s7-1500 1513-1pn ip; 192.168.3.2 i need to get data from plc1 to plc2. any idea how to do...
Replies
5
Views
76
Back
Top Bottom