Loop through excel files in a folder and open it without reference to filenames -


i want loop through excel files in folder , extract information. problem file names of excel files in vietnamese, when use dir function loop, not work. how can loop through files in folder , open them without referring names.

i try getfolder method doesn't seem work either.

thanks help.

sub loopthroughfiles()    dim myobj object, mysource object, file variant    dim wb workbook    set mysource = myobj.getfolder("c:\excel")    each file in mysource.files         set wb = worksbooks.open(file)    next file end sub 

looks have dim myobj, don't initialize before used. should have set myobj = something


Comments

Popular posts from this blog

android - MPAndroidChart - How to add Annotations or images to the chart -

javascript - Add class to another page attribute using URL id - Jquery -

firefox - Where is 'webgl.osmesalib' parameter? -