473,657 Members | 2,624 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How To Get Frontend and Backend UNC Paths?

I'm using the following to get the FE and BE database paths.

FEPath = DBEngine.Worksp aces(0).Databas es(0).Name

BEPath = Mid([DBEngine].[Workspaces](0).[Databases](0).[TableDefs]
("Admin").[Connect], 11)

These work well but they only retrieve the Drive Letter paths. Is
there a simple way to retrieve the UNC paths?


Jul 17 '08 #1
6 4266
On Wed, 16 Jul 2008 17:53:12 -0700 (PDT), Wayne <cq*******@volc anomail.com>
wrote:
>I'm using the following to get the FE and BE database paths.

FEPath = DBEngine.Worksp aces(0).Databas es(0).Name

BEPath = Mid([DBEngine].[Workspaces](0).[Databases](0).[TableDefs]
("Admin").[Connect], 11)

These work well but they only retrieve the Drive Letter paths. Is
there a simple way to retrieve the UNC paths?
It depends on how the table was linked initially.
If the table was linked using a drive letter, the connect string will return the
drive letter.
If the table was linked using a UNC path, the connect string will return the UNC
path.

There is no inbuilt conversion function, it is just a text string.
Wayne Gillespie
Gosford NSW Australia
Jul 17 '08 #2
Wayne wrote:
I'm using the following to get the FE and BE database paths.

FEPath = DBEngine.Worksp aces(0).Databas es(0).Name

BEPath = Mid([DBEngine].[Workspaces](0).[Databases](0).[TableDefs]
("Admin").[Connect], 11)

These work well but they only retrieve the Drive Letter paths. Is
there a simple way to retrieve the UNC paths?
This should help. http://www.mvps.org/access/api/api0003.htm

Eye of the Tiger
http://www.youtube.com/watch?v=eMsBU0zvMqc
Jul 17 '08 #3
Thanks for the help Wayne and Salad.

Jul 17 '08 #4
JvC
Wayne,

You can use CurrentDb.Name to get the FEPath. It's a bit shorter!

Wayne expressed precisely :
I'm using the following to get the FE and BE database paths.

FEPath = DBEngine.Worksp aces(0).Databas es(0).Name

BEPath = Mid([DBEngine].[Workspaces](0).[Databases](0).[TableDefs]
("Admin").[Connect], 11)

These work well but they only retrieve the Drive Letter paths. Is
there a simple way to retrieve the UNC paths?

Jul 17 '08 #5
"Wayne" <cq*******@volc anomail.comwrot e in message
news:dd******** *************** ***********@l42 g2000hsc.google groups.com...
I'm using the following to get the FE and BE database paths.

FEPath = DBEngine.Worksp aces(0).Databas es(0).Name

BEPath = Mid([DBEngine].[Workspaces](0).[Databases](0).[TableDefs]
("Admin").[Connect], 11)

These work well but they only retrieve the Drive Letter paths. Is
there a simple way to retrieve the UNC paths?
Yes. All it requires is a little copy 'n paste from here:

http://www.smccall.demon.co.uk/MiscApi.htm#UNCpath
Jul 17 '08 #6
JvC <jo******@earth link.netwrote in
news:Pp******** *********@newsf e04.iad:
You can use CurrentDb.Name to get the FEPath. It's a bit shorter!
And more reliable, since it can never return anything but the
database open in the Access UI. DBEngine(0)(0) can in rare
circumstances (such as just after running a wizard) return a
different database.

--
David W. Fenton http://www.dfenton.com/
usenet at dfenton dot com http://www.dfenton.com/DFA/
Jul 17 '08 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
2526
by: w | last post by:
Hello all!!! For a year and a half now, we have been developing different Access 2000 applications. Most of them are access frontend and access backends. Some of them have SQL server 2000 as a backend. There is one application, which consists of a frontend and 3 backend mdb's. Different companies (80) are using the application: 1. Companies with just one pc and one user. 2. Companies with a Cytrix environment.
1
2345
by: matt bourke | last post by:
Hi, Can you please tell me what the advantage is of using an access backend with a VB frontend OVER access as a frontend and backend. M
16
2191
by: Wayne Aprato | last post by:
I have several Access 97 databases which are split into front end and back end running off a server. The front end mde is shared by 2 or 3 - absolute maximum of 6 concurrent users. This scenario has been working flawlessly for about 2 years. I am now at a point where these databases need to be converted to Access 2003. I think I read somewhere on this forum that the newer versions of Access are not as tolerant to multiple users...
3
2092
by: DD | last post by:
Hi I have a split database, that is packaged and used in a runtime enviroment. I want to make it easier for the user, a button on the frontend "Export Backend" They can click on the button then search for the backend and then save the backend to a CD or Floppy.
2
2353
by: Sukkel | last post by:
When I define relations in the Backend of my Database, everything works fine. I get these funny lines (with 1 and "OO") between the fields of the different table that indicate a one to many relationship. Then, when I try to build a query in the frontend, these signs disappear in the query design window, and as a consequence, the form wizzard based on such a query won´t let me construct a subform in the main form. I could make my...
42
5622
by: PC Datasheet | last post by:
I have zero experience with using a SQL database for a backend and Access for a frontend. I have some questions: 1. Does an SQL database have tables? 2. How does Access connect to the data in an SQL database? Linking, importing, or ??? 3. Earlier today there was a thread regarding DAO and ADO. In the thread it was said that ADO is very useful when the backend is a SQL database. Could someone explain that?
5
1816
by: ordy62 | last post by:
I split a database to a FE and BE but the issue is the network shares. I have several groups that need to view this database but the network paths to database are different for example. Network drive F:\Projects\shared\database_be.mdb (original location) Group 2 L:\Department Folder\Projects\shared\database_mdb
9
2189
by: philelpko | last post by:
Good Morning all, Lost once again which is becoming a common occurance atm. My database has successfully been broken into a frontend and a backend db. A problem has now arisen as it has become apparant that db managers need to add additional field names to a table. I cant find anyway that access will allow you to create additional fields to already existing tables in the backend from the frontend. In a nutshell, is it possible to...
15
1639
by: Michiel Rapati-Kekkonen | last post by:
my understanding is that you can copy a backend on condition that all recordsets are closed. But it is not what I experience. Is there a way to find out what keeps the backend connected? (maybe I forgot a recordset somewhere) thanks for any input Michiel
0
8407
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8837
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8739
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8612
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7347
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6175
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5638
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
2
1969
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1732
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.