#1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Define name

Hello,

I have a worksheet with 10 rows table X 3 columns.
Column A: Worker name
Column B: Worker salary
Column C: active/not active (1,0)

I want to define 2 ranges:
First range: all workers name from Column A (just the cells with value)
that are active.
I mean: row A value is not Null and row C value is 1.
Second range: Worker's salary for the workers in the First range.

For example:

A B C
Row1: Gil 120 1
Row2:Dan 100 0
Row3:Joe 50 1

First range will be: A1,C3
Second range will be: 120'50

How can I do this ?

Thank you for your help.
Gil D.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8
Default Define name

Hello,

Thank you for your help. I want to define dynamic ranges because my
user changes the data (add/remove workes and set status to active/not
active).

How can I define these names ?

Gil D.

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Define name


http://www.contextures.com/xlNames01.html#Dynamic

Check out this site , it may help


--
davesexcel
------------------------------------------------------------------------
davesexcel's Profile: http://www.excelforum.com/member.php...o&userid=31708
View this thread: http://www.excelforum.com/showthread...hreadid=520394

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8
Default Define name

Hello,

Sorry, It did not help me to solve my problem.

Gil D.

  #5   Report Post  
Posted to microsoft.public.excel.programming
GS GS is offline
external usenet poster
 
Posts: 364
Default Define name

Hi Gil,

Here's an example for making a dynamic range for your table data:

InsertNameDefine
In the name box enter:
'ActiveSheet'sName'!TableData

This creates a sheet-level name for the active sheet.
To use the name, refer to it as TableData.

In the RefersTo box enter:
=OFFSET(Sheet1!$A$1:$C$3,0,0,COUNTA(Sheet1!$A:$A))

This assumes the table has no header. If it does then use:

=OFFSET(Sheet1!$A$2:$C$4,0,0,COUNTA(Sheet1!$A:$A)-1)


It requires that there are contiguous (non-empty) cells in columnA. You
could do the same for the Salary cells.
-OR-
If you just want to reference the salary 'relative' to a name in columnA
then the RefersTo for Salary would be:
=$B1
so if A3 is active, Salary refers to B3. This will persist the entire length
of columnA.

Regards,
GS
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
Define a Value sagenichole Excel Worksheet Functions 2 May 18th 10 02:41 PM
Define name digicat Excel Discussion (Misc queries) 6 January 19th 06 05:54 PM
Name Define Ken Johnston Excel Discussion (Misc queries) 6 January 8th 06 03:04 PM
Define name Q Benjamin Excel Discussion (Misc queries) 3 October 19th 05 01:29 PM
define name sunshine Excel Discussion (Misc queries) 1 March 29th 05 01:37 AM


All times are GMT +1. The time now is 08:02 PM.

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"