Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 18
Default cell function to copy contents of another cell

What I want to do: create a cell function that will - if cell = quantity 0
then copy worksheet 1 cells a2 to c2 and paste that information to worksheet
2 cells a2 to c2
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4,624
Default cell function to copy contents of another cell

Functions can only return values, they can't directly affect (i.e.,
paste to) other cells.

So in worksheet 2, cell A2, enter

=IF(x = 0, 'Worksheet 1'!A2, "")

where x is your "cell" reference. Copy that across to worksheet 2, cell
C2.



In article ,
Margo wrote:

What I want to do: create a cell function that will - if cell = quantity 0
then copy worksheet 1 cells a2 to c2 and paste that information to worksheet
2 cells a2 to c2

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 18
Default cell function to copy contents of another cell

Thanks. I couldn't see the tree for the forest, your formula worked, all I
had to do was add in the worksheet name as well the cell.

"JE McGimpsey" wrote:

Functions can only return values, they can't directly affect (i.e.,
paste to) other cells.

So in worksheet 2, cell A2, enter

=IF(x = 0, 'Worksheet 1'!A2, "")

where x is your "cell" reference. Copy that across to worksheet 2, cell
C2.



In article ,
Margo wrote:

What I want to do: create a cell function that will - if cell = quantity 0
then copy worksheet 1 cells a2 to c2 and paste that information to worksheet
2 cells a2 to c2


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default cell function to copy contents of another cell

One guess ..

Assume quantity is listed in D2 in Sheet1

In Sheet2,
Put in A2:
=IF(Sheet1!$D2="","",IF(Sheet1!$D2=0,Sheet1!A2,"") )
Copy A2 to C2
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Margo" wrote:
What I want to do: create a cell function that will - if cell = quantity 0
then copy worksheet 1 cells a2 to c2 and paste that information to worksheet
2 cells a2 to c2

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 18
Default cell function to copy contents of another cell

Thanks, that answer set me on the right path. I just had to create an IF
formula in each cell on sheet 2 that returned the content of the cell on
sheet 1.
"Max" wrote:

One guess ..

Assume quantity is listed in D2 in Sheet1

In Sheet2,
Put in A2:
=IF(Sheet1!$D2="","",IF(Sheet1!$D2=0,Sheet1!A2,"") )
Copy A2 to C2
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Margo" wrote:
What I want to do: create a cell function that will - if cell = quantity 0
then copy worksheet 1 cells a2 to c2 and paste that information to worksheet
2 cells a2 to c2



  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default cell function to copy contents of another cell

welcome, glad it helped
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Margo" wrote in message
...
Thanks, that answer set me on the right path. I just had to create an IF
formula in each cell on sheet 2 that returned the content of the cell on
sheet 1.



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
how do I copy the contents of every 10th cell? suzie Excel Discussion (Misc queries) 3 June 14th 06 05:31 AM
copy cell value not contents D Moran Excel Discussion (Misc queries) 2 April 24th 06 03:29 PM
Copy contents to cell based on value in second cell Mike Carpenter Excel Discussion (Misc queries) 3 April 21st 06 03:01 PM
Data entry - Copy contents of cell typed in one cell to another ce danie Excel Worksheet Functions 2 March 16th 06 06:51 PM
What worksheet function will formatlessly copy cell contents? MargueriteL Excel Worksheet Functions 1 June 7th 05 04:16 AM


All times are GMT +1. The time now is 11:46 PM.

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

About Us

"It's about Microsoft Excel"