Excel Macro, need to use key combination in macro

Posted on 2013-02-06
Last Modified: 2013-02-07
In Excel I can access a function by pressing the Alt key, then the S key, then the R key and then the D key

I want to put this in a macro format where I run it and it would send these keys in Excel.

I have been trying the Application.sendkey without any luck.
Question by:wilpitz
  • 4
  • 2
LVL 46

Expert Comment

by:Martin Liss
ID: 38861859
Are you trying to send Alt+SRD ?

Author Comment

ID: 38861870
No it needs to be each single key
LVL 46

Expert Comment

by:Martin Liss
ID: 38861878
So Alt, the S then R then D? or Alt+S, Alt+R, Alt+D?
Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

LVL 46

Accepted Solution

Martin Liss earned 500 total points
ID: 38861885
Just in case, to send Alt+S do


Author Closing Comment

ID: 38864054
Yep got it to work!

Application.SendKeys ("%S")
Application.SendKeys ("R")
Application.SendKeys ("D")
LVL 46

Expert Comment

by:Martin Liss
ID: 38864268
I'm glad I was able to help.

Marty - MVP 2009 to 2012

Featured Post

Optimizing Cloud Backup for Low Bandwidth

With cloud storage prices going down a growing number of SMBs start to use it for backup storage. Unfortunately, business data volume rarely fits the average Internet speed. This article provides an overview of main Internet speed challenges and reveals backup best practices.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This Article is a follow-up to my Mappit! Addin Article (, it was inspired by an email posting I made to EUSPRIG (, I will briefly cover: 1) An overvie…
Convert between Excel file formats (.XLS, .XLSX, .XLSM) with/without macro option David Miller (dlmille) Intro Over this past Fall, I've had the opportunity to see several similar requests and have developed a couple related solutions associate…
This Micro Tutorial will demonstrate how to use longer labels with horizontal bar charts instead of the vertical column chart.
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

778 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question