View Single Post
 
Old 12-27-2017, 07:30 PM
Logit Logit is offline Windows 10 Office 2007
Expert
 
Join Date: Jan 2017
Posts: 591
Logit is a jewel in the roughLogit is a jewel in the roughLogit is a jewel in the roughLogit is a jewel in the rough
Default

.
"Is there an advantage to it ? "

I can't answer that question ... I'm not an expert programmer. It's a hobby that I take seriously. (Is that bad ?)

One advantage I understand is :

If you have code that basically says, "Range("A1"A12").Value = "XYZ", then the logic to that is Range("A1"A12").Value ALWAYS must equal "XYZ" for the remainder of the line of code to work correctly.

Now, if you use, "If Not Range("A1:A12").Value is Nothing Then" ... The Values in the stated range can be anything. The code has not restricted the value to always be XYZ in order for it to work.

I'm retired now but I still recall being in High School Algebra and wondering how that gobble-d-goop was ever going to be useful. It wasn't until I began hobby programming that I finally understood a use for variables, less than, greater than, equals, double negatives, etc. etc.

Most of the time I'm still as confused as I was 50 years ago !
Reply With Quote