Category "vba"

Retrieve the name of a shape

In Excel we have the "Name Box" in the upper-left side, but I could not find a way to retrieve the name of a shape in Word. How do I do that?

Controlling MSG file draft/sent state

I've an Access database that records and saves email on the mailitem_send event. Saved email looks like: I want email to appear like an already sent email, li

Send from another email address in Outlook

My users have their personal mailbox as their primary account and an auto-mapped shared mailbox configured in their Outlook 2010 client. The shared mailbox is a

Excel VBA function with Recordset (Performance issue)

I have a database in SQL Server that I'm using to feed some financial reports in Excel. I'm using Recordsets through a custom Excel Function that uses arguments

Cannot remove code modules from a destination workbook through VBA

I am running an Excel 2010 macro that opens another workbook and removes a few code modules (a form and a BAS module). After that it re-imports them as an updat

Macro to change colors of specific characters in a range

I wanted to develop a macro for my worksheet that would pick up a range and change the color of specific chars based on its color. This was similarly answered b

Userform resizing according to screen resolution

I have an Excel userform I want to resize on opening to fit the screen resolution. I get the height and the width through Application.Height and Application.Wi

launching chrome or IE via selenium VBA

I have written a code for web data downloading using selenium VBA, it works good in Firefox, but many time Firefox is crashing. I tried to launch chrome/IE from

Conditional move loop - VBA excel

I just learned to use VBA in excel, I have a spreadsheet as shown, I have columns from B1:B12 containing content to search and move, I want to build code to se

Outlook Reply or ReplyAll to an Email

Set objOutlook = CreateObject("Outlook.Application") Set objMail = objOutlook.CreateItem(0) objMail.To = "[email protected]" objMail.cc = "[email protected]" o

Is there any way to get the date time on the "you replied to this message on [xxx]"?

I am trying to do a email export from outlook to excel macro which includes the recipient, email subject and most importantly the date time of email reply. I ha

Saving "Device Independent Bitmap" attachment

How to properly save this kind of attachment (from signed message)? I saved this with .SaveAsFile method, but it is without any extension and no application can

Issue with Redim Preserve (2D array)

Yet another topic with multidimensional array and Redim Preserve, I know. I read a lot of them but still can not understand why my code is not working. I kwow

EXCEL VBA UserInterfaceOnly:= True not working

When I use (some code here).copy destination:=(some code there). It will still prompt for protection issues on cells. Basically it just won't let my code runs.

Run Time Error 5 - Invalid Procedure Call or Argument

I need help with this macro. Every time I run it, I get the error below. I thought it was a simple macro that I could have anybody on my team use to make it t

Excel cells from Access export look empty but are not (=isblank=FALSE)

My problem is that an Excel spreadsheet (exported from Access as .xls) has cells that look empty, but are not. This is mucking up my calculations & navigati

Excel VBA: Autofilter using textbox values

I tried the following to filter (between filter) my worksheet based on 2 values. The 2 values are input in textbx1 and textbox2 in userform 'A1_Filter_Range'.

How to convert PDF to Excel on a Mac?

I have a lot of PDFs to convert to excel. I found the code below which converts PDF to excel by opening the pdf file in word but it fails at Dim fso As New File

add attachment picture into html email body in office 16 / O365

I have been using this code in office 2013: With OutMail .Attachments.Add fName .HTMLBody = .HTMLBody & "<br><B>" &

Open.ics with Outlook 2013 to read items

This is specific to Office 2013. In previous versions of Office (2010), I had a script which would download an .ics attachment and then save it to my calendar.