range and maco

  1. D

    Copying n times a range of data to each row of data from two adjacent columns

    Hello everyone, how I can change this VBA to copy two columns instead of one? Lets say the B column is actually C column and there is one extra column - for the purpose of explanation I will add one more column before A. Now - both columns are with the same number of rows (A and B) instead of...
  2. A

    Select range in for loop

    Hello, I have a sheet with 35 columns. I would like to create a For loop to go through all the headers of these columns, find a specific one and return the column underneath it as a Range. I have tried Dim rng As Rang With Sheets("MySheet"). UsedRange For i = 1 To .Columns.count If...
  3. T

    ComboBox,select case all working except one column not showing

    Hello, I have used some code from the net to create a dynamic data range for selection from the combo box. It all works well except one column. The column title displays in the first combo-box but the range does not display in the second? It is called the exact same way as all the rest and i...
  4. S

    Excel VBA to hide columns based on cell value

    I have 3 tabs within my workbook that I would like to hide columns based on cell value. The following code hides some of the columns, but I am looking for assistance to add the rest of the columns. Here is what I am looking for: Hide Columns J:M if cell K18 is "" Hide Columns N:Q if cell O18...
  5. S

    Excel VBA to hide rows based on cell value in range

    I am looking for assistance in revising code for one of my worksheets (Sheet3). In essence, I want to look at a specific cell within a range and if that cell is blank, then hide the entire range. Sheet3 has 5 ranges to gauge whether to hide the blank rows and thought a Union would be the best...
  6. Rymare

    VBA - Invalid procedure call: copy folders to new locations

    The ever so excellent Ron De Bruin has an amazing bit of code that is meant to move/copy one folder to another folder; however it only works if you have only one folder to move. In my excel I have a list of folder paths in column A like so...
  7. A

    Trying to Create a Macro to Autoformat a Report

    Hi All, I am fairly new to VBA coding however a lot of people at my work rely on me to create useful macros for our office. One of the reports that we pull from our employee portal is absolutely atrocious and I have been tasked with formatting it correctly. So to give you an idea of the data...
  8. Y

    Arrays, Ranges and unknown row count

    Afternoon all, I've been doing a lot more VBA scripting so I thought I would join to get expert help and hopefully give one day. I've created a macro tha that will use the mapquest api to find the distance between two points. The macro works but I need to make it more dynamic. The main problem...
  9. D

    VBA code to copy mutiple sets of data from one sheet into another

    Hello all, I'm a new user to VBA. Have been programming since a week and I'm stuck with one of my code. I have mutiple sheets contaning data in a certain format. I want to only copy few blocks of data from all the sheets and arrange in a certain order in a newly created worksheet. I'm...
  10. A

    Loop through files in a folder based on file name and paste data in master sheet

    Hello All, I am new to VBA and could really use your help on this. - I have a folder that has 3 types of files (APL, PL, BPL) and a master file. I would like to pull specific data from specific sheets in each of these files and pull it back into the master file. - The issue I am having is...
  11. N

    VBA Performing calculations on discontinuous cell addresses

    Hi, I have some working code that I'd like to expand on. Basically I'll have a bunch of individual cell addresses "AB10", "AD10", ... "CZ10", and so on that i'd like to compile some basic statistics on. But when I try to get the values in a way that's easy to work with, like in this example...
  12. E

    Need help to lock/unlock multiple sections of a worksheet as when clicked by user

    Hi guys, I am an excel savvy person, but not too expert like VBA or macro programmers. As such, I need some help on figuring out how to lock certain portions of my worksheet upon a click of a button. Imagine a 30-day calendar spread page. I need to have 30 buttons which will enable the user...
  13. C

    Macro not Executing. Copy and Paste based on Criteria in Range

    Hi All I hope you can help. What I am trying to achieve is for my Macro or code to look through column F. When it finds a country then create a new sheet name it after that country then copy all the information for that country from the Original sheet in this case 'TOV Full Extract with...
  14. T

    Shifting a selected range of cells to the right or left

    I have a spreadsheet that needs to shift a selected range of cells one column to the right or left using an "Advance" or "Delay" button. Here is the sequence of operation: 1. Activate a button 2. Select the cells beginning 2 spaces from the button's originating cell to 10 spaces from the...
  15. G

    Setting an Autofiltered Table as a Range using VBA

    Good evening, I have written a report writing program within excel using vba and I have a problem when I try to assign my filtered data to a range. All my data lives in a table called T_RESIDENTS which I set in the code as: Set tblresidents = .Sheets("Residents").ListObjects("T_RESIDENTS")...
  16. A

    Need help with Selecting muiple Cells and then checking all of the values in a IF statment.

    Why will this not work? Does anyone know how they could check each score in a range and run each cell through the If statment. Here is what I have. Thank You! Or if you have a link to where i could find the answer I would really appreciate that also.:) Dim Cell As Integer, result As String...
  17. E

    Formulas in loops

    Dear All, After a lot of effort (I am a brand new in VBA) I have managed to create a macro to do the following: 1. Copy time vs. Volume data (with variable lengths). A18:B18 2. Calculate deltaT and deltaVolume. (A19:B19). 3. For a constant DR located in cell C6 in the same w/s the following is...
  18. L

    Need Help with Macro Button to add 1 to cell based on dropdowns (Row/Column)

    I am having trouble with a macro button, that links to two drop-down boxes. My main sheet (YYD), has two drop-down boxes that reference my other sheet (Data). The first drop-down in YYD!F12 selects a row and the second drop-down in YYD!F17 selects the column on my 'Data' Sheet. I just need a...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top