Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Modules / DAO / VBA / December 2006

Tip: Looking for answers? Try searching our database.

Open a map

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
wilfried - 24 Dec 2006 11:06 GMT
I want to open a map in a mdb with vba which is linked to a result of a
field in the active form

Field on the active form shows 3 the map to find is P_3

The path is C:\wilfried\Stamps\P_3

And mery Christmas for everyone
Brian - 24 Dec 2006 17:12 GMT
Assuming the map to which you refer is some type of file on the computer,
what is the format of the map file? That is, what program is used to open the
map?

> I want to open a map in a mdb with vba which is linked to a result of a
> field in the active form
[quoted text clipped - 4 lines]
>
> And mery Christmas for everyone
wilfried - 25 Dec 2006 08:50 GMT
I only  want to cunsult the map corresponding with the field StampsId
on the active form so that I could see what files are in the map: word
documentens, JPG and BMP files

I want to do so with a command button but I don't now how to do so (I
think I have to do so with a VBA code but I don't know very much about
it).

Field stampsId on the active form shows "3" the map to find is "P_3"
Field stampsId on the active form shows "4" the map to find is "P_4"

All the maps are in the following path: C:\wilfried\stamps\ P_X (X
stands for the number of each stamp=stampsId)

Thanks for your quick repley

Brian schreef:

> Assuming the map to which you refer is some type of file on the computer,
> what is the format of the map file? That is, what program is used to open the
[quoted text clipped - 8 lines]
> >
> > And mery Christmas for everyone
Brian - 25 Dec 2006 17:00 GMT
I am just a little confused about your usage of the word "map". You are
evidently not referring to a map file. It appears to me that you want to see
the list of files in the folder C:\wilfried\Stamps\P_3. Is this correct?

> I only  want to cunsult the map corresponding with the field StampsId
> on the active form so that I could see what files are in the map: word
[quoted text clipped - 26 lines]
> > >
> > > And mery Christmas for everyone
Brian - 28 Dec 2006 01:36 GMT
If you want to show the contents of the folder, use the Dir command like this:

Private Sub Command3_Click()
Dim DirPath As String
Dim FileName As String
DirPath = "C:\wilfried\stamps\ P_3\*"
FileName = Dir(DirPath) 'get first file name
Do While FileName <> ""
   MsgBox FileName
   FileName = Dir() 'get next file name
Loop
End Sub

This will list each file in turn. To generate a list, either append each
entry to a table, and then run a query or report to show the contents of the
table, or assign the values to an array and show the contents of the array
when done the loop.

> I only  want to cunsult the map corresponding with the field StampsId
> on the active form so that I could see what files are in the map: word
[quoted text clipped - 26 lines]
> > >
> > > And mery Christmas for everyone
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.