Skip to main content
Matilda_Miglio
Level 2
April 16, 2018
Resuelto

First Name Email Script Token

  • April 16, 2018
  • 6 respuestas
  • 4388 visualizaciones

Hi there,

I was referencing this thread: Conditional First Name Token

#if (${lead.FirstName} == "[Not Provided]")

there

#else

${lead.FirstName},

#end

I have built the above but am struggling to pull in a value. We have leads that have a first name of [Not Provided], and we'd like to say if we identify the first name as such, fill in "there" as the value, if not identified as [Not Provided] use the value that lives in the field.

Este tema ha sido cerrado para respuestas.
Mejor respuesta de SanfordWhiteman

The code looks fine, though you don't need the curly braces and I recommend removing them (see Velocity ${formal.notation} invites syntax errors: use it wisely).

  • Do you have First Name checked off in the tree on the right-hand-side of Script Editor?
  • What do you see if you simply output $lead.FirstName?
  • Are you sure the case matches on both sides?
  • Are you testing with a real email, not Send Sample?

6 respuestas

Josh_Hill13
Level 10
April 16, 2018

@Sanford Whiteman​

SanfordWhiteman
Level 10
April 16, 2018

The code looks fine, though you don't need the curly braces and I recommend removing them (see Velocity ${formal.notation} invites syntax errors: use it wisely).

  • Do you have First Name checked off in the tree on the right-hand-side of Script Editor?
  • What do you see if you simply output $lead.FirstName?
  • Are you sure the case matches on both sides?
  • Are you testing with a real email, not Send Sample?
Matilda_Miglio
Level 2
April 16, 2018

Removed the curly brackets and it worked!

Thank you!