It must be done this way.
Params.Get("GUIX") may return a string (empty or not) or nothing (Null) if it has not been found.
Before comparing an object, you need to make certain that it is not NULL, otherwise you will get an error.
Also, the "if" condition is evaluated from left to right. So, if the first condition fails, it will not evaluate the second.
(In other languages as C, the first comparison would be made to the pointer holding the object. If it is not Null, proceed with checking the content. )