partial solution
Thanks so much for the answers, those answers helped me to reach this partial solution i am right now getting the value from the counter (wich is the cycles number) using this code
Dim gApplication As RSLogix500.Application 'Application object
Dim gProject As RSLogix500.LogixProject 'LogixProject object
Dim gDataFiles As RSLogix500.DataFiles 'DataFiles Collection
Dim gDataFile As RSLogix500.DataFile 'DataFile object
Private Sub CommandButton1_Click()
' Set the application object to the object returned by CreateObject.
' CreateObject is simply a method provided by Microsoft that creates
' a new registered COM application instance. In this case we start
' RSLogix 5 by using the "RSLogix5.Application" string.
Set gApplication = CreateObject("RSLogix500.Application")
' At this point, if the CreateObject method functioned properly, the
' gApplication object is now a direct reference to the RSLogix5
' Object Model. Any properties or methods that we invoke on this
' object will immediately take effect in RSLogix.
' Immediately set the visible property of the application to 'True'
gApplication.Visible = True
' Assign the AutoSaveInterval value to 3 minutes
gApplication.AutoSaveInterval = 3
' Assign WindowState prop. to lgxWindowStateMaximized enumeration
gApplication.WindowState = lgxWindowStateMaximized
End Sub
Private Sub CommandButton2_Click()
Dim name As String
' Get the currently open project in the application.
Set gProject = gApplication.GetActiveProject
name = gProject.name
MsgBox (name)
End Sub
Private Sub CommandButton3_Click()
On Error GoTo errorHandler
' Upload a project from the processor using the upload method of the
' application object while ignoring prompts, NOT saving the previous
' file, creating new file from the upload (using lgxUploadCreateNew
' enum (see the objectbrowser for more enumerations)), and go online
' (using the lgxGoOnline enum).
' Set the returned object reference to the gProject object.
'24 • RSLogix Automation Interface Reference Manual
Set gProject = gApplication.Upload(True, False, lgxUploadCreateNew, lgxGoOnline)
Exit Sub
errorHandler:
' Upon a caught error decide what to do.
MsgBox "Error: " & Err.Number & vbCrLf & "Description: " & Err.Description
End Sub
Private Sub CommandButton4_Click()
' Quit the application ignoring prompts and not saving changes.
gApplication.Quit True, False
' Eliminate the reference to the application object
Set gApplication = Nothing
End Sub
Private Sub CommandButton5_Click()
Dim value As String
Set gDataFiles = gProject.DataFiles
value = gDataFiles.GetDataValue("C5:0.acc")
cuentas.Text = value
End Sub
the software that you suggested me is an amazing one i downloaded it and i have it right know working (i did a display showing some plc info) this is great and easy!!!!!!!!!!!