Click here to Skip to main content
15,924,039 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Can i develope Client Server Application with access Pin
Dave Kreskowiak12-Apr-05 12:24
mveDave Kreskowiak12-Apr-05 12:24 
GeneralRe: Can i develope Client Server Application with access Pin
rwestgraham12-Apr-05 14:15
rwestgraham12-Apr-05 14:15 
AnswerRe: Can i develope Client Server Application with access Pin
Abhaypppppppppp12-Apr-05 2:10
sussAbhaypppppppppp12-Apr-05 2:10 
AnswerRe: Can i develope Client Server Application with access Pin
vertig073012-Apr-05 4:10
vertig073012-Apr-05 4:10 
GeneralProblems Displaying Forms Pin
Chris Quick11-Apr-05 18:10
Chris Quick11-Apr-05 18:10 
GeneralRe: Problems Displaying Forms Pin
Chris Quick12-Apr-05 3:35
Chris Quick12-Apr-05 3:35 
Generalvb6 - SQL via IP Pin
mike2k511-Apr-05 16:03
mike2k511-Apr-05 16:03 
GeneralRe: vb6 - SQL via IP Pin
Dave Kreskowiak12-Apr-05 4:05
mveDave Kreskowiak12-Apr-05 4:05 
It's no different than any other connection to an SQL server. All you need to do is supply either the full DNS name to the server or the servers IP address:
Dim DBcon As New ADODB.Connection
Dim objCmd As New ADODB.Command
Dim objparameter As New ADODB.Parameter
Dim objRs As New ADODB.Recordset
    
    DBcon.ConnectionString = "Provider=sqloledb;" & _
        "server=[ServerName or IP Here];uid=UserId;pwd=Password;database=MyDatabase
    DBcon.CursorLocation = adUseClient
    DBcon.Open
    
    objparameter.Direction = adParamInput
    objparameter.Type = adVarChar
    objparameter.Size = 5
    objparameter.Value = "hello"
    objCmd.Parameters.Append objparameter
    
    objCmd.ActiveConnection = DBcon
    objCmd.CommandType = adCmdStoredProc
    objCmd.CommandText = "s_mysp"
    Set objRs = objCmd.Execute                       ' objCmd.Execute for no resultset
   
    set objRs.ActiveConnection = Nothing
    Set objCmd = Nothing
    DBcon.Close

Code snippet lifted from Nigel Rivett[^], without permission, of course.


RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome

GeneralRe: vb6 - SQL via IP Pin
mike2k512-Apr-05 5:59
mike2k512-Apr-05 5:59 
GeneralRe: vb6 - SQL via IP Pin
mike2k512-Apr-05 6:33
mike2k512-Apr-05 6:33 
GeneralRe: vb6 - SQL via IP Pin
Dave Kreskowiak12-Apr-05 6:48
mveDave Kreskowiak12-Apr-05 6:48 
GeneralReading a parallel port - Status Register Pin
add_23_200511-Apr-05 12:59
add_23_200511-Apr-05 12:59 
GeneralRe: Reading a parallel port - Status Register Pin
vertig073011-Apr-05 13:10
vertig073011-Apr-05 13:10 
GeneralRe: Reading a parallel port - Status Register Pin
Anonymous11-Apr-05 16:47
Anonymous11-Apr-05 16:47 
GeneralRe: Reading a parallel port - Status Register Pin
Anonymous11-Apr-05 16:50
Anonymous11-Apr-05 16:50 
GeneralRe: Reading a parallel port - Status Register Pin
Anonymous11-Apr-05 17:07
Anonymous11-Apr-05 17:07 
GeneralIntelligent graphic image analysis and comparison Pin
tempgp11-Apr-05 12:02
tempgp11-Apr-05 12:02 
QuestionCan someone please Help! Pin
joseuri2111-Apr-05 11:15
joseuri2111-Apr-05 11:15 
AnswerRe: Can someone please Help! Pin
vertig073011-Apr-05 13:08
vertig073011-Apr-05 13:08 
AnswerRe: Can someone please Help! Pin
Dave Kreskowiak11-Apr-05 16:48
mveDave Kreskowiak11-Apr-05 16:48 
GeneralShellExecute API Pin
Lisana11-Apr-05 10:26
Lisana11-Apr-05 10:26 
GeneralRe: ShellExecute API Pin
shinay11-Apr-05 10:49
shinay11-Apr-05 10:49 
GeneralRe: ShellExecute API Pin
Lisana11-Apr-05 11:01
Lisana11-Apr-05 11:01 
GeneralRe: ShellExecute API Pin
shinay11-Apr-05 11:12
shinay11-Apr-05 11:12 
GeneralRe: ShellExecute API Pin
shinay11-Apr-05 11:14
shinay11-Apr-05 11:14 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.