Showing results 1 to 3 of 3

Thread: adjustzenonvalue

  1. #1
    Join Date
    29.09.2011
    Posts
    1

    Default adjustzenonvalue

    Hi,

    I'd like to ask if you could give me a sample of how to program the adjustzenonvalue macro?I'm not that familiar with VBA but I'd like to use it for one of our projects.

    thanks

  2. #2
    Join Date
    11.06.2013
    Posts
    32

    Default Re: adjustzenonvalue

    Hi figuerra!

    Iím not sure, if I could understand your question correctly. But maybe the following link could help you.


    Best whishes

  3. #3
    Join Date
    28.06.2013
    Posts
    21

    Default AW: adjustzenonvalue

    Quote Originally Posted by figuerra View Post
    Hi,

    I'd like to ask if you could give me a sample of how to program the adjustzenonvalue macro?I'm not that familiar with VBA but I'd like to use it for one of our projects.

    thanks
    Hello,

    you have to create the AdJustZenOnValue with your Macorlist.


    Heres an example for the Macro:

    Public Function AdjustZenOnValue_BCD(obVar As Variable, vValue As Variant) As Double
    On Error Resume Next
    Dim W As Variant
    
    'Diese Function wandelt z.B. einen Sollwert in den BCD Code um,
    'damit dieser korrekt in die Steuerung abgesetzt werden kann
        W = vValue
        AdjustZenOnValue_BCD = W / 10
    End Function

    Put this non-linear value adjustment on your Variable you want to edit.
    On each Change the value of the variable this Macro will activate.

    For example your PLC gets the value 10 you divide this value by 10 and your variable has the value 1.

Posting Rules

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