This is the code I have used. This works apart from when the line with the * next to it is added. I think I may have missed out a comma or something as trivial as that.
strProvider="DRIVER=Microsoft Access Driver (*.mdb); DBQ=C:\Inetpub\wwwroot\Web Site\SquashMetro.mdb;"
set conn = server.createobject("ADODB.Connection")
conn.Open strProvider
sqlstmt = "UPDATE PlayerResultsDiv1"
if GH1 = 3 then
Won = 1
sqlstmt = sqlstmt & " SET Won= Won + " & Won
else
Lost = 1
sqlstmt = sqlstmt & " SET Lost= Lost + " & Lost
end if
sqlstmt = sqlstmt & " Pts = Pts + " & GH1 **************
sqlstmt = sqlstmt & " WHERE PlayerID ='" & PH1 & "' "
Set RS = conn.execute(sqlstmt)
Thanks
Dave