Showing results 1 to 3 of 3

Thread: Combi-Element per VBA anpassen

  1. #1
    niclasfl Gast

    Default Combi-Element per VBA anpassen

    Hallo,

    kurze Frage ist es möglich Werte eines Combi-Elements im Bereich Konfiguration u. Test Mode per VBA zu ändern, konkret geht es um die Hintergrundfarbe des Defaultzustandes.
    Last edited by niclasfl : 4th August 2012 at 10:43

  2. #2

    Default Re: Combi-Element per VBA anpassen

    Hallo,

    Hier ein kleines Beispiel wie die Hintergrundfarbe vom Defaultzustand geändert werden kann.

    Sub combi_change()
    Dim myScr As DynPicture
    Set myScr = MyWorkspace.ActiveDocument.DynPictures.Item("Start")
    If Not myScr Is Nothing Then
        Dim myElem As Element
        Set myElem = myScr.Elements.Item("combi")
        On Error Resume Next
        If Not myElem Is Nothing Then
            'printout the total number of states
            Debug.Print myElem.DynProperties("States[-1]")
            'state 0 is the default state, set the background color
            myElem.DynProperties("States[0].BkColor") = 12121212
        End If
        myScr.Save
    End If
    End Sub

  3. #3
    niclasfl Gast

    Default Re: Combi-Element per VBA anpassen

    Hi,

    Vielen Dank für die schnelle Hilfe habe es heute ausprobiert,
    funktioniert super gut u. erspart sehr viel Zeit.

Similar Threads

  1. Combi Element Test Mode Issue
    By stolyarov_as in forum zenon Supervisor
    Replies: 2
    Last Post: 24th March 2014, 12:20
  2. Checking if a combi-element is locked
    By ptk_mzeh in forum VSTA
    Replies: 1
    Last Post: 11th September 2012, 09:59
  3. Nested Structured Data Type in Combi Element
    By ansab.tp in forum zenon Supervisor
    Replies: 2
    Last Post: 21st March 2012, 07:38
  4. Combi Element
    By hoscillada in forum zenon Supervisor
    Replies: 4
    Last Post: 16th December 2009, 22:51
  5. Replies: 1
    Last Post: 14th December 2009, 03:23

Posting Rules

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •