Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Returning Columns to a List Box for a Holiday LookUp Table




Guys - I need help with this little problem!

I have a worksheet that holds everyone's holiday period, that is the
first day of their holiday in one cell and the last day of their
holiday in another. The structure of this table is that row one
holidays the employee name across two merged cells, this means that
each employee has two columns in order to hold the dates of their
holiday!

The problem that I want to crack is through use of a user form, how do
I return all of holiday dates to a list box when I search on a
employee's name? I have created a form with a text box where I can
enter in a name, and I can find the name using the Find function, but I
am stuck as to how to copy the correct columns giving the start and end
of the holiday.

There could anything up to 200 names on the table.

The other thing to note are that the dates (not the names) are linked
to cells in other workbooks as each employee holds their own
holidaysheet, and I think this may complicate the search.

Can anyone help with this?????


--
Noggy1
------------------------------------------------------------------------
Noggy1's Profile: http://www.excelforum.com/member.php...o&userid=19126
View this thread: http://www.excelforum.com/showthread...hreadid=475489

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,163
Default Returning Columns to a List Box for a Holiday LookUp Table

The links to other workbooks should not be a problem as long as everything is
up to date and calculated on the sheet you are using at the time you do the
search.

As for how to find the dates: If you have found the employee name (as you
say you can) then (if I visualize this correctly) the start and end dates are
directly beneath the merged cell with that name in it? The find function
will return the address of the upper left cell that makes up the merged cells
- in your case, this means that (address-wise) the start date is directly
under the found cell, the end date is one cell to the right of that:
StartDate = Range("1:1").Find(EmployeeName).Cells(2,1).Value
EndDate = Range("1:1").Find(EmployeeName).Cells(2,2).Value
I am not clear how you want to use these with your list box, but this is how
you can find the dates.
--
- K Dales


"Noggy1" wrote:




Guys - I need help with this little problem!

I have a worksheet that holds everyone's holiday period, that is the
first day of their holiday in one cell and the last day of their
holiday in another. The structure of this table is that row one
holidays the employee name across two merged cells, this means that
each employee has two columns in order to hold the dates of their
holiday!

The problem that I want to crack is through use of a user form, how do
I return all of holiday dates to a list box when I search on a
employee's name? I have created a form with a text box where I can
enter in a name, and I can find the name using the Find function, but I
am stuck as to how to copy the correct columns giving the start and end
of the holiday.

There could anything up to 200 names on the table.

The other thing to note are that the dates (not the names) are linked
to cells in other workbooks as each employee holds their own
holidaysheet, and I think this may complicate the search.

Can anyone help with this?????


--
Noggy1
------------------------------------------------------------------------
Noggy1's Profile: http://www.excelforum.com/member.php...o&userid=19126
View this thread: http://www.excelforum.com/showthread...hreadid=475489


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
Lookup value in table without returning #N/A Eric_NY Excel Discussion (Misc queries) 3 February 28th 09 04:04 AM
Lookup info in one Column and then returning info in other columns Cyndi513 Excel Worksheet Functions 1 June 23rd 08 02:36 PM
Excel returning more than one value from a lookup table that match the same value [email protected] Excel Discussion (Misc queries) 3 September 26th 07 08:59 PM
Returning a text result from 2 lookup columns sam Excel Discussion (Misc queries) 4 June 14th 07 02:14 PM
Returning multiple corresponding values using lookup in a list Wk Excel Discussion (Misc queries) 2 January 25th 06 10:56 PM


All times are GMT +1. The time now is 03:33 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"