Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Define colume function in VBA

  1. Mar 16, 2012 #1
    Is it possible to define a function for an entire column in excel? I have data importing from a chemical process simulator and every time it populates a row it will insert a blank row and I need to copy my formulas. Can I make it so, for example, column B is always equal to Column A+something, or etc???
     
  2. jcsd
  3. Mar 16, 2012 #2

    rcgldr

    User Avatar
    Homework Helper

    You can enter =sum(...) into a cell to add up a list of values in a column or row of cells, for example, =sum(a1..a10) produces the sum of the column of cells a1 through a10.
     
    Last edited: Mar 16, 2012
  4. Mar 18, 2012 #3
    Create a template with the VBA function in the template...then use that template to make your sheet each time...that function will be available
     
  5. Mar 18, 2012 #4
    Do you run a VBA routine to do the import, or manually import a text file, or is another program writing to the .xls file?

    If you already have a VBA routine to do the import, you could just add a line to update the cell in column B for that row with your formula.
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook




Similar Discussions: Define colume function in VBA
Loading...