Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ListView icon/thumbnail

Status
Not open for further replies.

sal21

Programmer
Apr 26, 2004
411
0
16
IT
I just have a c:\mydir\ with .jpg images.
i need to show in a liostview all images such as thumbnail.
no eperience with...

if is possible insert a dialog box to select dir of images
tks.
 
Strong tks for reply.
but is for a listview?
 
Perhaps you should explain in more detail what you are actually trying to achieve
 
I need to show image from dir in listview as photo album...

Note:
But only for image with .jpg
 
And what do you think the code in the thread I linked does?
 
sorry, but busy...

with a milion of cut and paste code...

my last code:

Private Sub FILL_LISTVIEW()

Dim sfile As String
Dim sPath As String
Dim sPATTERN As String
Dim pattern_array() As String
Dim pattern As Variant

sPATTERN = "*.gif;*.bmp;*.jpg"
sPath = STRPATHIMG

pattern_array = Split(sPATTERN, ";")

sfile = Dir(sPath)

Me.ImageList1.ImageHeight = 64
Me.ImageList1.ImageWidth = 64

Me.ListView1.ListItems.Clear

For Each pattern In pattern_array
Do While Not sfile = ""
Me.ImageList1.ListImages.Add , , LoadPicture(sPath & sfile)
Set Me.ListView1.Icons = Me.ImageList1
Me.ListView1.ListItems.Add , , sfile, Me.ImageList1.ListImages.Count
sfile = Dir
Loop
Next

Me.LNR.Caption = Me.ListView1.ListItems.Count

End Sub
 
Ok, well, that won't work quite the way you think. But assuming it does, what do you then want to do with it? Are you simply trying to create your own Select Picture dialog? In which case I again refer you to my code.

Or is the problem you seek halp with how to "insert a dialog box to select dir"?
 
Did you get this working the way you wanted (whatever that was)?
 
Hi bro
Very busy...
I have changed the home...
Imagine you!
Pc off, naturally.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top