Click here to Skip to main content
15,914,488 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: objectdatasource has no values to insert Pin
dr S.A.f.14-Apr-06 8:20
dr S.A.f.14-Apr-06 8:20 
QuestionVb 6 and access 2000 in LAN Pin
arunendra14-Apr-06 2:11
arunendra14-Apr-06 2:11 
AnswerRe: Vb 6 and access 2000 in LAN Pin
Dave Kreskowiak14-Apr-06 3:34
mveDave Kreskowiak14-Apr-06 3:34 
GeneralRe: Vb 6 and access 2000 in LAN Pin
arunendra14-Apr-06 5:15
arunendra14-Apr-06 5:15 
GeneralRe: Vb 6 and access 2000 in LAN Pin
Dave Kreskowiak14-Apr-06 6:43
mveDave Kreskowiak14-Apr-06 6:43 
GeneralRe: Vb 6 and access 2000 in LAN Pin
arunendra14-Apr-06 7:10
arunendra14-Apr-06 7:10 
GeneralRe: Vb 6 and access 2000 in LAN Pin
Dave Kreskowiak14-Apr-06 7:14
mveDave Kreskowiak14-Apr-06 7:14 
GeneralRe: Vb 6 and access 2000 in LAN Pin
arunendra14-Apr-06 23:35
arunendra14-Apr-06 23:35 
Thanks Dave.
I am out of my setup and so couldnt try it, but I will follow your instructions and will report it back.
In the mean while, can you help me in a very different subject, as I found this to be amazing, I never thought I will find someone who will answer my questions, and so I am bursting with all the queries, I am sorry for that , but i am trying my best to filter them and send you something that is absolutely impossible for me to do.
I have a code for compacting which uses jet engine,(there was a code which was working fine but was in DAO, and I found some errors occuring in my project and also in the crystal report, so i thought of going on with ado only), the code if changed a little works fine, i dont remeber what changes i had done but it can't put the password back to the newly created mdb file, so i am sending the original code i got , please see what I have to do.
''''''''''''''''''''' the code '''''''''''''''''''''''''''''''''''''
Public Function CompactAndRepairDB(sSource As String, _
sDestination As String, _
Optional sSecurity As String, _
Optional sUser As String = "Admin", _
Optional sPassword As String, _
Optional lDestinationVersion As Long) As Boolean

Dim sCompactPart1 As String
Dim sCompactPart2 As String
Dim oJet As JRO.JetEngine

' Put together the provider string for the source database
sCompactPart1 = "Provider=Microsoft.Jet.OLEDB.4.0" & _
";Data Source=" & sSource & _
";User Id=" & sUser & _
";Password=" & sPassword

' If the database has a user-level security file, add the
' details
If sSecurity <> "" Then
sCompactPart1 = sCompactPart1 & _
";Jet OLEDB:System database=" & sSecurity & ";"
' Else
' sCompactPart1 = sCompactPart1 & _
' ";Jet OLEDB:System database=false ;"
End If

' Put together the provider string for the destination
' database
sCompactPart2 = "Provider=Microsoft.Jet.OLEDB.4.0" & _
";Data Source=" & sDestination & ";Persist Security Info=False;Jet OLEDB:Database Password=bill1234"

' The destination database will end up in the latest version
' of jet, unless a specific version has been requested;
' 1 = Jet 1.0, 2 = Jet 1.1, 3 = Jet 2.x, 4 = Jet 3.x,
' 5 = Jet 4.x etc
If lDestinationVersion <> 0 Then
sCompactPart2 = sCompactPart2 & _
";Jet OLEDB:Engine Type=" & lDestinationVersion
End If

' Compact and repair the database
Set oJet = New JRO.JetEngine
oJet.CompactDatabase sCompactPart1, sCompactPart2
Set oJet = Nothing

CompactAndRepairDB = True
End Function

this code produces the following error number :-2147217843
and the following error msg :
"Cannot start your application. The workgroup information file is missing or opened exclusively by another user."
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Regards
arunendra
GeneralRe: Vb 6 and access 2000 in LAN Pin
Dave Kreskowiak15-Apr-06 3:37
mveDave Kreskowiak15-Apr-06 3:37 
GeneralRe: Vb 6 and access 2000 in LAN Pin
arunendra15-Apr-06 5:18
arunendra15-Apr-06 5:18 
GeneralRe: Vb 6 and access 2000 in LAN Pin
Dave Kreskowiak15-Apr-06 6:47
mveDave Kreskowiak15-Apr-06 6:47 
GeneralRe: Vb 6 and access 2000 in LAN Pin
arunendra16-Apr-06 2:26
arunendra16-Apr-06 2:26 
GeneralRe: Vb 6 and access 2000 in LAN Pin
Dave Kreskowiak16-Apr-06 10:24
mveDave Kreskowiak16-Apr-06 10:24 
GeneralRe: Vb 6 and access 2000 in LAN Pin
arunendra17-Apr-06 0:02
arunendra17-Apr-06 0:02 
GeneralRe: Vb 6 and access 2000 in LAN Pin
Dave Kreskowiak17-Apr-06 2:56
mveDave Kreskowiak17-Apr-06 2:56 
Questionhotmail account Pin
TAREQ F ABUZUHRI14-Apr-06 2:06
TAREQ F ABUZUHRI14-Apr-06 2:06 
GeneralRe: hotmail account Pin
Guffa14-Apr-06 2:42
Guffa14-Apr-06 2:42 
AnswerRe: hotmail account Pin
Dave Kreskowiak14-Apr-06 4:32
mveDave Kreskowiak14-Apr-06 4:32 
Questionerror in executing site from server(its urgent) Pin
Amit Agarrwal13-Apr-06 23:35
Amit Agarrwal13-Apr-06 23:35 
AnswerRe: error in executing site from server(its urgent) Pin
CWIZO14-Apr-06 2:35
CWIZO14-Apr-06 2:35 
Questionsetup and deployment Pin
naeeemkhan13-Apr-06 20:44
naeeemkhan13-Apr-06 20:44 
AnswerRe: setup and deployment Pin
Mekong River13-Apr-06 23:21
Mekong River13-Apr-06 23:21 
GeneralRe: setup and deployment Pin
arunendra14-Apr-06 2:13
arunendra14-Apr-06 2:13 
GeneralRe: setup and deployment Pin
Mekong River14-Apr-06 16:40
Mekong River14-Apr-06 16:40 
AnswerRe: setup and deployment Pin
Dave Kreskowiak14-Apr-06 4:33
mveDave Kreskowiak14-Apr-06 4:33 

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.