Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 12-06-2011, 10:17 PM
Pragabhava Pragabhava is offline Show the first item of a drop-down list instead of a blank Windows 7 64bit Show the first item of a drop-down list instead of a blank Office 2010 64bit
Novice
Show the first item of a drop-down list instead of a blank
 
Join Date: Dec 2011
Posts: 1
Pragabhava is on a distinguished road
Default Show the first item of a drop-down list instead of a blank

Hello. Sorry if this has been asked before, but I can't find how to do it anywere.

The problem is the following:

I need to be able to autofill a drop-down list if some cell is not empty.

To be more clear, suppose that i have a drop-down list


Code:
Apples
Bannanas
Pinapples
in cell B1.

Now, suposse that cell A1 can have a catalog code A, B, or P, or be empty. If it's empty, I want B1 to be the drop-down list, else to be the item specified in A1.

I've narrowed to this:
Code:
Fruits = {Apples, Bannanas, Pinnaples}
and in the Data Validation Box, under "Source" I've the following
Code:
=IF(ISBLANK(A1),Fruits,IF(A1="A",Apples,IF(A1="B",Bannanas,Pinapples)))
This works well, except the drop-down shows an empty cell and one has to manually select Apples or Bannanas or Pinapples, wich defeats the whole purpose.

Any suggestions so cell B1 is automatically filled when A1 is specified, or a drop-down if not?
Reply With Quote
  #2  
Old 12-29-2011, 11:48 PM
JBeaucaire JBeaucaire is offline Show the first item of a drop-down list instead of a blank Windows XP Show the first item of a drop-down list instead of a blank Office 2003
Advanced Beginner
 
Join Date: Dec 2011
Posts: 51
JBeaucaire is on a distinguished road
Default

I do this frequently in my forms, the thing to remember is that this solution will be erased by the use of the drop down, ok?

So, in B1, put the formula:

=IF(A1="", "", LOOKUP(A1, {"A","B","P"}, {"Apples","Bananas","Pineapples"}))

Now, as soon as A1 is filled in, B1 will automatically display the answer via this formula.

However, your Data Validation might still be available based on how you set it up. Regardless, if anyone ever uses the data validation drop down list, it will permanently enter a choice into that cell and the formula will be deleted. That may be just fine, it is in my forms since each form is "one use" only and the agents start with a fresh clean form each time with all formulas intact to start with.

Just my idea.
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Show the first item of a drop-down list instead of a blank Automatically select first item in drop-down? flackend Excel 4 08-29-2011 02:07 PM
Show the first item of a drop-down list instead of a blank Drop-Down Menu, show-hide, expand-collapse??? 300zxmuro Word 1 02-27-2011 03:02 PM
25 item max in drop down form sonicvalley Word 0 07-26-2010 11:12 PM
Using both drop down lists and blank cells for text voltarei Word 0 03-18-2010 04:16 AM
Referens to an item list... matbli Word 0 10-29-2009 08:04 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 04:05 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft