How is the detail of the faceplate configured?

Hello everyone,

I wanted to add a new tab in the detail of the facplate, but looking at the animation and the configuration of the detail of the faceplate, I can not understand how it works.

I looked in the animation and in the script of the detail of the faceplate but without any result, I can not understand how the TabMain changes in run mode with this tab.

Is someone has already worked on a detail of facplate and that he made such a change?

An example of the detail of the faceplate that I want to modify it:

Run Mode:

Edit mode: 

Detail of the configuration:

Script of TabMain:

All Script of Detail Faceplate:

Script.txt

  • My understanding of how this works is as follows.

    The visible tabs are a Microsoft Forms TabStrip control. In DeltaV Configure VBA (assuming you have a reference to the Microsoft Forms library) select help for Visual Basic then look in the Microsoft Forms Reference to see full details.

    A brief summary is that the TabStrip is a collection of Tab objects representing each tab. In run mode, the TabStrip has a Value property which indicates which tab is selected. This value is used to control the visibility of a group of objects that appear on that tab. If you look at the animations for eg grpInterlocks you should see a Visibility animation controlled by the value of the TabStrip in your case called TabMain.

    In Design mode you only see two tabs. This is the default(?) number. The other tabs are added programmatically when the faceplate is opened by procedures DiscreteTabInit and DiscreteAlarmTabInit.

    So to use the 'unused' tab you need to find out the TabStrip value for this tab and create a group of objects whose visibility is true for this value. The TabMain_Change procedure limits the value of the TabStrip to less than iTabNo-1 so you might need to look at the code that sets iTabNo. You would also need to look at DiscreteTabInit and DiscreteAlarmTabInit and enter code to set the caption of the tab you want to use.

    Hope this helps
  • In reply to Cedric Dawnhawk:

    Thanks Cedric for your reply, yes you are right.

    The "DiscreteTabInit and DiscreteAlarmTabInit" function will initialize the tabstrip of a discrete control. The value of "iTabNo" to display and indicates which tab is selected.

    If iTabNo = 0 Then

               objTabstrip.Tabs(0).Name = "Page1"

               objTabstrip.Tabs(0).Caption = sResString(952)

           Else

               If iTabNo = 1 Then

                   objTabstrip.Tabs(1).Name = "Page2"

                   objTabstrip.Tabs(1).Caption = sResString(952)

               Else

                   objTabstrip.Tabs.Add "Page" & Str(iTabNo + 1), sResString(952)

               End If

           End If

    After, the tab display depends on "sResString(xxx)", we could find all the configuration of this parameter in a file called "D:\DeltaV\DVData\Graphics-iFix\Pic\Standard\ResourceFile.txt".

    ;Detail Display Common Text

    ;==========================

    944  FORÇAGE SP

    945  VARIABLE

    946  E/S

    947  ALARMES

    948  DIAGNOSTICS

    949  MODULE CIBLE

    950  LIMITES

    951  ETAT

    952  INTERVERROUILLAGES

    953  TEMPS DE MARCHE

    954  ALARMES/LIMITES

    955  REGLAGE

    In VBA, the function to load String from resource file is configured in "Project_SIGlobs / Modules / modMiscellaneous" Code.

    For example, it means that sResString(952)  represent "INTERVERROUILLAGES".