Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 150
Default Filling a cell with formula only if cell in the column to the left isfilled

Hi,

Is there a way other than VBA for filling a cell with a formula only
if the cell in the adjaced column is filled? The sheet is being used
as a database where new rows will be added periodically. Filling the
whole column with the formula makes the file size very large.

Thanks in Advance for all the help.

Regards,
Raj
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,441
Default Filling a cell with formula only if cell in the column to the left is filled

Raj,

Hover your mouse pointer over the lowest cell with a formula's lower right corner (the fill square)
until your cursor changes from a white cross to a solid black cross, then double click. Excel will
fill down to match the filled column on the left or the right of that cell.

HTH,
Bernie
MS Excel MVP


"Raj" wrote in message
...
Hi,

Is there a way other than VBA for filling a cell with a formula only
if the cell in the adjaced column is filled? The sheet is being used
as a database where new rows will be added periodically. Filling the
whole column with the formula makes the file size very large.

Thanks in Advance for all the help.

Regards,
Raj



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Filling a cell with formula only if cell in the column to theleft is filled

On Apr 24, 7:48*pm, "Bernie Deitrick" <deitbe @ consumer dot org
wrote:
Raj,

Hover your mouse pointer over the lowest cell with a formula's lower right corner (the fill square)
until your cursor changes from a white cross to a solid black cross, then double click. Excel will
fill down to match the filled column on the left or the right of that cell.

HTH,
Bernie
MS Excel MVP

"Raj" wrote in message

...



Hi,


Is there a way other than VBA for filling a cell with a formula only
if the cell in the adjaced column is filled? The sheet is being used
as a database where new rows will be added periodically. Filling the
whole column with the formula makes the file size very large.


Thanks in Advance for all the help.


Regards,
Raj- Hide quoted text -


- Show quoted text -


Thanks. But this was not what I was looking for.

Example:
Column A has values input by the user. Column B has a vookup formula
that looks up the value in Column A
Let's say that A5 and B5 are filled up.
When the user inputs the value in A6, the formula in B5 should get
automatically copied down to B6 without autofill or any other method.
If the formula is copied down the whole length of Column B the file
size becomes too large.

Thanks in Advance.

Regards,
Raj
  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,441
Default Filling a cell with formula only if cell in the column to the left is filled

Raj,

Ah.

Tools / Option.... Edit tab, check "Extend data range formats and formulas"

Another method would be to use the worksheet change event:

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Cells.Count 1 Then Exit Sub
If Target(0, 2).HasFormula And Not Target(1, 2).HasFormula Then
Application.EnableEvents = False
Target(0, 2).Copy Target(1, 2)
Application.EnableEvents = True
End If
End Sub

HTH,
Bernie
MS Excel MVP

"Raje" wrote in message
...
On Apr 24, 7:48 pm, "Bernie Deitrick" <deitbe @ consumer dot org
wrote:
Raj,

Hover your mouse pointer over the lowest cell with a formula's lower right
corner (the fill square)
until your cursor changes from a white cross to a solid black cross, then
double click. Excel will
fill down to match the filled column on the left or the right of that
cell.

HTH,
Bernie
MS Excel MVP

"Raj" wrote in message

...



Hi,


Is there a way other than VBA for filling a cell with a formula only
if the cell in the adjaced column is filled? The sheet is being used
as a database where new rows will be added periodically. Filling the
whole column with the formula makes the file size very large.


Thanks in Advance for all the help.


Regards,
Raj- Hide quoted text -


- Show quoted text -


Thanks. But this was not what I was looking for.

Example:
Column A has values input by the user. Column B has a vookup formula
that looks up the value in Column A
Let's say that A5 and B5 are filled up.
When the user inputs the value in A6, the formula in B5 should get
automatically copied down to B6 without autofill or any other method.
If the formula is copied down the whole length of Column B the file
size becomes too large.

Thanks in Advance.

Regards,
Raj

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Filling a formula down-need correct cell reference NeedExcelHelp07 Excel Worksheet Functions 13 October 31st 07 06:43 PM
Automatically filling in a formula in a cell Don Excel Discussion (Misc queries) 7 October 22nd 07 09:37 PM
programaticly filling a cell with a formula [email protected] Excel Programming 4 January 11th 07 03:45 PM
Error '7' Run out of memory while filling in a cell with a formula Jim Cone Excel Programming 2 January 11th 07 03:26 PM
Filling excel entire row/column instead of single cell from an array shitij Excel Worksheet Functions 3 July 13th 05 07:44 AM


All times are GMT +1. The time now is 05:22 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"