VBA

5K

Solutions

15

Articles & Videos

2K

Contributors

Visual Basic for Applications (VBA) enables building user-defined functions (UDFs), automating processes and accessing Windows API and other low-level functionality through dynamic-link libraries (DLLs). VBA is closely related to Visual Basic and uses the Visual Basic Runtime Library, but it can normally only run code within a host application rather than as a standalone program. It can, however, be used to control one application from another via OLE Automation. VBA is built into most Microsoft Office applications.

Refine results

This has gotta be easy, but the solution is escaping me for the moment. I want to set the selected values of a multiselect listbox by the value of the bound column. I know how to set by row number:

60 views
Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

There is often more than one way to accomplish a particular coding task and one of the criteria that can be used to determine which method to use is to determine which one is the fastest.  But how do …

25,340 views
Eggs in one array

You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes a way to elegantly solve the problem.

21,234 views
Oh no

This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.

92,943 views

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to …

05,722 views

Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.
 What are they?
An Enum is just a type of variable like a string or an Integer, b…

114,899 views

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate be…

24,257 views

Dear Experts:

for the selected cells in a column (contiguous range) I would like to perform the following VBA Action.

If the macro hits a cell (of this selected range) which starts with a numbe…

210 views

Dear Experts:

I got thousands of records where I have to concatenate two cells as follows

The Formula in D5 is as follows:
IF(C5="";"";C5&"_"&MOD($E$4;1;3))

Copying it down all the way does…

314 views

Hi Experts,

Wondering if there is a way to have a button in my app that does the following.

Makes a copy of the current file, then saves that file as an executable (ADE in my case), or perhaps t…

1134 views
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

I had this question after viewing Status Change (https://www.experts-exchange.com/questions/28978792/Status-Change.html).

Hi Experts,
Need A help with piece of code ...please help me.
in attached…

1328 views

I can copy entire cells like this - values, formats, everything.

(CODE)

I want to copy only the Formats, Conditional Formats. How do I amend the above please?

Thanks

Edit: I want to avoid …

717 views

I see that {Numlock} toggles the Number lock.

I'm looking for a reliable way to ensure that, after my Sendkeys {Down} which sometimes leaves Number Lock state as 'off', to ensure that it is returne…

428 views

I have a cell which gets a DataValidation list when a button is clicked. See attached.

I'd like to make the List dropdown end up opened after the DataValidation is created in the cell. I understand…

619 views

I've got an application running in an old version of Access (have to leave it there because of the toolbars), which I've been using pdf995 to print invoices.
The trouble is, the pdf995 runs async and…

2128 views

Problem
My macro creates formulas to be displayed in word, so I don't want unnecessary brackets. The formula obtained from an excel cell will be multiplied by a factor, so a bracket will be necessary…

218 views

Using an instance of the outlook namespace I can use the CreateItem to create and manipulate a new email message, leaving it available for the user to add text or other things at will then send it.

1019 views

I am using VBA in Access 2010.

I am trying to show the results of a query in a list box.  I am putting the data into a recordset and then using a function to put it into the list box.  I have used …

415 views

I need a function where I can give a range such as A2:D2
and have it combine them the text values.
I would also like an option to add a divider.

313 views
What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

I had this question after viewing Status Change (https://www.experts-exchange.com/questions/28978792/Status-Change.html).

Hi Experts,

This Same kind of question like my previous question ...need…

329 views

I want to re-use an ADO recordset (same object variable to reference it, same Active Connection, Locktype, and cursortype properties, etc.)  I just want to change the source.  Can the source of an ADO…

417 views

Hi,

I have data in columns A to columns I, what I am trying to achieve is to run some VBA coding which will remove any duplicates rows so only the one unique line remains, so for example if there a…

311 views

Is there a fast/clean way of determining the field type (directly from the form)?  I have a function that creates a shortcut menu when a control gets focus (pretty much every field/control on the form…

411 views

How can I export my query to a text file automatically lets say 3 times a day at specific times or timing intervals. Every 8 hours. Would this be with the DoCmd.TransferText? I am unfamiliar with this…

421 views

I have list of data and want to know how to process data the way I want it?
Please have a look at file, there is a sample output.

216 views
Show more content
201506-LO-Top-001

TOP EXPERTS

view all

RELATED TOPICS view all topics

  1. MS Excel
    (128,567)
  2. MS Access
    (215,524)
  3. Visual Basic Classic
    (163,556)
  4. VB Script
    (36,269)
  5. MS Office
    (57,065)
  6. MS Applications
    (43,147)
  7. MS Word
    (26,941)
  8. Outlook
    (94,455)
  9. Programming
    (51,874)
  10. Spreadsheets
    (5,982)