I have upgrade to MDAC 2.8, which could also found on Microsoft website. The problem of MDB_AddParam(string, string) still exist. when I ran the program, DBP report a error message said "Could not understand command at line 8". Same error is occared when i ran the line
text,20,60,MDB_GetRowDataByColName(0,"Strength")
sync on;sync rate 0
sConn as string
sConn = "Jet OLEDB:Global Partial Bulk Ops=2;" +"Jet OLEDB:Registry Path=;" +"Jet OLEDB:Database Locking Mode=1;" +"Jet OLEDB:Database Password=;" + "Data Source=" + ".\db1.mdb;" +"Password=;Jet OLEDB:Engine Type=5;" +"Jet OLEDB:Global Bulk Transactions=1;" +"Provider=Microsoft.Jet.OLEDB.4.0;" +"Jet OLEDB:System database=;" +"Jet OLEDB:SFP=False;Extended Properties=;" +"Mode=Share Deny None;Jet OLEDB:New Database Password=;" +"Jet OLEDB:Create System Database=False;" +"Jet OLEDB:Don't Copy Locale on Compact=False;" +"Jet OLEDB:Compact Without Replica Repair=False;" +"User ID=Admin;Jet OLEDB:Encrypt Database=False"
mdb_init
A=MDB_SetConnection(sConn)
MDB_ClearDataSet
ran=MDB_RunQuery("PlayerStatus")
MDB_AddParam("PlayerStatus","380")
do
if A=1
text 5,5,"Database Connected"
text 20,20,MDB_GetWholeRow(1,"*")
text 20,40,str$(MDB_GetColumnsUpperBound())
text,20,60,MDB_GetRowDataByColName(0,"Strength")
else
text 5,5,"No work"
endif
sync
loop
end
it seems DBP couldn't understand those two commands. But if i get rid of the two commands, "MDB_GetWholeRow" and "MDB_GetColumnsUpperBound()" worked properly.
I presume my need of the work flow of this plugin is
(Read informtion and then write changed one back into database)
1.MDB_init
2.MDB_ranQuery(QueryName,"*") to get each cell of query information in database in the form of a string splitted by *. and then use DBP core text command like mid$()or other way to pass information to needed array.
3.???? I need help on the following steps. how can i pass informtion of my array back to database?
4....
5....
...
Thanks a lot CastleRustler~~!
AMD Duron1800+, 256 ddr ram, Gforce2 MX 32mb, 120gb, Windows 2000 advanced server. DBPro1.05. "Sorry for my english" "New to Programming, Anything basic I missed??"