Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 12
Default Filter Data based on cell value

Hi, I need to run a macro to filter the data from a query based on the value
of a cell. It is hard to explain so I have put a print screen picture at:

Http://www.nws-web.co.uk

If anyone has any ideas how I can make this work it would be great, I can't
copy the data manually as the worksheet will never actually be open it will
just run calculations in the background.

Many Thanks

Windows XP Professional
Office 2003
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 915
Default Filter Data based on cell value

Bob1866 wrote:
Hi, I need to run a macro to filter the data from a query based on the value
of a cell. It is hard to explain so I have put a print screen picture at:

Http://www.nws-web.co.uk

If anyone has any ideas how I can make this work it would be great, I can't
copy the data manually as the worksheet will never actually be open it will
just run calculations in the background.

Many Thanks

Windows XP Professional
Office 2003


Maybe this. In cell I7, fill right:

=VLOOKUP($E$9,$I$11:$M$9999,1+COLUMN()-COLUMN($I:$I),FALSE)
  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 12
Default Filter Data based on cell value

Hi many thanks for your reply, I have entered the formula suggested into I7
which provided cell E9 shows 1234567891 then cell I7 also shows 1234567891,
however, If I put a different number in cell E9 i get an error in cell I7 of
#N/A. I am also not quite sure how to do the "fill right" to copy the rest of
the data in the row.

Many Thanks


"smartin" wrote:

Bob1866 wrote:
Hi, I need to run a macro to filter the data from a query based on the value
of a cell. It is hard to explain so I have put a print screen picture at:

Http://www.nws-web.co.uk

If anyone has any ideas how I can make this work it would be great, I can't
copy the data manually as the worksheet will never actually be open it will
just run calculations in the background.

Many Thanks

Windows XP Professional
Office 2003


Maybe this. In cell I7, fill right:

=VLOOKUP($E$9,$I$11:$M$9999,1+COLUMN()-COLUMN($I:$I),FALSE)

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 915
Default Filter Data based on cell value

VLOOKUP will return #N/A if the value being sought (E9) is not in the
first column of the search range (column I).

"Fill right" is a shortcut for copying a formula to multiple cells. Here
are a few ways to do it:

- Click the cell with the formula (I7), then click the fill handle
(small square in the lower right corner of the cell), hold the left
mouse button down as you drag to select cells to the right. This works
for "fill down" as well.

- Click the cell with the formula (I7), then drag to select cells to the
right. Press Ctrl+R.

- Click the cell with the formula (I7), then drag to select cells to the
right. Navigate the menu to Edit | Fill | Right.

You can also copy cell I7, then paste in J7, K7, etc.

Hope this helps!


Bob1866 wrote:
Hi many thanks for your reply, I have entered the formula suggested into I7
which provided cell E9 shows 1234567891 then cell I7 also shows 1234567891,
however, If I put a different number in cell E9 i get an error in cell I7 of
#N/A. I am also not quite sure how to do the "fill right" to copy the rest of
the data in the row.

Many Thanks


"smartin" wrote:

Bob1866 wrote:
Hi, I need to run a macro to filter the data from a query based on the value
of a cell. It is hard to explain so I have put a print screen picture at:

Http://www.nws-web.co.uk

If anyone has any ideas how I can make this work it would be great, I can't
copy the data manually as the worksheet will never actually be open it will
just run calculations in the background.

Many Thanks

Windows XP Professional
Office 2003

Maybe this. In cell I7, fill right:

=VLOOKUP($E$9,$I$11:$M$9999,1+COLUMN()-COLUMN($I:$I),FALSE)

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 12
Default Filter Data based on cell value

Hi, many many thanks for the formula, I have just applied the fill right and
that works perfectly, thanks for that, I do still have the same problem with
the #N/A though, I have manually entered one of the numbers from column I
into E9 but the only one I get a result wtih is 1234567891 the other numbers
all result in #N/A.

Many Thanks.

"smartin" wrote:

VLOOKUP will return #N/A if the value being sought (E9) is not in the
first column of the search range (column I).

"Fill right" is a shortcut for copying a formula to multiple cells. Here
are a few ways to do it:

