I have AutoCAD 2012. When I try to run a program that requires Visual Basic, I'm getting a message that states the following:
"The location of the Files Location Database must be the first item in "\SentinelVBA" File Path in Preference Menu. It is advisable to correct before proceeding."
SentinelVBA is a folder which houses an Access database called "SentinelDB.mdb".
When I go to Preferences, Files, Support file Search Path, it reads "C:\Documents and Settings\Administrator\my documents\pacs\pacsacadcustom2005\sentinelvba". It is the first item in the list. When I change "sentinelvba" in that path to "SentinelVBA" (notice the caps) the program works properly, until I close AutoCAD and restart. Then the lower case letters are back and it does not work properly until I change it again.
Any help is greatly appreciated.
Solved! Go to Solution.
My guess is to store database file name in your program
using Const directive like this:
Const mdbfile as String= "SentinelDB.mdb"
then i your sub routine you can load it directly
something like this:
mdbfile = MyFolderName & "\" & mdbfile
or without backslash if you've already added it to the folder path before
>> Then the lower case letters are back and it does not work properly until I change it again.
Have you tried to rename the folder on your harddisk to lower characters?
>> The location of the Files Location Database must be the first item in "\SentinelVBA"
Is this a 3rd-party application for AutoCAD that's suggesting you to set this as first path? Or who told you that this is the rule for getting it to work?
- alfred -
It doesn't seem to matter if the folder name is upper case, lower case or a combination. In Autocad 2012 I have to change the Support File Search Path in Options/Files to "C:\Documents and Settings\Administrator\my documents\pacs\pacsacadcustom2012\SentinelVBA" and not "sentinelvba". It doesn't matter if it's first or last in the Support File Search Path, so I don't know if the message "The location of the Files Location Database must be the first item in "\SentinelVBA" File Path in Preference Menu. It is advisable to correct before proceeding." is referring to that. By the way, that is a message that appears in Autocad.
This was some custom programming that someone did years ago. I don't know too much about how it works but I checked the cui in 2012 and it shows in the macro field "^C^C-vbarun main.MakeLegend". It seems to be running that macro in Visual Basic file "acad.dvb", which is in folder called "C:\Documents and Settings\Administrator\my documents\pacs\pacsacadcustom2005\SentinelVBA".
It works fine with Autocad 2007. The "Support File Search Path" will stay "SentinelVBA". But in 2012, it will always change back to lower case when it’s first opened, and it won't work until I change it.
if you can modify the VBA-file then check where the errormessage comes from and verify there how it tries (and fails) to access the MDB-file. If it compares foldernames then try to convert the verification-syntax to convert the foldernames first to upper-case and then do the comparision.
Second question: are you running 2012 on a 64bit os or 32bit. If 64bit you may have some troubles accessing the MDB-file as of missing drivers for ODBC-MDB access (at least there is >>>one way<<<, but not sure if the guy in 2005 has programmed it in that way).
- alfred -
This sounds suspicously like the original programmer is doing a literal string comparison on the paths, without considering character case. If the programmer isn't available, you might be able to hire somebody to check that other general updates/diagnostics. If you don't have access to the source code... you're pretty much hosed.
Haven't had time to do anything with this until now but, problem solved.
I searched the code and found this:
DBLocation = ParseFromList("SentinelVBA", preferences.Files.SupportPath, ";")
I changed SentinelVBA to sentinelvba and that did the trick.