vb2005 and RSLinx OPC

traihanoi

Member
Join Date
Aug 2006
Location
Hanoi
Posts
3
My system: SLC503 => 1747 PIC => PC
PC : RSLinx + SCADA VB2005
I have a problem when using RSlinx OPC in VB2005
=========================
Public Class frmMain
'Khai bao OPC
Public MyRsLinxOPCServer As RsiOPCAuto_OPCServer
Public WithEvents MyRSLinxOPCGroup As RsiOPCAuto_OPCGroup
Public LinxItem1 As RsiOPCAuto_OPCItem
Public LinxItem2 As RsiOPCAuto_OPCItem

Private Sub initialOPC()
'Dim TransID As Int64
'Dim CancelID As Int64
'Dim i As Integer
'Create Server
MyRsLinxOPCServer = New RsiOPCAuto_OPCServer
'Connect to Server
MyRsLinxOPCServer.Connect("RSLinx OPC Server")
'Add Group to Server, Group name can be anything you want it to be
MyRSLinxOPCGroup = MyRsLinxOPCServer.OPCGroups.Add("TEST")
'Set Group Active for Data Updates and Events
MyRSLinxOPCGroup.IsActive = True
'Group Update Rate
MyRSLinxOPCGroup.UpdateRate = 10
MyRSLinxOPCGroup.IsSubscribed = True
''''''''''
'Add Items to Group, the specifier on the end Needs to be Unique for each Tag
LinxItem1 = MyRSLinxOPCGroup.OPCItems.AddItem("[MM4inchs]F17:0", 1)
LinxItem2 = MyRSLinxOPCGroup.OPCItems.AddItem("[MM4inchs]F17:4", 2)
End Sub
Private Sub frmMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Base.Load
initialOPC()
End Sub
End Class
................................
Help me !!!! Thanks verry much
 
Last edited:
Make sure that you have the correct version of RSLinx (anything other than RSLinx Lite?). If the menu bar has an item option 'DDE/OPC' then you have a suitable version.

Click on 'DDE/OPC' & make sure that the topic 'MM4inches' exists in the topic list. If not add it & set the correct data source & data collection etc.
 
How about answering some questions...

What version of RSLinx are you using? Does it support OPC?

If you are using a version of RSLinx that supports OPC, does the topic 'MM4inches' appear in the topic list?

What is the error (in detail) that Visual Studio is generating?

If you cannot be bothered to provide any details of the exact nature of YOUR problem, I think that you will find that there will be few people willing to help you.
 

Similar Topics

Hi, I am working on a project, where I face a issue with respected to Network Dropout. The PLC is connected to a 16 port unmanaged switch, where...
Replies
7
Views
179
Does Rockwell still offer reset codes for old school Master Disk floppy's? In a bind and need to reset the activation disk soon and to be pointed...
Replies
9
Views
229
Anyone have issues with RSLinx being very slow to open. It sometimes will say "Checking Activation" at the bottom for what seems like an...
Replies
2
Views
141
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
82
Hey All, I am sorry to ask this, but i still gotta do it. What happens if I close RS linx? Will it cause network interruption and PLCs will lose...
Replies
5
Views
152
Back
Top Bottom