Autofill of row or column

Z

Zerex71

Greetings,

Let's say I have a min, a max, and an increment, all decimal values. I
want to autofill or autopopulate a row or column -- without manually
dragging cels -- over the range [min,max] incrementing by the increment
value each cell. Can this be done somehow? Also, what if you don't
know how many cells you will need initially (you return some variable
integer from a calculation)--can you tell Excel to fill only that
number of cells each time? For example, let's say I compute some
number and get a 7 one time and a 10 the next, and I want 7 cells
filled with data and then on the next run, the originaly 7 wiped out
and a new 10 filled. Is this possible?

Mike
 
S

Spreadsheet

Mike,

This can be done. However, I need to know what you mean when you sa
that the number of cells needed is a variable. Does this mean that you
range of cells does not need to necessarily reach the max and th
increment remains the same, or does this mean that your max must b
reached in a certain number of cells and thus the increment wil
change
 
Z

Zerex71

I guess the simplest way to answer this is, sometimes I will need 7
cells, sometimes 10, sometimes 15 -- it all depends. I was just
wondering if you can fill cells on the fly and not be fixed to having a
certain number of cells. In software, it's the difference between
using a vector and an array, where vectors can expand and contract as
needed, only reserving as much space as needed, whereas arrays are set
to have a fixed size.

The number of cells needed does not necessarily correlate to the
contents of the cells, although that is likely what I will use them
for. I think the answer to your question is the second interpretation.

To try and make it even more clear, let's assume I have a blank
worksheet. I have some computation that gives me an integer. The
value of that integer determines however many cells I want to fill.

An example problem I am working on at work right now might go like
this: I am using physics to determine the fragment properties of bombs
(the mass and velocity of each fragment). However, depending on the
inputs, I can get a different number of fragments. So I'd like to
build a table that only fills cells for as many fragments as my
calculations output:

FragNo Mass (kg) Velocity (m/s)
....etc....

FragNo might run from 1-3,000 sometimes, it might be 1-5,500, etc. It
all depends. I just didn't want to have a fixed number of cells "set
aside" to be populated with data.

Mike
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top