Results 1 to 8 of 8

Thread: help :P

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Aug 2004
    Location
    Auckland, New Zealand
    Posts
    31

    Red face help :P

    Private Sub Command2_Click()
    Set mFolder = fso.GetFolder("c:\Program Files\WMD\Images\usermap\")
    For Each mFile In mFolder.Files
    If UCase(mFile.Type) = "JPEG IMAGE" Or UCase(mFile.Type) = "GIF IMAGE" Or UCase(mFile.Type) = "BMP IMAGE" Then
    Image4.Picture = LoadPicture
    End If
    Next
    Command2.Enabled = False
    End Sub

    i have that code but it doesnt work

    I want a code that will look in a file for the only image there and display it in an imagebox. But since the name of the file is unknown, the program can't find it without a specific code. And the one i got doesn't work :S

    all help appreciated

  2. #2

    Thread Starter
    Junior Member
    Join Date
    Aug 2004
    Location
    Auckland, New Zealand
    Posts
    31
    oh and while were on the subject of helping me...

    Open "C:\Program Files\WMD\usermap.txt" For Input As #1
    Text1.Text = Input(LOF(1), #1)
    Command5.Visible = True
    Command7.Visible = False
    Close #1


    when it puts it in a text box, it puts two rectangles there. and this totally screws up everything. How do i get rid of the little rectangles?


    Thanks

  3. #3
    PowerPoster Deepak Sakpal's Avatar
    Join Date
    Mar 2002
    Location
    Mumbai, India
    Posts
    2,424
    VB Code:
    1. Dim mFolder As Folder
    2. Dim mFile As File
    3.  
    4. Set mFolder = fso.GetFolder("c:\")
    5. For Each mFile In mFolder.Files
    6.     If UCase(mFile.Type) = "JPEG IMAGE" Or UCase(mFile.Type) = "GIF IMAGE" Or UCase(mFile.Type) = "BMP IMAGE" Then
    7.     Image1.Picture = LoadPicture(mFile)
    8. End If
    9. Next
    10. Command2.Enabled = False

  4. #4
    PowerPoster Deepak Sakpal's Avatar
    Join Date
    Mar 2002
    Location
    Mumbai, India
    Posts
    2,424
    set Textbox's MultiLine property to True & ScrollBars property to 3

  5. #5

    Thread Starter
    Junior Member
    Join Date
    Aug 2004
    Location
    Auckland, New Zealand
    Posts
    31
    Thanks Deepak

    my last question and i'm finished:

    When i click on a button to download a file from the internet, I want it to be able to start a progress bar for the download status. How can i do this?

    Thanks in advance

  6. #6
    PowerPoster Deepak Sakpal's Avatar
    Join Date
    Mar 2002
    Location
    Mumbai, India
    Posts
    2,424
    how r u downloading file internet api's, inet ?

  7. #7

    Thread Starter
    Junior Member
    Join Date
    Aug 2004
    Location
    Auckland, New Zealand
    Posts
    31
    inet...

  8. #8
    PowerPoster Deepak Sakpal's Avatar
    Join Date
    Mar 2002
    Location
    Mumbai, India
    Posts
    2,424
    have a look at this . I have not tested this.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width