Re: List box display of external text files
From: richardb (richardb_at_discussions.microsoft.com)
Date: 01/23/05
- Next message: richardb: "Re: List box display of external text files"
- Previous message: richardb: "Re: List box display of external text files"
- In reply to: Douglas J. Steele: "Re: List box display of external text files"
- Next in thread: Douglas J. Steele: "Re: List box display of external text files"
- Reply: Douglas J. Steele: "Re: List box display of external text files"
- Messages sorted by: [ date ] [ thread ]
Date: Sun, 23 Jan 2005 05:29:02 -0800
Douglas,
I have tried the code by copying it into a module and then attempted to run
the TestIt function. I must have some missing libraries. For CurDir, I get
the Compile Error "Can't find project or Library". This refers to
compatui.dll. Even the "string" function produces the same. I guess I need to
install an option or library.
"Douglas J. Steele" wrote:
> While it's true that the Common Dialog Control doesn't require much code,
> it's also extremely prone to versioning problems. Even if you aren't
> distributing your application to others, if you install new software on your
> workstation, the CDC may stop working.
>
> It really doesn't matter whether you understand the code to work with the
> API. Let's face it, you have no idea what code is "under the covers" when
> you use the CDC! Copy the code from the given reference into a module, and
> then you need 2 lines of code to use it (4 if you count the declarations):
>
> Dim strFilter As String
> Dim strInputFileName as String
>
> strFilter = ahtAddFilterItem(strFilter, "Text Files (*.txt)", "*.txt")
> strInputFileName = ahtCommonFileOpenSave( _
> Filter:=strFilter, OpenFile:=True, _
> DialogTitle:="Please select an input file...", _
> Flags:=ahtOFN_HIDEREADONLY)
>
>
> --
> Doug Steele, Microsoft Access MVP
> http://I.Am/DougSteele
> (no e-mails, please!)
>
>
>
> "richardb" <richardb@discussions.microsoft.com> wrote in message
> news:CE57A798-C82F-4F12-8704-47515CD7E79C@microsoft.com...
> > Because I don't remember the Common Dialog Control requiring me to write
> > that
> > huge amount of code and I could not understand the code. I recall that
> > there
> > is someway to use the CDC that is pretty straight forward. I don't know
> > what
> > I'm missing here.
> >
> > "John Nurick" wrote:
> >
> >> Why not try the link I sent you?
> >>
> >> On Sat, 22 Jan 2005 17:13:03 -0800, "richardb"
> >> <richardb@discussions.microsoft.com> wrote:
> >>
> >> >I looked under "More Controls" button but do not see the Common Dialog
> >> >Control. Yes, you remind me that it would be the best solution, but I
> >> >can't
> >> >locate it.
> >> >
> >> >"John Nurick" wrote:
> >> >
> >> >> Hi Richard,
> >> >>
> >> >> It's probably simpler to use the standard Windows File Open dialog to
> >> >> get the filename. You can set a filter for the file type and also the
> >> >> initial directory. See http://www.mvps.org/access/api/api0001.htm.
> >> >>
> >> >> On Fri, 21 Jan 2005 06:17:04 -0800, "richardb"
> >> >> <richardb@discussions.microsoft.com> wrote:
> >> >>
> >> >> >I would like to create a list box on a form that will display the
> >> >> >external
> >> >> >files of type *.txt located in a certain folder. I would appreciate
> >> >> >help how
> >> >> >to do this.
> >> >> >
> >> >> >My intention is to import the selected file into an Access Table. I
> >> >> >think I
> >> >> >can do that part but any suggestions would be helpful.
> >> >> >
> >> >> >Thank you, Richard
> >> >>
> >> >> --
> >> >> John Nurick [Microsoft Access MVP]
> >> >>
> >> >> Please respond in the newgroup and not by email.
>
>
>
- Next message: richardb: "Re: List box display of external text files"
- Previous message: richardb: "Re: List box display of external text files"
- In reply to: Douglas J. Steele: "Re: List box display of external text files"
- Next in thread: Douglas J. Steele: "Re: List box display of external text files"
- Reply: Douglas J. Steele: "Re: List box display of external text files"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|