what is differeence between i.equal(j) and i=j in vb.net?
-
what is differeence between i.equal(j) and i=j in vb.net.
-
what is differeence between i.equal(j) and i=j in vb.net.
sathyan_8294 wrote:
what is differeence between i.equal(j) and i=j in vb.net.
What's
equal
?:confused: Do you intendObject.Equals()
, don't you?If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
-
sathyan_8294 wrote:
what is differeence between i.equal(j) and i=j in vb.net.
What's
equal
?:confused: Do you intendObject.Equals()
, don't you?If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
we r using variables?
-
we r using variables?
-
How have you declared
i
andj
???If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
CPallini wrote:
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
"There is a theory which states that if ever anyone discovers exactly what the Universe is for and why it is here, it will instantly disappear and be replaced by something even more bizarre and inexplicable. There is another theory which states that this has already happened." - The Guide.
Upcoming Scottish Developers events: * Glasgow: Tell us what you want to see in 2007 My: Website | Blog | Photos
-
what is differeence between i.equal(j) and i=j in vb.net.
It could be that it was placed in the framework so it would be more familiar to developers who are coming from the Java programming language. In Java, the == boolean expression returns true if two strings share the same memory address and false if the two memory addresses are different. The .equals method in Java would properly determine whether each of the memory addresses contain the same information. For VB and VC# I would imagine that the == and .equals (or in VB's case: = and .equals) should have the same purpose, but this is just a guess as neither of the languages really use pointers.
Regards, Thomas Stockwell Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning. Visit my homepage Oracle Studios[^]
-
what is differeence between i.equal(j) and i=j in vb.net.
That depends very much on the data types of the variables. The Equals method of the i variable is called with whatever data the j variable contains, while the behaviour of the = operator depends on the data types. If the data types are the same or can easily be converted to the same type, the = operator method for that data types is used, which usually does the same as the Equals method. Otherwise a huge method (hundreds of lines of code) in the Microsoft.VisualBasic library is called, that determines how the values can be compared and how it should be done.
--- Year happy = new Year(2007);
-
what is differeence between i.equal(j) and i=j in vb.net.
.equals is for comparing things other than numbers or words, like controls. if textboxTMP.equals(textboxName) kind of thing, if you're working with say, forms or addressbooks and you need to have some sort of checking rather than a loop or select for each control. Personally, I don't use it, so I can't think of a useful instance, though I'm sure there are a few. Daniel