Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What operator is <> in VBA

Tags:

I was studying some vba code and came across this:

If DblBalance <> 0 Then 

I can't figure out what operator this is, any help would be appreciated.

like image 305
vini Avatar asked Oct 21 '12 12:10

vini


People also ask

What are operators in VBA?

An operator is a code element that performs an operation on one or more code elements that hold values. Value elements include variables, constants, literals, properties, returns from Function and Operator procedures, and expressions.

How do you say not equal to in VBA?

For example, “NOT EQUAL” in VBA represents the combination of greater than and less than symbols. If both these operators are combined, then it becomes not equal, i.e., “<>. “

Is there a += operator in VBA?

No, it doesn't exist in VBA.


2 Answers

It is the "not equal" operator, i.e. the equivalent of != in pretty much every other language.

like image 170
ThiefMaster Avatar answered Nov 07 '22 06:11

ThiefMaster


Not Equal To


Before C came along and popularized !=, languages tended to use <> for not equal to.

At least, the various dialects of Basic did, and they predate C.

An even older and more unusual case is Fortran, which uses .NE., as in X .NE. Y.

like image 21
DigitalRoss Avatar answered Nov 07 '22 05:11

DigitalRoss