[AccessD] Common Dialog

Lawrence Mrazek lmrazek at lcm-res.com
Fri Jan 8 09:59:35 CST 2010


Thanks to everyone for your responses; I had completely forgotten about the
filescriptingobject and learned some new techniques as well.

Thanks!

Larry Mrazek
ph. 314-432-5886
lmrazek at lcm-res.com
http://www.lcm-res.com


-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Dan Waters
Sent: Thursday, January 07, 2010 11:51 AM
To: 'Access Developers discussion and problem solving'
Subject: Re: [AccessD] Common Dialog

Larry,

You can use FileScriptingObject to do a lot of file management tasks pretty
easily.

First, set a reference to Microsoft Scripting Runtime (scrrun.dll)

In your procedure:

    Dim fso as Object

    Set fso = CreateObject("Scripting.FileSystemObject")

    '--  get full file path

    stgFileName = fso.GetFileName(stgFullPathToFile)


You can review all the FileSystemObject methods here:
http://msdn.microsoft.com/en-us/library/6tkce7xa%28VS.85%29.aspx

Hope this helps,
Dan

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Lawrence Mrazek
Sent: Thursday, January 07, 2010 11:00 AM
To: Access Developers discussion and problem solving
Subject: [AccessD] Common Dialog

Hi Folks:

I'm the API from http://www.mvps.org/access/api/api0001.htm, and can't seem 
to remember how to ONLY retrieve the filename (not the filename and path 
using the API. 

I suppose that if I know the directory, I can use some functions to trim 
off the directory path, but in this case I might not always be looking for 
the files in a default directory.

Any hints/guidance would be appreciated. 

Larry Mrazek
lmrazek at lcm-res.com
314-432-5886



-- 
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com

-- 
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com
No virus found in this incoming message.
Checked by AVG - www.avg.com 
Version: 9.0.725 / Virus Database: 270.14.129/2606 - Release Date: 01/07/10
13:35:00





More information about the AccessD mailing list