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 / SQL Server / ADP / November 2005

Tip: Looking for answers? Try searching our database.

cancel  system login prompt

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Sam - 29 Nov 2005 09:17 GMT
the access to the application is with sql server Authentication
for login i use a login form
but before it opsen's there is a system login prompt
how can i cancel this prompt?

thanks
giorgio rancati - 29 Nov 2005 09:44 GMT
Hi Sam,

before closing the project, clear the connection string
----
Currentproject.Openconnection ""
----

bye
Signature

Giorgio Rancati
[Office Access MVP]

> the access to the application is with sql server Authentication
> for login i use a login form
> but before it opsen's there is a system login prompt
> how can i cancel this prompt?
>
> thanks
Sam - 29 Nov 2005 10:24 GMT
It's ok
but now their is a new problem
the login form supose to read user name from a connected table
but because of canceling the system login prompt the table is yet
unconnected
when login form activate

> Hi Sam,
>
[quoted text clipped - 10 lines]
>>
>> thanks
giorgio rancati - 29 Nov 2005 16:10 GMT
Hi Sam.

Before open the login form, you can reconnect the project or read the table
in a separate connection to the server, then reconnect the progect

Open a recordset in separate connection
-----
Dim Cn As ADODB.Connection
Dim Rs As ADODB.Recordset
Set Cn = New ADODB.Connection
Set Rs = New ADODB.Recordset

Cn.Open "Provider=SQLOLEDB.1" & _
     ";Data Source=ServerName" & _
     ";Initial Catalog=DbName" & _
     ";User Id=UserName" & _
     ";Password=UserPassword"

Rs.Open "Select * From Tablename", Cn, adOpenKeyset, adLockOptimistic
......
......
Rs.close
Set Rs=Nothing
Cn.Close
Set Cn=Nothing

----

reconnect the project
----
If Currentproject.IsConnected=False Then
  Currentproject.OpenConnection _
     "Provider=SQLOLEDB.1" & _
     ";Data Source=ServerName" & _
     ";Initial Catalog=DbName" & _
     ";User Id=UserName" & _
     ";Password=UserPassword"
End if
----

bye
Signature

Giorgio Rancati
[Office Access MVP]

> It's ok
> but now their is a new problem
> the login form supose to read user name from a connected table
> but because of canceling the system login prompt the table is yet
> unconnected
> when login form activate
 
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.