Link to home
Start Free TrialLog in
Avatar of TerenceHewett
TerenceHewett

asked on

Runtime error 3654 Internal Internet Failure MS Access 2003

Hi experts,

I am trying to access data stored in a HTML table on my website and transfering this value into my database through an import control.  I am getting an error message 3654 Internal Internet Failure and do not know how to get around this problem.  The code I am using is as follows:

Private Sub Command0_Click()
Dim db As DAO.Database
Dim td As DAO.TableDef

Set db = CurrentDb()

Set td = db.CreateTableDef("versionnumber")
td.Connect = "HTML Import;HDR=YES;IMEX=1;DATABASE=http://www.e2s-application-systems.com/BCExpert/versionnumber.htm"
td.SourceTableName = "VersionNumber"
Call db.TableDefs.Append(td)

Dim rs As DAO.Recordset

Set rs = db.OpenRecordset("select count(*) from versionnumber")
Debug.Print rs.Fields(0).Value
Call rs.Close  

End Sub

I would be grateful for any help.

Regards,
Terry
Avatar of peter57r
peter57r
Flag of United Kingdom of Great Britain and Northern Ireland image

From what I can see the table is called table1, not versionnumber.
Avatar of TerenceHewett
TerenceHewett

ASKER

Hi Peter,

Many thanks for your post. I have substituted as suggested with table1 but still getting the same error message 3654 Internal Internet Failure.  Did you manage to avoid this message?

Private Sub Command0_Click()
Dim db As DAO.Database
Dim td As DAO.TableDef

Set db = CurrentDb()

Set td = db.CreateTableDef("table1")
td.Connect = "HTML Import;HDR=YES;IMEX=1;DATABASE=http://www.e2s-application-systems.com/BCExpert/versionnumber.htm"
td.SourceTableName = "table1"
Call db.TableDefs.Append(td)

Dim rs As DAO.Recordset

Set rs = db.OpenRecordset("select count(*) from table1")
Debug.Print rs.Fields(0).Value
Call rs.Close

End Sub

Any further help would be appreciated.

Regards
Terry
I have never done this before - I can't comment on the validity of the code you are using.
I could just see that the table id was wrong.

ASKER CERTIFIED SOLUTION
Avatar of Markus Fischer
Markus Fischer
Flag of Switzerland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thank you for your posts and sorry for the delay in responding.  Harfang, point noted on giving the place that the code I wish to adapt comes from.

Regards,
Terry