Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » Elevate Web Builder Technical Support » Support Forums » Elevate Web Builder General » View Thread |
Messages 1 to 2 of 2 total |
Detecting a null string |
Mon, Dec 12 2016 10:49 AM | Permanent Link |
Matthew Jones | Way back in 2013, in EWB v1, you could detect a null value for a string with a compare against nil.
http://www.elevatesoft.com/forums?action=view&category=ewb&id=ewb_general&page=1&msg=2200#2200 This no longer works. When I use GetProperty on a field that doesn't exist, the result value is null in this case. I put in an "if assigned(mystring) then" to use another method, but this then doesn't discriminate between null and an empty string. How can I know it is null? (If anyone else has this, the particular workaround is to use PropertyType() to check it exists, but the general question still exists given that external interfaces could return null...) -- Matthew Jones |
Wed, Dec 14 2016 3:06 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Matthew,
<< This no longer works. When I use GetProperty on a field that doesn't exist, >> Don't do that. GetProperty is only intended to be used in cases where the property actually exists, thus avoiding any "undefined" issues, etc. It's isn't intended to be a full-on replacement for hash key-value access to the underlying JS object properties. Tim Young Elevate Software www.elevatesoft.com |
This web page was last updated on Thursday, October 10, 2024 at 02:11 PM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |