Your Universal Remote Control Center
RemoteCentral.com
Philips Pronto Professional Forum - View Post
Up level
Up level
The following page was printed from RemoteCentral.com:

Login:
Pass:
 
 

Original thread:
Post 2 made on Wednesday March 20, 2024 at 19:02
Lyndel McGee
RC Moderator
Joined:
Posts:
August 2001
12,999
Your statement that you had to use === makes no sense. Something else in your code must be wrong.

System.getGlobal 'Purpose' from DEV Guide

Retrieve a string value stored in the global variables list.

Return
String
The value of the global variable, or null if the name is not found.

In your case, either the value returned was null or maybe had some extra characters on it.

null == 'hello' => false
null === 'hello' => false

The double equal does type coercion and null and a string are not the same.

Sounds like the first time you did this, maybe the global was not set prior to your executing the script but sometime after, it was.
Lyndel McGee
Philips Pronto Addict/Beta Tester


Hosting Services by ipHouse