3 ms·
Python is a nicer language to use than C or C++ but that is not a very high bar to pass. The main reason VBA is horrible is because it allows dynamic typing by
by dmz73 5y ago
Python is a nicer language to use than C or C++ but that is not a very high bar to pass.
The main reason VBA is horrible is because it allows dynamic typing by default and Python would not help there at all.
VB syntax is actually nicer than Python syntax in at least 3 aspects: 1) VB is not case sensitive 2) VB allows specifying data types 3) VB uses If Then Else End If style syntax that makes it clear where things start and stop.
If Excel actually had the SQL based query interface inside the spreadsheet, it would make most of VBA unnecessary and probably improve the performance of Excel macros by several orders of magnitude.
- dragonwriter 5y ago> VB syntax is actually nicer than Python syntax in at least 3 aspects: 1) VB is not case sensitive VB is not case sensitive, but case insensitivity isn't nice; it reduces clarity and forces circumlocution in cases where having case distinctions would not. > 2) VB allows specifying data types Python allows specifying data types, and the major python typecheckers support a more robust type system than VBA. > 3) VB uses If Then Else End If style syntax that makes it clear where things start and stop Python uses indentation-based syntax that makes it more immediately visually clear where things start and stop with less visible noise.
- Hublium 5y agoI'm not quite sure what my opinion on case sensitivity should be in general, but I feel like it's actually dangerous in dynamically typed languages.
- IshKebab 5y agoI don't know - C++ has a sane static type system, value semantics and isn't ridiculously slow. Also case insensitivity is a terrible idea. Everywhere it is used it causes problems.
- omnicognate 5y agoOn Error Resume Next
- ptx 5y agoCase insensitivity might be fine on a language level, but the mandatory IDE makes it annoying. It tries to normalize the case of identifiers, which would be a nice feature except for the fact that it doesn't know about scopes and can't tell variables from properties. The result is that if you declare a variable named "count" anywhere in your project, every property (and every unrelated variable) everywhere gets renamed from "Count" to "count". Makes for annoying diffs.