Page 1 of 1

VBScript not assigning values.

Posted: Wed Dec 19, 2018 2:27 pm
by Dr.Phlox
Good afternoon!

I'm having a rather peculiar problem:

I'm using a VBScript to switch between German and French text on my label. I used the exact same Code on a different Label, I just renamed some Data Source variables. It works perfectly fine there.
For that I'm using multiple variables, this is what the code approximately looks like:

Code: Select all

Dim DescrDE 
Dim DescrFR 
Dim QtyDE 
Dim QtyFR 
Dim ColorDE 
Dim ColorFR 
Dim ArtNoDE
Dim ArtNoFR 
Dim ColorWertDE 
Dim ColorWertFR

LANG = [Language]
QtyDE = "Menge"
QtyFR = "Quantité"
ColorDE = "Farbe"
ColorFR = "Couleur"
ArtNoDE = "Artikelnummer"
ArtNoFR = "Numéro d'article"

If LANG = "DE" Then
[Beschreibung] = DescrDE
[AnzahlLabel] = QtyDE
[FarbeLabel] = ColorDE
[ArtikelnummerLabel] = ArtNoDE
[Farbe] = ColorWertDE

[Beschreibung] = DescrFR
[AnzahlLabel] = QtyFR
[FarbeLabel] = ColorFR
[ArtikelnummerLabel] = ArtNoFR
[Farbe] = ColorWertFR
End If
Now, the values I assign are shown in the Designers Preview:


However, as soon as I switch to printing, the values are no longer shown. If I tick the box "Value Required", I get an error that it's empty.


What I have tried so far:
  • Check if they're Phantoms
  • Check if their visibility is depending on another variable
  • If another variable interferes
  • If my SQL is interfering
  • If my Syntax is correct
I'm at a loss at this point, I have been hunting for an error for the past 3 hours and had 2 other coworkers check my work and nobody can find a mistake. ](*,)

I hope somebody here can help me!

Re: VBScript not assigning values.

Posted: Wed Dec 19, 2018 4:46 pm
by Kyleodonnell

We recommend opening a support case with the support team as the team will need all of your files to test your solution.

Re: VBScript not assigning values.

Posted: Thu Dec 20, 2018 8:25 am
by Dr.Phlox
Nevermind, I forgot to drag the function on to the Label. That was the rpoblem.