Solved

FileListBox won't display long file names

Posted on 2002-06-13
4
155 Views
Last Modified: 2006-11-17
I'm using a FileListBox in one of my projects. It is populated using the change event on a DirListBox (FileListBox.path = DirListBox.path). The problem that I've got is that when a directory name has a space in it the file list box does not diplay the full file name. It only shows the first eight characters then the extension. When the files have the same first eight character it substitutes the last two characters for numbers i.e. testfil1, testfil2 etc. Does anyone know why this is and how if can be remedied?

Many thanks,

Dust.



0
Comment
Question by:dustybryn
  • 2
4 Comments
 
LVL 142

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 7075595
This is probably because of your version of VB, i guess you have VB5...
CHeers
0
 

Author Comment

by:dustybryn
ID: 7075632
I'm using VB6 Enterprise Edition, try it for yourself.
0
 
LVL 75

Accepted Solution

by:
Anthony Perkins earned 75 total points
ID: 7075634
THe FileListBox, DriveListbox and DirListBox for the most part are deprecated controls.  Take a look at these two articles from MSDN:
PRB: FileListBox Control May Not List File Names Properly (Q196028)
http://support.microsoft.com/default.aspx?scid=kb;en-us;Q196028&SD=MSKB&
PRB: Problems Using Intrinsic File System Controls (Q196141)
http://support.microsoft.com/default.aspx?scid=kb;en-us;Q196141

Anthony
0
 
LVL 142

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 7075655
In fact, for me the controls work fine...
So I can only suggest what is said in the articles of acperkins: develop your own routines for this, using either DIR() function, the Scripting.Filesystem object or (for hardcore developers) some API functions.

BTW, I don't use those controls except for creating some demo programs...

CHeers
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

864 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

21 Experts available now in Live!

Get 1:1 Help Now