Field type error
-
- Posts: 2
- Joined: Tue Sep 08, 2015
Hi,
In my SHarePoint list the field type is number - when I open the feild type in the plumsail Form desinger is says it has a field type of text - so when I try and Java script do a numeric calucluation it appends the number - 3+ 3 = 33 instead of 6 - what am I doing wrong?
In my SHarePoint list the field type is number - when I open the feild type in the plumsail Form desinger is says it has a field type of text - so when I try and Java script do a numeric calucluation it appends the number - 3+ 3 = 33 instead of 6 - what am I doing wrong?
I guess you're trying to concatenate two strings, as fd.field().value() returns textual representation of a field. You can use parseFloat() function to parse your string, like this:
this would return 40.3.
If you only need to add whole numbers you can use parseInt() the same way.
Code: Select all
parseFloat('30.3') + parseFloat('10');
If you only need to add whole numbers you can use parseInt() the same way.
-
- Posts: 2
- Joined: Tue Sep 08, 2015
Thanks so Much that fixed it for me!
Cheers!
-Victoria
Cheers!
-Victoria
-
- Information
-
Who is online
Users browsing this forum: No registered users and 6 guests