Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default I only want to grab specific cells

Okay, I've got an Excel document throws a list of items into a listbox. It grabs that item list from another sheet. Here's how it does that:

Range("B1").Select
While ActiveCell.Value < ""
test2 = ActiveCell.Value
Sheet1.comboShowReports.AddItem test2
Cells(ActiveCell.Row + 1, 2).Select
Wend

It basically loops down through the list until it reaches an empty cell. Easy enough... Except now I want it to loop through based on an additional piece of information. I want it to grab everything whose value equals null in the B column AND whose value equals "ShowReports" in the C column.

How would I go about doing that?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default I only want to grab specific cells

Right now your loop stops when column B equals "Null". How is it supposed
to tell when to end now?

--
Regards,
Tom Ogilvy

"Gary Phillips" wrote in message
...
Okay, I've got an Excel document throws a list of items into a listbox. It

grabs that item list from another sheet. Here's how it does that:

Range("B1").Select
While ActiveCell.Value < ""
test2 = ActiveCell.Value
Sheet1.comboShowReports.AddItem test2
Cells(ActiveCell.Row + 1, 2).Select
Wend

It basically loops down through the list until it reaches an empty cell.

Easy enough... Except now I want it to loop through based on an additional
piece of information. I want it to grab everything whose value equals null
in the B column AND whose value equals "ShowReports" in the C column.

How would I go about doing that?



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
Import data to specific cells for a specific row Netta Excel Discussion (Misc queries) 0 January 27th 09 04:23 PM
Getting specific data into specific cells? Kram Excel Discussion (Misc queries) 0 November 6th 08 03:09 AM
number grab David New Users to Excel 5 July 20th 06 10:45 PM
grab detail when = 1 jenn Excel Worksheet Functions 0 January 12th 06 09:06 PM
Grab Password Name Paul P[_3_] Excel Programming 3 October 24th 03 01:07 AM


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