ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Access to Office (https://www.excelbanter.com/excel-programming/333473-access-office.html)

vinbad

Access to Office
 

If I have entered data in a cell and I want to access data from an
Access MDB file to fill the dropdown of another cell how can I do so?

Can any one help me with this?


--
vinbad
------------------------------------------------------------------------
vinbad's Profile: http://www.excelforum.com/member.php...o&userid=24865
View this thread: http://www.excelforum.com/showthread...hreadid=384070


Sean Connolly[_2_]

Access to Office
 
Hi Vinbad,

If I'm understanding your request correctly, one way to achieve what I
*think* it is that you're trying to achieve might be ...

1. Create a single column QueryTable that will retrieve your data from the
Access dB. (Data - Import External Data - New Database Query).
2. Ensure that the .RefreshOnFileOpen property is checked/set to "true".
(You might also consider locating your QueryTable and results on a hidden
sheet).
3. Carefully name the QueryTable (which will also be the result range name)
and remember the name. (For example: rngList).
4. Select the cell on the worksheet where you want the dropdown.
5. From the Excel Data menu choose Validation...
6. On the Settings tab, from the Allow dropdown choose 'List'.
7. In the Source textbox type the name of the range containing your dropdown
list values as per 3. above and proceeded by =. (e.g. =rngList).
8. Click on OK and that should be it!

(Of course, this can all be done programatically using VBA, but its a little
more involved and may not be necessary - again, depends on your purpose).

Let me know how you get on and HTH, Sean.

"vinbad" wrote:


If I have entered data in a cell and I want to access data from an
Access MDB file to fill the dropdown of another cell how can I do so?

Can any one help me with this?


--
vinbad
------------------------------------------------------------------------
vinbad's Profile: http://www.excelforum.com/member.php...o&userid=24865
View this thread: http://www.excelforum.com/showthread...hreadid=384070




All times are GMT +1. The time now is 10:06 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com