- Click the cell with the formula (I7), then click the fill handle
(small square in the lower right corner of the cell), hold the left
mouse button down as you drag to select cells to the right. This works
for "fill down" as well.

- Click the cell with the formula (I7), then drag to select cells to the
right. Press Ctrl+R.

- Click the cell with the formula (I7), then drag to select cells to the
right. Navigate the menu to Edit | Fill | Right.

You can also copy cell I7, then paste in J7, K7, etc.

Hope this helps!


Bob1866 wrote:
Hi many thanks for your reply, I have entered the formula suggested into I7
which provided cell E9 shows 1234567891 then cell I7 also shows 1234567891,
however, If I put a different number in cell E9 i get an error in cell I7 of
#N/A. I am also not quite sure how to do the "fill right" to copy the rest of
the data in the row.

Many Thanks


"smartin" wrote:

Bob1866 wrote:
Hi, I need to run a macro to filter the data from a query based on the value
of a cell. It is hard to explain so I have put a print screen picture at:

Http://www.nws-web.co.uk

If anyone has any ideas how I can make this work it would be great, I can't
copy the data manually as the worksheet will never actually be open it will
just run calculations in the background.

Many Thanks

Windows XP Professional
Office 2003
Maybe this. In cell I7, fill right:

=VLOOKUP($E$9,$I$11:$M$9999,1+COLUMN()-COLUMN($I:$I),FALSE)




  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 12
Default Filter Data based on cell value

Hi again, the reason I am getting #N/A as the result is something to do with
text formatting I believe, if I manually type the number into E9 it returns
with #N/A but if I copy and paste the number into cell E9 from one of the
lookup cells in column I it works perfectly every time. Does anybody have any
ideas why this might be happening and if there is a solution for the problem.

Many Thanks

"Bob1866" wrote:

Hi, many many thanks for the formula, I have just applied the fill right and
that works perfectly, thanks for that, I do still have the same problem with
the #N/A though, I have manually entered one of the numbers from column I
into E9 but the only one I get a result wtih is 1234567891 the other numbers
all result in #N/A.

Many Thanks.

"smartin" wrote:

VLOOKUP will return #N/A if the value being sought (E9) is not in the
first column of the search range (column I).

"Fill right" is a shortcut for copying a formula to multiple cells. Here
are a few ways to do it:

- Click the cell with the formula (I7), then click the fill handle
(small square in the lower right corner of the cell), hold the left
mouse button down as you drag to select cells to the right. This works
for "fill down" as well.

- Click the cell with the formula (I7), then drag to select cells to the
right. Press Ctrl+R.

- Click the cell with the formula (I7), then drag to select cells to the
right. Navigate the menu to Edit | Fill | Right.

You can also copy cell I7, then paste in J7, K7, etc.

Hope this helps!


Bob1866 wrote:
Hi many thanks for your reply, I have entered the formula suggested into I7
which provided cell E9 shows 1234567891 then cell I7 also shows 1234567891,
however, If I put a different number in cell E9 i get an error in cell I7 of
#N/A. I am also not quite sure how to do the "fill right" to copy the rest of
the data in the row.

Many Thanks


"smartin" wrote:

Bob1866 wrote:
Hi, I need to run a macro to filter the data from a query based on the value
of a cell. It is hard to explain so I have put a print screen picture at:

Http://www.nws-web.co.uk

If anyone has any ideas how I can make this work it would be great, I can't
copy the data manually as the worksheet will never actually be open it will
just run calculations in the background.

Many Thanks

Windows XP Professional
Office 2003
Maybe this. In cell I7, fill right:

=VLOOKUP($E$9,$I$11:$M$9999,1+COLUMN()-COLUMN($I:$I),FALSE)


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
Copying data based on filter criteria no_rhythm Excel Worksheet Functions 1 January 10th 08 09:45 PM
Run Filter criteria based on data in range Mitch4 Excel Discussion (Misc queries) 0 October 17th 07 04:15 PM
data filter criteria based on cell references? scshop Excel Worksheet Functions 1 June 22nd 07 03:16 AM
Filter and show data based on a reference cell Stephen Hancock Excel Worksheet Functions 3 June 30th 06 07:53 PM
Filter data based on multiple columns [email protected] New Users to Excel 4 April 28th 06 04:43 PM


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