VBA (Visual Basic for Applications) is the dominant programming language for Microsoft Office Applications [Word, Excel, Access...].
0
votes
0answers
6 views
how do I create a graph in excel spanning the y axis
I am working with excel and looking to create a graph the same as the following
http://blogs.sas.com/content/graphicallyspeaking/files/2012/07/Butterfly2.png
See how the y axis has values either ...
1
vote
0answers
18 views
Inserting VLOOKUP into spreadsheet using VBA but having table array length adjustable
Let me preface by saying I'm very new to VBA and understand there could be easier, cleaner ways to go about this, but here we go:
I have this equation:
ActiveCell.FormulaR1C1 = ...
1
vote
1answer
5 views
Trouble with Input Box range attribution
I've been trying to build a utility that allows the user to select formulas in a column (or row) and transpose those to a row (or column) using the Transpose method of PasteSpecial. I have it working ...
0
votes
0answers
6 views
Updating Rows from Source Sheet to Target Sheet while Deleting Rows from Target
I'm running a master submodule that calls other submodules. The submodule called UpdateMatrix is not working. Below is the full code. Here's the process:
Another person will write Done/done in ...
0
votes
0answers
5 views
Data Validation - Ignoring numbers or skipping columns in Drop Down List - Excel
I have 2 excel sheets in one excel file, which are:
summary and media
What I want to achieve is that
the media sheet can display a drop down menu from the data in summary sheet but at the same ...
0
votes
0answers
12 views
Use autofilter with criteria based on keys in multiple workbooks (like in SQL)
I have two spreadsheets:
Has an index key, several columns of data, and a date
Has an index key and two dates (dateIn and dateOut)
I'm trying to separate the data from the first spreadsheet into two ...
0
votes
0answers
16 views
vba copy and paste different worksheet with merged cells
I can use the code below to copy cells a1:g1 to the next empty cell in sheet2 column A. i can move the column using cells(rows.count, "E") to paste in column E. My issue is that i want to start ...
1
vote
1answer
28 views
Get the column of a user selected cell using vba excel
Refer to this question: Let the user click on the cells as their input for an Excel InputBox using VBA.
I use this line of code Set rng = Application.InputBox(Prompt:="Select the cell you want to ...
3
votes
3answers
24 views
add columns in excel
I am trying to create an excel macro that automatically inserts two columns before column D...
The procedure worked fine when I created it, here it is:
Sub AddColumns()
Columns("D:D").Select
...
2
votes
1answer
25 views
Sort cells in column from A to Z
The code is from slightly edited macro. I tried to remove the 'messy code', however it is not working. The aim of it is to sort data in column BF from A to Z.
Dim InSheet As Worksheet
Set ...
0
votes
0answers
19 views
Excel User Defined Function to remove special characters and convert to upper case
I have been trying to make a user defined function I wrote return it's value in all upper case, using the String.ToUpper() method in VBA. When I try to use my UDF in excel, I get a compiler error that ...
1
vote
2answers
28 views
Which is faster and more efficient - For loop, MATCH, FIND, etc?
What I am doing is search some strings one by one in the entire range - like search for "blah1", if found then exit, else search "blah2" in the entire range in the same manner. "blah's" are searched ...
0
votes
1answer
14 views
Looping through rows / columns and checking values to determine what value to assign to new column
I've spent half day or so over this week learning vba, and building up this macro. After much research, mostly done on stackoverflow - this is what I have so far. I keep getting sub or function not ...
0
votes
1answer
9 views
Copying active row of Sheet1 to Sheet2 based on cell condition & avoid duplicates
Copying active row of Sheet1 to Sheet2 based on cell condition (Column F="Yes") and also prevent duplication.
I tried the following
Private Sub CommandButton1_Click()
Dim CustomerName As String, ...
0
votes
1answer
27 views
How can I make the Excel filtering macro use the date locale correctly?
I found macro code (apologies to my source, I can't find where I got this from) to do some filtering and modified it to include a date range. Here is the code snippet:
Dim wb1 As Workbook, wb2 As ...