
I hope srod will fix his webside.
He is a lazy bugger at the best of times!ts-soft wrote:I hope srod will fix his webside.
I just clicked the dropbox url and it downloaded w/o issue.coelhorb wrote:Please could you put ADOmate link available again? http://dl.dropbox.com/u/3086026/ADOmate.zip doesn't work any more and I can't find it anywhere on internet. The nxsoftware's site is out. Thanks and sorry for my poor english.
Yes, but most of the links aren't!ts-soft wrote:And http://www.nxsoftware.com/ is working again
Code: Select all
;The following structure is used in the iDispatch\Invoke() method call to receive detailed errors.
CompilerIf Defined(EXCEPINFO, #PB_Structure) = 0
CompilerIf #PB_Compiler_Processor = #PB_Processor_x64
Structure EXCEPINFO
wCode.w
wReserved.w
pad.b[4] ; Only on x64
bstrSource.i ;BSTR
bstrDescription.i
bstrHelpFile.i
dwHelpContext.l
pvReserved.i
pfnDeferredFillIn.COMate_ProtoDeferredFillIn
scode.l
pad2.b[4] ; Only on x64
EndStructure
CompilerElse
Structure EXCEPINFO
wCode.w
wReserved.w
bstrSource.i ;BSTR
bstrDescription.i
bstrHelpFile.i
dwHelpContext.l
pvReserved.i
pfnDeferredFillIn.COMate_ProtoDeferredFillIn
scode.l
EndStructure
CompilerEndIf
CompilerEndIf
Code: Select all
; ADOmate_OpenDatabase method - Line 1099
If SUCCEEDED(*connection\connectionObject\Invoke("Open('" + connection$ + "', " + user$ + ", " + password$ +")"))
Code: Select all
; ADOmate_OpenDatabase method - Line 1099
If *connection\connectionObject\Invoke("Open('" + connection$ + "', " + user$ + ", " + password$ +")") = #S_OK
Code: Select all
Macro SUCCEEDED(HRESULT)
HRESULT & $80000000 = 0
EndMacro
Macro FAILED(HRESULT)
HRESULT & $80000000
EndMacro
Ah, so that's what's going on.EDIT : yes I do think that PB x64 regards HRESULT as 64-bit integers rather than 32-bit longs. This would mean that PB x64 has all in-built interface methods which return HRESULT values incorrect.
Code: Select all
; The declaration:
Procedure.i ADOmate_DatabaseQuery(*connection._ADOmateConnection, request$, cursorType = #adOpenForwardOnly, cursorLocation = #adUseServer)
Code: Select all
; The definition (line 423):
If rset\SetProperty("CursorType = " + Str(cursorType)) = #S_OK And rset\SetProperty("CursorLocation = " + Str(cursorLocation)) = #S_OK And rset\Invoke("Open('" + request$ + "', " + Str(*connection\connectionObject) + " As COMateObject)") = #S_OK
Code: Select all
;/////////////////////////////////////////////////////////////////////////////////
;***ADOmate*** - access to OLEDB datasources.
;*============
;*
;*Database query demo.
;*This demo requires the "ado.mdb" database file.
;/////////////////////////////////////////////////////////////////////////////////
IncludePath "..\"
XIncludeFile "ADOmate.pbi"
databaseFile$ = "D:\test.mdb"
connectionString$ = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + databaseFile$ + ";"
User$ = ""
Password$ = "test"
;Attempt to open the database.
myConnection = ADOmate_OpenDatabase(connectionString$,User$,Password$)
If myConnection
;Attempt to execute a basic query.
SQL$ = "Select * from Test"
If ADOmate_DatabaseQuery(myConnection, SQL$, #adOpenStatic)
;Let us display a list of columns.
numColumns = ADOmate_DatabaseColumns(myConnection)
If numColumns
Debug "Columns : "
Debug "--------------"
For i = 0 To numColumns-1
Debug " " + ADOmate_DatabaseColumnName(myConnection, i) + " --> column type = " + Str(ADOmate_DatabaseColumnType(myConnection, i))
Next
Debug ""
EndIf
;Now examine all records retrieved in the recordset.
Debug "Rows : "
Debug "--------------"
While ADOmate_IsEOF(myConnection) = 0
ID$ = ADOmate_GetDatabaseString(myConnection, 0)
Integer$ = ADOmate_GetDatabaseString(myConnection, 1)
Text$ = ADOmate_GetDatabaseString(myConnection, 2)
Memo$ = ADOmate_GetDatabaseString(myConnection, 3)
Debug " (ID=" + ID$ + ", IntegerField=" + Integer$ + ", TextField=" + Text$ + ", MemoField=" + Memo$ + ")"
ADOmate_NextDatabaseRow(myConnection)
Wend
ADOmate_FinishDatabaseQuery(myConnection)
Else
MessageRequester("ADOmate error!", ADOmate_GetLastErrorDescription())
EndIf
ADOmate_CloseDatabase(myConnection)
Else
MessageRequester("ADOmate error!", ADOmate_GetLastErrorDescription())
EndIf
Code: Select all
[...]
connectionString$ = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + databaseFile$ + ";Jet OLEDB:Database Password=test"
;Attempt to open the database.
myConnection = ADOmate_OpenDatabase(connectionString$, "", "")
[...]