472,341 Members | 2,044 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,341 software developers and data experts.

linking to a password protected database

please help im new at access programming and i just got this project
dropped in my lap because the old programmer quit. i've been doing ok
so far but now i need to add code to an existing database that is used
to connect to other databases and generate reports. below is sample
code of how the database does the linking i hope i give you enough
info to help me but if not let me know and i will give more.

Sub txtShipDataFileSub()

Dim tblShipData As TableDef
Dim ThisDB As Database
Dim Index As Integer

If FileExists(txtShipDataFile.Value) = True Then
StatusWindow_Display "Loading ship data..."
Index = Len(Trim(txtShipDataFile.Value))
Do While Mid(Trim(txtShipDataFile.Value), Index, 1) <>
"\" And Index > 1
Index = Index - 1
Loop
ChangeConfigSetting "ShipDir",
Left(Trim(txtShipDataFile.Value), Index)

StatusWindow_AddMessage "Linking FAST tables..."

Set ThisDB = DBEngine.Workspaces(0).Databases(0)
ConnectTable ThisDB.TableDefs![c2BulkParts],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST CSMP tables..."
ConnectTable ThisDB.TableDefs![c2CSMPED],
txtShipDataFile.Value
If FileExists(GetConfigSetting("ShipDir") &
"config.dbf") Then
ConnectTable ThisDB.TableDefs![tblCSRRConfig],
GetConfigSetting("ShipDir"), "FOXPRO 2.6;DATABASE="
ChangeConfigSetting "UseConfigNames", True
Else
ChangeConfigSetting "UseConfigNames", False
End If
'add new link tables

StatusWindow_AddMessage "Linking FAST parts tables..."
ConnectTable ThisDB.TableDefs![c2Parts],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST SCLSIS
tables..."
ConnectTable ThisDB.TableDefs![c2SCLSIS],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST ShipInfo
tables..."
ConnectTable ThisDB.TableDefs![c2ShipInfo],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST System
tables..."
ConnectTable ThisDB.TableDefs![c2System],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST TrainingNames
tables..."
ConnectTable ThisDB.TableDefs![c2TrainingNames],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST CtrlSheetRanges
tables..."
ConnectTable ThisDB.TableDefs![C5_CtrlSheetRanges],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST EquipConfig
tables..."
ConnectTable ThisDB.TableDefs![C5_EquipConfig],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST Evaluators
tables..."
ConnectTable ThisDB.TableDefs![C5_Evaluators],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST FinalReportInfo
tables..."
ConnectTable ThisDB.TableDefs![C5_FinalReportInfo],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST FollowUps
tables..."
ConnectTable ThisDB.TableDefs![C5_FollowUps],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST MasterEvals
tables..."
ConnectTable ThisDB.TableDefs![C5_MasterEvals],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST MasterQuals
tables..."
ConnectTable ThisDB.TableDefs![C5_MasterQuals],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST MCL tables..."
ConnectTable ThisDB.TableDefs![C5_MCL],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST Qualifications
tables..."
ConnectTable ThisDB.TableDefs![C5_Qualifications],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST SpecialRemarks
tables..."
ConnectTable ThisDB.TableDefs![C5_SpecialRemarks],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST TestPlanRanges
tables..."
ConnectTable ThisDB.TableDefs![C5_TestPlanRanges],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST TestPlans
tables..."
ConnectTable ThisDB.TableDefs![C5_TestPlans],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST EocInfo
tables..."
'ConnectTable ThisDB.TableDefs![C5_VisitInfo],
txtShipDataFile.Value
ConnectTable ThisDB.TableDefs![EocInfo],
txtShipDataFile.Value
StatusWindow_AddMessage "Linking FAST Training
tables..."
ConnectTable ThisDB.TableDefs![C5_Training],
txtShipDataFile.Value
EraseTable "tblTOCIndividualReportsSource"
RecordCounters_CloseTable
DeleteQueries
AppendC2
StatusWindow_AddMessage "Linking FAST tables
complete..."

StatusWindow_Done

End If
End If

End Sub
Nov 12 '05 #1
0 2079

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

Similar topics

9
by: Ben Allen | last post by:
Hi, I want to create a password protected page to administer my site from (the news is read from a mySQL database and I have created a PHP form to...
0
by: mikehernandez99 | last post by:
I have an Access 2003 application that consists of a front end MDE with linked tables to a password protected MDB. I try to use ADO code for this...
4
by: kthiagar | last post by:
Hi I am trying to connect to a password protected access file from VB.NET. I have no problem in connecting to Access, if I remove the password. ...
2
by: Matthew Wells | last post by:
Hello, I have an ADO connection object connected to an external ms access password protected database. I am trying to execute a delete statement...
5
by: Joe-Paul | last post by:
Hi: I'm using VB 6.0 with an Access 2000 database. I set the password in the Access database to: abcdef1234. Then, using a MDIform, during the...
3
by: -xx- | last post by:
Hi, I am new to c# and just trying out c# with ms access. First problem i encountered is how do i open up ms access that has password. Here...
6
by: bmoore | last post by:
Greetings, This seems like it should be a simple problem, but I'm new to Access and my digging hasn't yielded a solution. I would like to create...
8
by: gngui | last post by:
Hi, Please Please Please anyone out there, if you have a solution, i will highly appreciate as i have searched the internet for 5 days now with no...
16
by: Greg (codepug | last post by:
If one converts that .mdb into an .mde the code is secure but the tables can still be imported. Just for Very Basic protection, I have placed a...
0
better678
by: better678 | last post by:
Question: Discuss your understanding of the Java platform. Is the statement "Java is interpreted" correct? Answer: Java is an object-oriented...
0
by: teenabhardwaj | last post by:
How would one discover a valid source for learning news, comfort, and help for engineering designs? Covering through piles of books takes a lot of...
0
by: Kemmylinns12 | last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and...
0
by: CD Tom | last post by:
This only shows up in access runtime. When a user select a report from my report menu when they close the report they get a menu I've called Add-ins...
0
by: Naresh1 | last post by:
What is WebLogic Admin Training? WebLogic Admin Training is a specialized program designed to equip individuals with the skills and knowledge...
0
jalbright99669
by: jalbright99669 | last post by:
Am having a bit of a time with URL Rewrite. I need to incorporate http to https redirect with a reverse proxy. I have the URL Rewrite rules made...
0
by: antdb | last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine In the overall architecture, a new "hyper-convergence" concept was...
0
by: Matthew3360 | last post by:
Hi there. I have been struggling to find out how to use a variable as my location in my header redirect function. Here is my code. ...
0
by: Arjunsri | last post by:
I have a Redshift database that I need to use as an import data source. I have configured the DSN connection using the server, port, database, and...

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.