EXCEL-VBA (Visual Basic for Applications for MS-Excel) is the dominant programming language for Microsoft Office Excel.
0
votes
0answers
5 views
Macro to read a csv file into an excel file
i need a macro to open a csv file in the following format:
date descr1 descr2 descr3 descr4 amt
and update an active excel 2013 file in the following format:
date descr3 colx coly colz amt
...
0
votes
0answers
8 views
Excel VBA Macro: Ignore cells with Formulas
I have created a tool in excel which can take two spreadsheets, and copy the content from one to another when we do an update on the sheet itself.
The tool is purely designed to be a copy / paste ...
1
vote
0answers
9 views
Excel 2010 Pastes Data in Wrong Place - Overwrites Existing Data
I have an Excel 2010 workbook that basically brings information in from Access 2010 and pastes it into a Raw Data sheet. It runs through and populates sheets based on the year. When it gets to this ...
-2
votes
0answers
5 views
Shortcut to Run macro in excel for mac
Basically the title says it all. In the editor in excel on Windows, all you have to do to run a macro is press F5. What is the shortcut to do this on a mac?
0
votes
2answers
9 views
converting timestamp from descending to new/different ascending value in excel
I have the values of the first half of a college basketball game counting down from 20 minutes. I need to match the times that I have with the times on a DVD where the times are different ascending ...
2
votes
2answers
17 views
Min of non-contiguous range in VBA Excel
I am looking to find a minimum value of a non-contiguous range using Excel VBA. The main reason for the range being non-contiguous is that I want the user to be able to select the range. Unfortunately ...
0
votes
1answer
20 views
excel vba giving a value to next variable in the same sub
I have a sub where I get values every time I run it. What I would like to do, is to add a variable, to another each time the sub runs. For example, I have x, a, b, c variables inside the sub.
Lets ...
0
votes
0answers
26 views
Can I erase a member of an array? [duplicate]
Right now the method I'm using for deleting members of an array is the following:
For i = 1 To UBound(ante_sent)
temp_ante = ante_sent(i)
For k = 1 To UBound(cons_sent)
temp_cons = ...
0
votes
1answer
16 views
Same code not working with new parameters
I am trying to get this code to paste the House # if the associated water and light bills are one month late or more. I have this exact same code running perfectly fine with another set of similar ...
0
votes
1answer
21 views
VBA- creating variable multiple
So new to coding completely. here is question :
How do I make a code that finds a multiple of a number within a set.
Ex. I have a set of number: I want to order the number beginning with the first ...
0
votes
0answers
12 views
Run Time error when Opening an Excel Subroutine from VBS
I have a VBA sub that I am trying to run by calling it through VBS code. The VBS code works to open the Excel workbook and call the sub but the sub stops with a runtime error when it opens. The ...
0
votes
0answers
11 views
VBA commands not working unless run step-by-step
I have been having a problem with visual basic. I am adding doughnut charts to a powerpoint slide with excel VBA. When I use debug and step through the macro, it works perfectly, but when I just run ...
0
votes
0answers
26 views
Using variable as part of URL;<string>
I am trying to pass the variable StrPass to the HTML extraction code in this module but I can't figure out how to get it to work. Can i not use a variable with the URL; command?
Public StrPass As ...
1
vote
1answer
7 views
Unable to set the value for the second series in a chart
i am creating some vba to update the series ranges for a chart I have in my workbook. I am able to update series 1 however series 2 returns a 1004 error when i try and run the code.
Here is what I ...
0
votes
1answer
22 views
Loop through columns and delete those that only have zeros
Posting this from the Stack Exchange app so forgive me if the formatting is a bit off.
Basically, I want to do something really simple. I have a spreadsheet with some data. Headers are on the first ...
0
votes
3answers
23 views
Macro for removing conditional formatting fill color Red
I have a large excel report and I am trying to make life easier for my technicians.
I have cells where if a number is not within 10% of another cell then that cell will highlight in RED. My ...
0
votes
0answers
34 views
Same VBA code applied to multiple sheets (ver 2)
Thanks guys!! This is kind of an extended version of my question before but I kind of came up with a method but its still giving me errors. Basically my workbook contains worksheets with have data ...
0
votes
0answers
23 views
Excel vba Userform occasionally does not work
I have a userform in excel that has a timestamp caption box, and a button next to it that brings up another userform that has the input for the time stamp, and when I hit my submit button for the 2nd ...
0
votes
0answers
20 views
Combining multiple rows into one in Excel VBA
I'm trying to write a code that would help me automate the process of combining multiple rows into a single row through the use of VBA. I have several hundreds of grouped data that needs to be put in ...
-1
votes
0answers
10 views
Row counts trouble in excel 2007 VBA [on hold]
My this macro has been working perfect, but lately it missed one count twice. I couldn't see anything different with that same value, why it missed that one. Here's the codes.
0
votes
1answer
15 views
Storing multidimensional Data that can be accessed by Key VBA
I need a data structure in VBA that will allow me to use a for loop to iterate over a list of investments and store them by "investment name" and then store both the "Market Value" and "Percent ...
0
votes
1answer
13 views
How do I create a report in Excel marking empty cells as “n” and cells with any input as “y” for a range of cells?
As an example, say I have five columns and five rows of data. Column A would all be names, where the remaining four columns, B through E, include user-generated data about each individual person.
I ...
-2
votes
1answer
26 views
VBA Excel: Copy column data from one sheet to another sheet
Hi I am trying to write a visual basic code that would copy values from A1 of data worksheet to another destination compilation sheet. The rows from the data source change weekly so I would need to ...
1
vote
1answer
9 views
Excel VBA Change Next Cell Text Color ERROR
Excel VBA 2010
This is a quick function that when the user click on a cell (A Column), it creates a checkmark. I also want the function to make the text in adjacent cell (B column) change color.
I'm ...
0
votes
1answer
14 views
SQL Record Count VBA ADODB connection
Trying to work a RecordSet count in VBA Using ADODB recordset but it won't seem to get the count to work properly.
I've got 50 records in a worksheet with unique ID's, some of them are already in a ...
-1
votes
2answers
9 views
Pivot Table Number Ranges - Novice
I am a complete novice to excel and having my first go with Pivot Tables.
I have sheets with lost of data mostly numeric, these sheets contain up to 80,000 rows and 25 columns.
I am using pivot ...
1
vote
2answers
11 views
Type mismatch on query to create an array from list
I am running some VBa code in Excel to update multiple sheets, based on a list of sheets names.
Sub Test()
Dim ArrayOne As Variant
ArrayOne = ActiveSheet.Range("A8:A10")
Dim sheetsArray As Sheets
...
1
vote
1answer
21 views
Applying same VBA code on all sheets in a workbook
I have a question regarding VBA.
I am trying to apply the below code to all the sheets in a workbook.
The workbook contains numerous worksheets but have all the datapoints in the same cells
The only ...
-2
votes
1answer
19 views
I keep receiving a compile error in excel with my macro
I keep receiving a compile error in excel with my macro.
I'm trying to make a macro in a shared workbook (I will unshare the workbook to use the macro) and have it copy over to another file (The ...
-2
votes
0answers
11 views
vba excel: pin/float a workbook over another workbook
Inside the main excel application window i have two or three
workbooks open. For maximum space availability and better design/looks
purposes these workbooks all overlap each other.
When i switch ...
0
votes
1answer
23 views
Excel VBA: Cell Value from Macro
I have a Macro that sets the value of a cell from other cell values.
So the Macro sets the value of a cell when I run the code as usual.
But I want the Macro work like a Formula.
So the value of a ...
-2
votes
0answers
27 views
VB macro convert ppt to pdf
This is what I have so far. I am trying to get it to filter through al the folders not just the top level drive letter. Converstion of ppt to pdf. Any help that can be provided would be greatly ...
0
votes
1answer
20 views
Automatically include image and sound files in excel columns, based on a filename in another column
I have a column with filenames in my excel file.
In the same folder of the excel file, I have image files in the form of that filename + '.jpg'. Also I have small mp3 files with the same filename + ...
-3
votes
0answers
33 views
Excel Macro: I need help copying data from one shared file to another non-shared file (Not Solved 8-26-14)
Hello all I have a scenario which I'm trying to help another team in the office. They want to have a shared woorkbook so that the team members can update the sheet. They also want graphs from the data ...
0
votes
0answers
25 views
Excel application issue - single user cannot type in cells
I have built an application in Excel 2013, which is accessed by users on another site via remote desktop sessions on a server running Windows Server 2012. The application contains a range of ActiveX ...
0
votes
0answers
16 views
Excel macro to compile a csv using Vlookup on cells in each row
does anyone know why the following section of code in my excel macro will not run
i'm generating a csv file from selected cellls in a row, some of these require a lookup on named ranges in the ...
0
votes
2answers
35 views
Open a Woorkbook in background VBA Excel
I'm trying to use this code to open a workbook in background.
Dim app As New Excel.Application
app.Visible = False
Dim book As Excel.Workbook
Set book = app.Workbooks.Add(UserForm1.TextBox1.Text)
...
1
vote
1answer
29 views
why wont my macro automatically run when the cell is changed?
I am trying to implement and automated change function on visual basic for applications. I have recorded a macro which takes information from one sheet and inserts a new row and pastes the information ...
0
votes
1answer
21 views
Conditional Formatting using VBA - For Exact Matched Words
You commented on on the following page about Conditional Formatting using VBA -
Conditional Formatting using VBA
You don't need a loop for this. You can just add a new FormatCondition
to your ...
-1
votes
1answer
15 views
Check if unique identifier is present in “new data”, if not, add entries to “historical data” sheet?
I've got data with a unique ID number in one column. This is pasted into a "Raw Data" sheet by the user.
Then, I've got macros that manipulate the "Raw Data", including archiving some of it on a ...
0
votes
1answer
22 views
Insert Same Data Every 6th & 7th Row - Excel
I have the following plus a whole lot more in an excel spreadsheet:
service instance 404 ethernet
description Name 661-1-11-3-15
encapsulation dot1q 804 second-dot1q 4
rewrite ingress tag ...
0
votes
0answers
20 views
Application defined 1004 runtime error - need help urgently
I am trying to create a worksheet which takes data from a pivot table annd then populates the table. I use the same function in different sheets for different portfolios. What this function does is to ...
0
votes
1answer
20 views
VBA: Handling PowerPivot refreshing error
I'm using a Macro to refresh some data in PowerPivot, it then autosaves the updated file on my computer.
My problem is that I'm using SSH in order to connect to a database and due to bad connection ...
0
votes
0answers
21 views
Tables from multiple files to one variant Array
I'm writing a process and using a while-loop to go through through all folders and excel files in a user specified directory.
My question is, I want to pull a certain set of data from each workbook ...
0
votes
1answer
42 views
Write to a very large number of Excel cells at once
I have the following code
Dim Destination As Range
Set Destination = Cells(2, 1)
Set Destination = Destination.Resize(UBound(X_values), 1)
Destination.Value = Application.Transpose(X_values)
With ...
0
votes
0answers
24 views
Make VBA Code IE11 compatible
I have written following piece of code to scrap Quantities available for a product for each colors and return it as a string.
So if the code works as expected following will be the output for URL
...
0
votes
1answer
22 views
Excel (VBA needed?) Select all Cells in a row that have a certain format and are filled, then count them. Use that count in a formula
Analysing some data I got for my company, I need to count cells, so I can work in a formula with that count.
CurrentRegion doesn't work. Here's what criteria need to be met.
The cells counted must ...
0
votes
0answers
12 views
Reading “highlighted” text in WordDocument using Excel Macro
I am trying to find out all text highlighted in a particular color, in a word document table, using Excel macro.
I am pretty close to the solution, but not quite complete though.
Sub ...
0
votes
1answer
51 views
Parse HTML content in VBA
I have a question relating to HTML parsing. I have a website with some products and I would like to catch text within page into my current spreadsheet. This spreadsheet is quite big but contains ...
1
vote
1answer
19 views
VBA ADODB multirow insert not working
I am trying to figure out how to do multirow inserts using ADODB in VBA excel.
My problem seems to be that i can`t figure out the correct syntax to use for this simple task, even after searching I am ...