FindFile

  • Thread starter Thread starter RJH
  • Start date Start date
R

RJH

Hello,
I'm using the code below to open a DOC file, then widen one of the columns
before adding the data to a new sheet.
I would like to modify the code to use 'FindFile' to present the browse
window and allow the user to select the file to open.
That said, how would I then code the widening of the 1st row of the selected
sheet before importing? I need to widen the 1st row to keep some name from
being truncated.

Workbooks.OpenText Filename:= _
"C:\Documents and Settings\rhoward\My Documents\CHROMM*.doc", Origin
_
:=xlWindows, StartRow:=1, DataType:=xlFixedWidth,
FieldInfo:=Array(Array _
(0, 1), Array(21, 1), Array(29, 1), Array(37, 1), Array(44, 1),
Array(52, 1), Array(60, 1), _
Array(68, 1), Array(73, 1))

Thanks for your help!

RJH
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top