Zum Hauptinhalt gehen

Suche

Suche

Vb Script For Conditional Expression

Kommentare

3 Kommentare

  • Avatar
    Legacy Poster

    Update

     

    The below seem to work but how do I append a string ('g' or 'kg') to the end of the values?

     

    If Field("weightPerRecipeUnit")>= 1000 Then

    value = Field("weightPerRecipeUnit")/1000

    Else

    value = Round(Field("weightPerRecipeUnit"))

    End If

     

    Thanks,

     

    Andrew

     

    0
  • Avatar
    Legacy Poster

    Try:

     

    Value = (Field"weightPerRecipeUnit")/1000) & "Kg"

     

    And:

     

    Value = Round(Field("weightPerRecipeUnit")) & "g"

    0
  • Avatar
    Legacy Poster

    Many thanks KM. Works as required.

    0

Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.