[AccessD] Broken References in Runtime AXP

Charlotte Foust cfoust at infostatsystems.com
Fri Jul 18 11:16:53 CDT 2003


Shamil,

It's me again.  I've been rereading the MSKB article and noticed this
line:

>>
Access looks for a named value with the same name as the reference. If
there is a match, Access loads the reference from the path pointed to by
the named value.
>>

Now, that worries me because the Name property for the reference that's
giving me fits returns something like "RedemptionCDO" when the reference
is perceived as OK and something like "C:\Some Folder\RedemptionCDO.mde"
when the reference is perceived as broken.  So if I name the key
"RedemptionCDO.mde", will Access find it when the reference is broken or
will it be looking for "C:\Some Folder\RedemptionCDO.mde" instead?

Regards,

Gertrude Stein


-----Original Message-----
From: Shamil Salakhetdinov [mailto:shamil at smsconsulting.spb.ru] 
Sent: Thursday, July 17, 2003 7:28 PM
To: Access Developers discussion and problem solving
Subject: Re: [AccessD] Broken References in Runtime AXP


> I'm just going off to sit in the corner and gibber.
Charlotte,

I'm sorry I don't particiapte actively in this thread - please reread
very carefully this paragrapgh of MS Access online help:

<<<<<<<<
  d.. If you set a reference to a project or type library from Microsoft
Access and then move the file that contains that project or type library
to a different folder, Microsoft Access will attempt to locate the file
and reestablish the reference. If the RefLibPaths key exists in the
registry, Microsoft Access will first search there. If there's no
matching entry, Microsoft Access will search for the file first in the
current folder, then in all the folders on the drive. You can create the
RefLibPaths key by using the Registry Editor in Windows, under the
registry key
\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\version\Access. For more
information about using the Registry Editor, see your Windows
documentation.
>>>>>>>>
I think this is the key sentence "Microsoft Access will search for the
file first in the current folder, then in all the folders on the drive."
- I mean that MS Access will search first in the CURRENT folder, then in
ALL the folders on the drive. I don't think it's 100% accurate - if MS
Access have been searching in ALL the folders on the drive for a broken
reference then it would have worked ages to resolve such refs on MS
Access program start-up. So I think it searches first in the current
folder and then starting from the current folder in all the subfolders
and probably in all the parent folders of the current folder and their
subfolders and then (of before?) in all the folders listed in PATH
environment variable. This extra-intelligence of MS Access sometimes
drives developers crazy...

Solution, which I used was to develop MS Access projects on different
drive(s)/under different paths than deployment drive/directory and NEVER
put referenced MS Access databases in the directories from PATH
environment variable.

I've also used RefLibPaths separatley and with SageKey scripts to
install
runtime(Access97) and its environment. Please reread again the sentence
above - when RefLibPaths is used then MS Access FIRST searches for
broken references in the directoriy from RefLibpaths...

But if the reference ISN'T broken then  even if RefLibPaths is specified
MS Access DOESN'T use its value for resolve a reference on runtime - I
think this is contr-intuitive and this is why is good to force the refs
being broken by having your development drive/directory different from
deployment ones...

Why you can't use RefLibPaths with your rutime environment?

Shamil



----- Original Message -----
From: "Charlotte Foust" <cfoust at infostatsystems.com>
To: "Access Developers discussion and problem solving"
<accessd at databaseadvisors.com>
Sent: Friday, July 18, 2003 4:38 AM
Subject: RE: [AccessD] Broken References in Runtime AXP


> Well, I'm now officially round the bend.  I just sat here and kept 
> seeing the idiot thing report that it found the broken reference in 
> the right location, which is where the file *is* but not where the 
> reference actually pointed.  The FullPath property of the reference 
> returned the right location instead of the broken one!  Then I watched

> the referenced library pop up in the project explorer even though it 
> wasn't there when I opened the project!  I'm just going off to sit in 
> the corner and gibber.
>
> I'm running Windows XP and I wonder if that has anything to do with 
> it. I've also seen it report a broken reference and say it fixed it in

> runtime and have the app appear to run OK but then when I opened it 
> normally and held down the shift key, the reference was broken.  
> Usually if it's broken it stays broken ... But not always!  
> Aaarrrgggghhhh!!!
>
> Charlotte Foust _______________________________________________
> 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


More information about the AccessD mailing list