VB Examples in FTView SE

hubb6666

Member
Join Date
Feb 2015
Location
Virginia
Posts
18
Can someone please show me some VB examples that show how to interact with my local FTView display screen. I'm trying to change text in a text box, monitor the state of a button on my local FTView screen, monitor a PLC tag, etc....

I'm using FTView Studio SE (Network Distributed) on Windows 7 PC looking at 150 PLC's via IP addresses

Thanks
 
Last edited:
To change the text on a screen with VBA, on some VBA Event, just set the .Caption property to what you want. The text object must be exposed to VBA through the property panel (Not properties, the property panel when you right click on it).

To monitor the state of a button, expose it to VBA, and create/edit its OnChange event.

To monitor a PLC tag, put a numeric display for it on your display, expose it to VBA, and create/edit its OnChange event.

There are the basics.
 
To change the text on a screen with VBA, on some VBA Event, just set the .Caption property to what you want. The text object must be exposed to VBA through the property panel (Not properties, the property panel when you right click on it).

To monitor the state of a button, expose it to VBA, and create/edit its OnChange event.

To monitor a PLC tag, put a numeric display for it on your display, expose it to VBA, and create/edit its OnChange event.

There are the basics.

I can expose Text objects to VBA Control. As for the buttons I can only select Type Info Extension. Is this correct?

I was able to change text caption by exposing to VBA but not really sure how to create a OnChange event for the buttons.
 
If it is an actual BUTTON (Really, a Windows Button), you can expose it to VBA. If it is an FTVIEW OBJECT (momentary PB, Latched PB, etc) you can only set it to Type Info Extension.

With type info extension, you can change various properties (height, width, visibility, caption, etc), but not have any actual control or trigger events.
 
That would explain it then because all the buttons were done in FTView.

I need to somehow monitor a multi-state (3 State) indicator so when it changes state it would start a timer and display that timer in a text box. When it changes state again the timer would be reset and start timing again. Any ideas on how to do this?
 
That would explain it then because all the buttons were done in FTView.

I need to somehow monitor a multi-state (3 State) indicator so when it changes state it would start a timer and display that timer in a text box. When it changes state again the timer would be reset and start timing again. Any ideas on how to do this?

This doesn't need VBA at all. Keep it simple.

When state changes, that is tied to a PLC bit. Start a timer in the PLC.

Maintain timer and reset in PLC code, and just expose a tag to it.

Maybe add visibility to the .TT (timer timing) bit. No need to do VBA or anything more complicated.
 
This doesn't need VBA at all. Keep it simple.

When state changes, that is tied to a PLC bit. Start a timer in the PLC.

Maintain timer and reset in PLC code, and just expose a tag to it.

Maybe add visibility to the .TT (timer timing) bit. No need to do VBA or anything more complicated.

Strongly agree here.
For one thing, you do NOT want VBA to do any timing. It is highly erratic, and will essentially make your HMI completely unresponsive.
Use VBA for fast routines that you call to do one thing and return.
Do your countdown timer in the PLC.
 

Similar Topics

This week I ran into a customer program that repeatedly used an XIC bit named Off. There was no destructive OTE or OTL setting this bit to...
Replies
55
Views
9,564
Hello, looking for ladder logic examples of the rmp instruction. Any videos out there showing how its done? Specifically looking for speed control...
Replies
1
Views
777
Hi all I am just new to this and relatively new to plc programming, I have been self teaching myself for just over a year now and have done...
Replies
36
Views
9,866
Hello, I have the software and emulate program and I am looking for application examples one by one in order to practice, test them on simulation...
Replies
4
Views
2,639
So basically I want to copy Ladders 10-19 to 20-29, 30-39 etc. All the way up to Lad 180-189 For a total of 18 copies. LAD 10-19 use...
Replies
6
Views
1,920
Back
Top Bottom