Building SQL strings in Access/VBA
Occasionally, I have had to build a SQL string in VBA and execute it with Docmd.RunSql(). I have always built these strings by concatenating…
81 expert-verified Q&A posts in this category, sourced from the top-voted answers on Stack Overflow.
Occasionally, I have had to build a SQL string in VBA and execute it with Docmd.RunSql(). I have always built these strings by concatenating…
Examples: 'DD/MM/YYYY "1/1/2009" should give `1` "31/1/2009" should give `5` "1/2/2009" should also give `5` Format("1/2/2009", "ww") returns 6. So, how can I get…
My manager tells me that there is a way to evaluate names that are spelled differently but sound similar in the way they are…
I am wrapping up an office application (VBA) that makes a call to a C# console application to perform some of the heavy lifting…
Usually I use this piece of code to retrieve the content of a folder in VBA. But this doesn't work in the case of…
About a year ago, a manager in another department brainstormed that I could code up some VBA to auto call me in the event…
What is the difference between the two. I always thought VBA is somewhat 'crippled' version of VB, but when a friend asked me the…
I am looking for some information or code samples for the Environ Function in VBA to grab the username on the current system.
I'm creating buttons dynamically on an Excel userform with the following code: With Me.CurrentFrame.Controls.Add("Forms.CommandButton.1") .Caption = "XYZ" .name = "AButton"…
This declaration causes an overflow in VBA: Const OVERFLOWS As Long = 10 * 60 * 60 whereas setting the value directly is fine:…