How to create intranet website accessing database dynamically without server or server side scripts?

Here is the problem, an Intranet webpage has to be created without the server for hosting and i have been trying to update Access database using HTML and javascript but this is not working with the below code plese help

When the below code ran from Visual studio an error which says "Microsoft JScript runtime error: Safety settings on this computer prohibit accessing a data source on another domain." is fired and the connecction was stopped. kindly help me

 <script>

 function removeRow(rnum) {
     jQuery('#rowNum' + rnum).remove();
 }



 function AddRecord() {
     var adoConn = new ActiveXObject("ADODB.Connection");

     var adoRS = new ActiveXObject("ADODB.Recordset");

     adoConn.Open("Provider=Microsoft.Jet.OLEDB.4.0;Data Source='\\dbName.mdb'");

     //adoConn.Open("Provider=Microsoft.Jet.OLEDB.4.0; Data Source='C:\sai\TrackerDB.mdb'");
     adoRS.Open("Select * From sai", adoConn, 1, 3);

     adoRS.AddNew;
     adoRS.Fields("requester_name").value = "Quentin";
     adoRS.Update;

     adoRS.Close();
     adoConn.Close();
  }  
   </script>

  <html>
  <input onclick="AddRecord();" type="button" value="Add data" />
  </html>

Answers:

Answer

Just try mapping the network driver to a local driver, make sure you map it to the same letter on each computer.

Digital Chris - What he means is: you have a local HTML file with some HTML and SCRIPT and you just open it.

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us Javascript

©2020 All rights reserved.