VBA Code Controlling PLC Tags in Studio 5000 Through FactoryTalk View Studio Site Edition
Using VBA code in FactoryTalk View Studio to control PLC tags in Studio 5000. This video is just an example of a best practice to get VBA to communicate to a PLC processor but is not limited to just this one example.
Treat this video as an eye-opener of many different applications that you could use this technique.
Private Sub VBACodeTrigger_Change()
On Error GoTo ErrorHandler
If Not IsError(VBACodeTrigger.Value) Then
If VBACodeTrigger.Value = 1 Then
ExecuteCommand "VBAmacro"
End If
End If
Exit Sub
ErrorHandler:
LogDiagnosticsMessage Err.Description, FTDiagSeverityError
End Sub
0:00 Example of VBA controlling PLC tags
1:00 HMI memory tag for VBA control
1:50 Adding a numeric display
2:25 Reason we change the name of the numeric display
2:50 Expose To VBA to VBA Control
3:40 Adding an HMI button
4:05 Using the &Set feature in button
5:05 Ladder Logic Seal In Circuit For Testing
7:11 Setting up FactoryTalk Linx shortcuts for HMI communications
7:59 Making a Macro in FactoryTalk View Studio
9:36 Opening VBA Code
10:25 Writing the VBA Code
14:46 Adding a second macro
16:45 Testing the VBA code
17:36 Creating an HMI Client for testing
19:05 VBA Code Testing through the HMI Client
20:30 Recommended videos for you
I hope it helped.
Thank you for watching the video.
Learn, Implement, Succeed
Visit:
https://www.allen-bradley-plc-training.com/
Other social media:
LinkedIn: https://www.linkedin.com/in/shane-welcher-sr/
Facebook: https://www.facebook.com/OnlinePLCSupport
#VBAcode #ExposeToVBA #VBAcontrol #FactoryTalk
-
5:21
Shane Welcher
10 months ago $0.02 earnedRockwell Automation's Studio 5000 V30 Servo Motion Group Not Synced
16 -
6:13
Shane Welcher
3 years agoHMI Server Status VBA Code In FactoryTalk View Studio Site Edition
19 -
13:50
Shane Welcher
2 years agoFactoryTalk Site Edition VBA Code for an External HTML Web Page
35 -
14:14
Shane Welcher
2 years ago $0.01 earnedFactoryTalk Site Edition Microsoft Web Browser ActiveX with VBA Code Tutorial
50 -
11:53
Shane Welcher
3 years agoStarting a FactoryTalk View Studio Site Edition HMI Application | Batching Station PLC | Day 4
73 -
19:39
Shane Welcher
2 years agoLegacy HMI Tag Alarms FactoryTalk Site Edition | Legacy HMI Alarms
24 -
9:59
Shane Welcher
2 years agoController Scope Tags vs Program Scope Tags in Studio 5000
57 -
18:27
Shane Welcher
3 years ago $0.01 earnedRSLogix 5000 Programming | Machine Simulator Palletizer Using Studio 5000 Through RSlinx OPC
12 -
11:09
Shane Welcher
2 years agoConnecting Studio 5000 Logix Emulate to a PLC Program
26 -
0:57
mikeybonez18
2 years agoStudio sesh
17