Posted By

lmontealegre on 02/06/13


Versions (?)

Who likes this?

1 person have marked this snippet as a favorite


Defined a shared script SQL database

 / Published in: C#

defined a shared script database, Visual Web Ripper will pass an instance of the class WrSharedDatabase to all your script functions. The WrSharedDatabase class has the following methods that all work the same, regardless of the type of database you are accessing.

  1. public void SetSql(string sql)
  2. public void PrepareSql()
  3. public void SetParameterTextValue(string parameterName, string value)
  4. public void SetParameterDateTimeValue(string parameterName, DateTime value)
  5. public void SetParameterIntValue(string parameterName, int value)
  6. public void SetParameterDoubleValue(string parameterName, double value)
  7. public void SetParameterNullValue(string parameterName)
  8. public object ExecuteNonQuery()
  9. public object ExecuteScalar()
  10. public DataSet ExecuteDataSet()
  11. public OleDbDataReader ExecuteOleDbDataReader()
  12. public SqlDataReader ExecuteSqlDataReader()
  14. public SqlConnection SqlConnection;
  15. public OleDbConnection OleDbConnection;
  16. public SqlCommand SqlCommand;
  17. public OleDbCommand OleDbCommand;

Report this snippet  

You need to login to post a comment.