D
Derek Dowle
I am using office excel 2003
I have a single worksheet workbook which is a database. Each record of the
database contains a file name and its path. The idea is that if the user
double-clicks on a cell containing the file name then the file opens. The
database contains various file types including Word, Excel, Project,
PowerPoint, pdfs, etc.
I have considered using hyperlinks, but have ruled the idea out as at the
end of the day they will be thousands of them. Code will more easily get
around changes of file path or file name.
I have written the code to establish that the file and the path exist, but I
have not been able to write the code to open the file.
From research I have found code using:
Dim oWord As Word.Application
But I get a compile error: User-defined type not defined.
Can anyone please advise how I can overcome this error?
It appears from looking at examples that separate lines of code may be
needed for each file type. Is this the case and how will the code differ
for each file type?
Many thanks in anticipation!
I have a single worksheet workbook which is a database. Each record of the
database contains a file name and its path. The idea is that if the user
double-clicks on a cell containing the file name then the file opens. The
database contains various file types including Word, Excel, Project,
PowerPoint, pdfs, etc.
I have considered using hyperlinks, but have ruled the idea out as at the
end of the day they will be thousands of them. Code will more easily get
around changes of file path or file name.
I have written the code to establish that the file and the path exist, but I
have not been able to write the code to open the file.
From research I have found code using:
Dim oWord As Word.Application
But I get a compile error: User-defined type not defined.
Can anyone please advise how I can overcome this error?
It appears from looking at examples that separate lines of code may be
needed for each file type. Is this the case and how will the code differ
for each file type?
Many thanks in anticipation!