Solved

DirListBox  Change Initial Default Drive in Box to a:

Posted on 2003-11-04
3
207 Views
Last Modified: 2008-02-01
I notice when using dirlistbox , the default is c:
ie. the dirlistbox initially shows c:

Is there a way of making the default =   a: ie (initial display)

if i use Drive1.drive=a:   the program tries to open drive a:, but there is no disk there yet.

The dir list box contains  a:   c:  d:  e:    but lights up the c: at load

Also, is there a way of determining if the drive is removeable ie floppy. as i need to format if this is so.??

Appreciate any help offered.

0
Comment
Question by:kennedymr
3 Comments
 
LVL 8

Expert Comment

by:dds110
ID: 9681983
The code you are using is correct, but, unless you have a disk in, it will fail (no way around this that I know of).

As far as determining the drive type?  Take a look at this code here:

http://www.planetsourcecode.com/vb/scripts/ShowCode.asp?lngWId=1&txtCodeId=151

HTH
0
 
LVL 28

Accepted Solution

by:
AzraSound earned 125 total points
ID: 9682314
The DirListBox is simple enough that you can emulate it with your own using a simple combobox if you really want this functionality of setting the floppy as the default.
0
 

Author Comment

by:kennedymr
ID: 9682508
Azarasound, Thanks for your tip. This seems to be the answer to the problem.


Thanks also to dds110 for your help, much appreciated.

Allways Appreciate the help offered

Regards  kennedymr
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now