Results 1 to 3 of 3

Thread: pop up the files in the folder

  1. #1

    Thread Starter
    Frenzied Member
    Join Date
    Feb 2007
    Location
    Malaysia
    Posts
    1,370

    pop up the files in the folder

    How I pop up the files name in the folder without files name extension? I try to pop up the files name but i got this..data member not found

    Code:
    Dim FSO As Scripting.FileSystemObject
    Set FSO = New Scripting.FileSystemObject
    Dim fldMainFolder As Folder
    Dim fldAllSubFolders As Folders
    Dim fldSubFolder As Folder
    Dim flAllFiles As Files
    Dim flFile As File
    
    Set fldMainFolder = FSO.GetFolder("C:\Documents and Settings\fauzul\Desktop\Print Attribute")
    Set fldSubFolders = fldMainFolder.Folders
    For Each fldSubFolder In fldAllSubFolders
        Set flAllFiles = fldSubFolder.Files
        For Each flFile In flAllFiles
           ...
        Next
    Next

  2. #2
    "Digital Revolution"
    Join Date
    Mar 2005
    Posts
    4,471

    Re: pop up the files in the folder

    I don't use the FSO...but a few things...

    Use Option Explicit if you are not already.

    You have a variable named fldSubFolder and later you added an s to it here:

    Set fldSubFolders = fldMainFolder.Folders

    Also, there is no .Folders member. But there is a .SubFolders member.

    Anything after that I probably can't help with since I don't use the FileSystemObject.

  3. #3

    Thread Starter
    Frenzied Member
    Join Date
    Feb 2007
    Location
    Malaysia
    Posts
    1,370

    Re: pop up the files in the folder

    If you don't mind.. What method you use to get the filename? Can I see you sample?

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