Live data from Hacker News

Will VBA Die? (2019)

thespreadsheetguru.com

91–100 of 170 posts

Re: Will VBA Die? (2019)

#92
It's weird to me that we haven't settled on a common, stable, purpose-built high-level language specifically for business logic. Stuff that doesn't change much, that doesn't need to concern itself with the platform, only the business. That code should be portable to whatever shiny new underlying system gets invented; why does it keep having to be re-expressed every few years?

The situation is much better (though still far from ideal) when it comes to data. Everything knows how to use CSVs. Relational databases, from a schematic perspective, really haven't changed terribly much in decades. NoSQL came around but that was really just an alternative option; you don't see everyone scrambling to migrate their SQL data to Mongo. SQL isn't quite a standard, but it would be dramatically easier to migrate an ancient MS SQL database to Postgres than an ancient COBOL codebase to Java.

Re: Will VBA Die? (2019)

#93
post #63

Nah... why should it? It works and it does what it needs to do and more if you decide to hook into the Windows API or Mac’s API. Want to parse 500mb structured XML file? Okay. Takes 3 seconds or so. I had a lot of fun creating a full featured & modern look & feel application using Excel’s VBA runtime as my platform. Sure... I had to create everything from scratch, but learned so much while doing it. Kind of miss it a…

Problem is that VBA in its current shape doesn't work for webbased Excel. Microsoft started with attempting to support Javascript based add-ins [0].

However, they those are of course light years behind in terms of API support. Never even mind that on the desktop Excel the javascript runs in the Internet Explorer engine (of all things, not even the EdgeHTML engine).

[0] https://docs.microsoft.com/en-us/office/dev/add-ins/excel/ex...

Re: Will VBA Die? (2019)

#94
post #52
post #39

Earlier quoted context omitted.

The Excel object model is really a COM/IDispatch object model... it's been accessible from non-VBA applications essentially since the beginning. Not Excel, but one of my first consulting projects was at a company that developed some custom libraries in Java and for a company that used ASP for the front end. The architecture we used ran the Java code in the Microsoft JVM, which then made Java accessible via IDispatch…

At the moment the implementation is to basically inject code, but I imagine eventually Microsoft would like to move away from that. Issues like DCOM and legacy systems would need some interface from Microsoft of course to handle IDispatch, GC etc, but thats what Microsoft do.. And to behonest, as much as I like to rip on them, they do it well. Edit: I think the Java example is a little bit different, but i don't know…

Have a read about Ext-VOS here.

https://blogs.msdn.microsoft.com/dsyme/2012/07/05/more-c-net...

"Project 7 and .NET Generics"

https://fsharp.org/history/hopl-draft-1.pdf

WinRT, as it was originally designed, traces its ideas back to that Ext-VOS project, but going back to COM as they were thinking about it back then.

https://docs.microsoft.com/en-us/uwp/winrt-cref/winrt-type-s...

Re: Will VBA Die? (2019)

#95
post #2

I don't own a Windows computer, but I've seen some incredibly interesting stuff come out of the VBA for Excel, which I sadly never have had a chance to learn. Does anyone here have a side-by-side comparison of the LibreOffice BASIC vs the VBA?

The main difference will be the object models for the various applications. LibreOffice's object model was designed around the expected scripting/automation language - Java. That means that the object model, especially the properties and methods of those objects, is written in a very Java-accented way that would normally feel like foreign vocabulary mixed into a Visual Basic-based dialect. If you're used to that, then the way objects work in VBA (or the very similar Lotusscript) might feel a little bit weird at first, then make more sense than the LibreOffice objects/properties/methods. (Similarly, writing Java against a COM- or OLE-oriented API object model feels awkward, even if you can do all of the same things that you could do with VBA.)

Re: Will VBA Die? (2019)

#96
post #92

It's weird to me that we haven't settled on a common, stable, purpose-built high-level language specifically for business logic. Stuff that doesn't change much, that doesn't need to concern itself with the platform, only the business. That code should be portable to whatever shiny new underlying system gets invented; why does it keep having to be re-expressed every few years? The situation is much better (though stil…

The great thing about standards is that there are so many to pick from.

What is the difference between what you are imagining and Java or python?

Re: Will VBA Die? (2019)

#97
post #92

It's weird to me that we haven't settled on a common, stable, purpose-built high-level language specifically for business logic. Stuff that doesn't change much, that doesn't need to concern itself with the platform, only the business. That code should be portable to whatever shiny new underlying system gets invented; why does it keep having to be re-expressed every few years? The situation is much better (though stil…

The great thing about standards is that there are so many to pick from. What is the difference between what you are imagining and Java or python?

I guess I'm talking about a domain-specific language. Something where you only articulate business processes and formulas, and nothing more. Java and Python are programming languages. You use them to tell a computer what to do. Whereas this would be a representation language. You'd be able to carry that representation around with you and drop it into different programming contexts.

Re: Will VBA Die? (2019)

#98
post #63

Nah... why should it? It works and it does what it needs to do and more if you decide to hook into the Windows API or Mac’s API. Want to parse 500mb structured XML file? Okay. Takes 3 seconds or so. I had a lot of fun creating a full featured & modern look & feel application using Excel’s VBA runtime as my platform. Sure... I had to create everything from scratch, but learned so much while doing it. Kind of miss it a…

A +30K LOC VBA app to maintain is exactly the punishment I expect to get when I'll eventually end up in Hell ;)

Re: Will VBA Die? (2019)

#99

Earlier quoted context omitted.

At some point, I hope we can get past this argument. Learning a new language for rudimentary tasks is not particularly hard. I'm not sure why people decided that JavaScript of all things was what we had to all latch onto.

Because it’s the new Franca lingua of programming. Everyone knows it whether they like it or not. There’s value in not have to switch context while programming. Also there’s typescript which makes JavaScript usable. I don’t like JavaScript either but typescript isn’t terrible and the ecosystem is much bigger than any Microsoft programming ecosystem which results in less reinventions of the wheel. MS has also been tre…

I suspect that we are reaching peak javascript, that wasm will open the browser to all languages and that javascript will compete based on its own merits rather than its historical monopoly.

Re: Will VBA Die? (2019)

#100
I have a soft spot for VBA. Programming macros in Excel was my introduction to programming; it made me realise how simple it can be to automate a repetitive process and save yourself literally hours a day with just a small investment of time.
Post reply on HN