PDA

View Full Version : MS BROWSER TO EXCEL



nandakumar
03-03-2008, 12:23 PM
hi,
How to export file list in Explorer to Excel, Example: I have 100 of file in D:/item name/
these file name in windows explorer or directory tobe exported to excel file.
if any solution , greatly appreciate.

thanks.:mkay

Ago
03-04-2008, 02:04 AM
open command prompt.
start -> run -> cmd [enter]

type D:\item name\ [enter]
dir [enter]
now you will see the filelist.
rightclick in the window and press mark
now you can mark an area just like in word
when you marked the files press CTRL + C
go to Excel and press CTRL + V

anandbohra
03-04-2008, 02:18 AM
open command prompt.
start -> run -> cmd [enter]

type D:\item name\ [enter]
dir [enter]
now you will see the filelist.
rightclick in the window and press mark
now you can mark an area just like in word
when you marked the files press CTRL + C
go to Excel and press CTRL + V

the actual is not CTRL+C but enter

& one more thing if u r working in DOS mode then follow this (Specially for DOS because there is nothing called mark option but can be use in windows)

use this command
go to the location whose data u want
then press dir > filename.txt

e.g.
u want data of
D:\item name

then go to this location
press dir >test.txt

it will create test.txt file in the same location u r using dir command & the contents will be whatever u see in dir command

Charlize
03-04-2008, 02:48 AM
I think he wants to use the dir command from vba.
Sub Fetch_Filenames()
Dim lrow As Long
'worksheet
Dim ws As Worksheet
'name of file
Dim v_filename As String
'path of files
Dim v_path As String
'define ws
Set ws = ActiveWorkbook.ActiveSheet
'we start at row 2
lrow = 2
'directory of your files
v_path = "C:\Data\*.*"
'get first filename
v_filename = Dir(v_path)
'loop through your files
Do While v_filename <> ""
ws.Range("A" & lrow).Value = v_filename
lrow = lrow + 1
'get next file
v_filename = Dir
Loop
End Sub
Charlize

Ago
03-04-2008, 05:11 AM
the actual is not CTRL+C but enter

& one more thing if u r working in DOS mode then follow this (Specially for DOS because there is nothing called mark option but can be use in windows)

use this command
go to the location whose data u want
then press dir > filename.txt

e.g.
u want data of
D:\item name

then go to this location
press dir >test.txt

it will create test.txt file in the same location u r using dir command & the contents will be whatever u see in dir command


oh really? no option called mark huh?
and CTRL + C is not copy anymore?
yeah...
sure...

anandbohra
03-04-2008, 05:47 AM
oh really? no option called mark huh?
and CTRL + C is not copy anymore?
yeah...
sure...

yes dude in windows command prompt

when u right click on black screen u can see following item as right click option

Mark
Copy Enter
Paste
Select All
Scroll
Find...


& copy is disabled when u click mark & select the area u have to click enter instead of Ctrl+c to copy data to clipboard.


try it

I done this at my end that why challanging your quote.
OS- Windows XP SP2