Null means nothing. Its just a literal. Null is the value of reference variable. But empty string is blank.It gives the length=0 .
The main difference between null and empty is that the null is used to refer to nothing while empty is used to refer to a unique string with zero length. A String refers to a sequence of characters. For example, “programming” is a String.
Definition: Null: It is the intentional absence of the value. It is one of the primitive values of JavaScript. Undefined: It means the value does not exist in the compiler.
In JavaScript, undefined is a type, whereas null an object. It means a variable declared, but no value has been assigned a value. Whereas, null in JavaScript is an assignment value.
Is there any difference between @null Vs transparent(#00000000)
in my layout I set android:background"@color/transparent"
but its showing some other different background color that I used.
when I used null its working fine.
I want to set @null thru programmatic.
how to do?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With