I allways use in the beginning of my program
- Code: Select all Expand view RUN
- oSQL:=CreateObject("ADODB.Connection")
oSQL:ConnectionString:=ADO_SQL_Connectionstring
oSQL:Open()
...
...
and at the end
- Code: Select all Expand view RUN
- oSQL:close()
oSQL:=nil
and that is working very nice.
In a particual program I want to delete the SQLite-database and do
- Code: Select all Expand view RUN
- oSQL:close()
oSQL:=nil
ferase('.\myfile.db')
but the ferase() this returns an error -1
This mean that the file is not closed
I now if a only return recordsets, I don't need to open the file like that, but I need to execute some SQL-commands (like creating tables, and other commands)
How can I close the connection completely with ADO?
Thanks