Making Spreadsheet Bigger Depending On Incoming Data

cameron.scrimgeour

Registered User.
Local time
Today, 14:43
Joined
May 7, 2009
Messages
21
I have a spreadsheet which uses VBA to connect to a Database. Data is then extracted into the spreadsheet.

The problem is that if more than 15 rows of data is extracted and put into my spreadsheet, it doesnt fit into the spreadsheets formatting correctly.

Is there any way I can code it so that it will allow for more rows of data coming in if needed?
 
Hi, cameron.scrimgeour,

as I know noting about your formatting you could use the name Database for the range currently used which should rely on the range neede (or create a name yourself based on Offset and the number of records by Count/CountA).

If you do it by VBA you could adjust the name after the import:
Code:
ActiveWorkbook.Names.Add Name:="myName", RefersToR1C1:= _
    "=Sheet1!R1C1"

Ciao,
Holger
 

Users who are viewing this thread

Back
Top Bottom