Category "vba"

Determine if an Outlook event is a meeting and what the response was

I'm trying to write a macro in Excel that will look through my Outlook calendar, grab all the events, and display the following information: subject, start time

Macro to resize all text boxes in a powerpoint presentation

I exported a PDF as a powerpoint presentation. The PDF had A4 pages, while the powerpoint has wide slides (16:9), and the text has ended up being centered in th

Excel 2010 VBA ActiveChart.SetSourceData Failed

I have a Excel VBA application which has been working fine in Excel 2003 but failed in Excel 2010. The relative codes are Public Sub Create_Chart Dim c

VBA ListBox RemoveItem Unspecified Error

When I try to call remove item on my listbox, I get '-2147467259 (80004005)' unspecified error. My rowsource property is blank. I add the items originally thr

What are all the properties that I can assign to "with Outlook" with VBA?

In VBA we can create an object to run and manipulate other applications. I am trying to do a few jobs in Outlook with code in Excel. Eg - With OutMail .Su

Make copy-paste code, triggered by button at different locations, faster

I made a model for our project managers to follow the economy in different projects. A wish for the model was the option to add rows into the matrix I made with

Script to Download xls files embeded in a .msg file

There are 1000s of .MSG files on my d drive and each containe an XLS file,as attachemnt. Is there any way to download these xls files from these .msg file usin

Replace cell value with image

I have an Excel file with a table containing values O and G. I want to replace O with an orange icon and G with a green icon How do I read each cell for value O

Outlook 2010 GAL with Excel VBA

I have the following code to get contacts out of Outlook from Excel: Public Sub GetGAL() Dim olApp As Outlook.Application Dim olNs As Outlook.Namespace Dim ol

VBA - worksheet object is hidden

I have a very simple yet seemingly unsolvable problem: I would like to copy a range of data from a worksheet to another. This is what I made up: Sub CopyProject

How can I use a for each loop on an array?

I have an array of Strings: Dim sArray(4) as String I am going through each String in the array: for each element in sarray do_something(element) next ele

Fetch data from website table using vba

I need to constantly update excel file with information, obtained from the following link (warning, ukrainian language): link to the Ministry of Finance web-sit

If IsEmpty then go to column A but in same row and extract that data

I am creating a spreadsheet which has many columns and I am trying to make it check if a cell in a certain column is empty then it will check to see the cells i

Delete a mailitem permanently in outlook

I'm trying to delete a mailitem using the outlook API. Like the following, Dim objMail For each objMail in objFolder.Items objMail.Delete Next Obviously, del

How to stop scroll bar auto jump in vba

I have a userform with a frame (Frame1) consisting a vertical scroll bar of height set to 1000 , the Frame houses 160 textboxes arranged in 40 rows and 4 column

How can I generate a "Social Golfer" matrix for worker seating arrangement?

EDIT: I am looking for an APL function, or MS Access VBA function, which takes as arguments the total number of employees, total number of dinning tables, and n

Using VBA to query a SQL Server table in Excel

I'm trying to query a table in Microsoft Excel using VBA. I've written up some code to try and accomplish this task, but I keep getting an error: run-time e

Create table from data on a worksheet with specific name and add column

I have a number of imported worksheets from CSV. The data includes timestamps based on UNIX epoch. Each time I import a new sheet I need to add a column to conv

Check if a cell from a selected range is visible

I have a VBA function in Excel returns a concatenated string of text from cells selected by users. This works as I require, however if there are hidden cells i

I keep assigning a value to my variable but it stays empty

I am currently working on a code that is supposed to assign a value to a certain variable and open a file with the name assigned to the variable. However, every