Hi,
Looking to join the values of two fields :
Both fields are Text fields but it wont let me build the code:
field1 + “/111/” + field2 +“/”
This doesn’t work…anyone have any ideas?
Thanks
Hi,
Looking to join the values of two fields :
Both fields are Text fields but it wont let me build the code:
field1 + “/111/” + field2 +“/”
This doesn’t work…anyone have any ideas?
Thanks
Subject: Join two field values
Is this formula language or script? Please explain a bit further.
Subject: RE: Join two field values
I am trying this formula in two places (has to be formula language) :
In a computed field on a form
In a view column
It seems like its trying to add the numbers together but I thought the + sign could be used to concatenate field values.
They are Text fields but are storing numbers
Thanks
Subject: RE: Join two field values
Hi,
this is weird. The code works correctly for me.
Tried to use local variables and the @Text-operator?
_tmpField1 := @Text( field1 );
_tmpSep := @Text( “/111/” );
_tmpField2 := @Text( field2 );
_tmpFin := @Text( “/” );
_erg := _tmpField1 + _tmpSep + _Field2 + _tmpFin;
_erg
Has the advantage you can print e.g. _tmpField1 easily instead of _erg (makes debugging easier)
Hope this helps,
Martin
Subject: Join two field values
It depends if the fields are defined as text or number,
If the are defined as numbers, You could try:
@Text(field1) + “/111/” + @Text(field2) +“/”
or
@Text(field1) & “/111/” & @Text(field2) & “/”
Subject: Thanks
Thats working a treat. I am using Martin’s code :
_tmpField1 := @Text(field1);
_tmpSep := @Text( “/111/” );
_tmpField2 := @Text(field2);
_tmpFin := @Text( “/” );
_erg := _tmpField1 + _tmpSep + _tmpField2 + _tmpFin;
_erg
I think it was because it was imported as a number from Excel…It may have got into a muddle somehow.
Thanks for all the help.
WPL