define range

  1. N

    Excel 2010 Defining Object as Range of Values

    Hello all, So I am trying to have a bit of code that recognizes all values between 3 and 5 within a range (which I will refer to as n) and if a cell value falls within this range then apply the replace the value with the following formula (n[original val] - 3) x .5) +3 Below is the code I have...
  2. R

    Copy data from a workbook and paste values into another workbook

    Hi I need to copy and paste the values of certain columns from one workbook to different columns in another workbook. See my code below.. I know this code is not efficient, I am new to VBA and would appreciate any help to make my macro more efficient.. I could start copying from row 2 instead...
  3. J

    Defining 2 Dynamic Ranges on Same Worksheet

    I have 2 ranges (each with headers and underlying text data) stacked on top of one another on the same worksheet. I am attempting to write a macro that autofilters the first range, copies and pastes data I need from each column to a separate worksheet, and then moves down to the second range...
  4. C

    Macro - Insert 4 rows, then go to the next cell and repeat

    Hi, I have a list of sells that is poviding, for simiplicity sake, the Following Col A - Company Name Col B = Start of year (e.g. 1/1/2007 or 1/1/208) Col C = End of Year (e.g. 12/31/2007 or 12/31/2008) Col D = Revenue for the year This goes on for a good 1500 rows. What I am trying to do is...
  5. I

    Using a Defined Variable in a Formula through VBA

    hi, I'm probably being really stupid but I can't figure this out. So, I have a string variable that I have being input through an Input box, this variable is Dim VP as string This is carried through to a private function where I want to add this into a formula. The formula is a simple one...
  6. F

    How to make a function only apply to a variable number of rows containing data

    I'm writing a macro to apply some simple functions (copy, paste, sort, etc) to a sheet of data. My problem is that the number of rows in this sheet will vary for each occassion I want to apply the macro. Can someone please tell me how to instruct a function to first calculate the number of...

Some videos you may like

This Week's Hot Topics

  • VBA (Userform)
    Hi All, I just would like to know why my code isn't working. Here is my VBA code: [CODE=vba]Private Sub OKButton_Click() Dim i As Integer...
  • List box that changes fill color
    Hello, I have gone through so many pages trying to figure this out. I have a 2020 calendar that depending on the day needs to have a certain...
  • Remove duplicates and retain one. Cross-linked cases
    Hi all I ran out of google keywords to use and still couldn't find a reference how to achieve the results of a single count. It would be great if...
  • VBA Copy and Paste With Duplicates
    Hello All, I'm in need of some input. My VBA skills are sub-par at best. I've assembled this code from basic research and it works but is...
  • Macro
    is it possible for a macro to run if the active cell value is different to the value above it
  • IF DATE and TIME
    I currently use this to check if date has passed but i also need to set a time on it too. Is it possible? [CODE=vba]=IF(B:B>TODAY(),"Not...
Top