Search

You searched for the word(s): userid:2156
Page 1 of 9 (86 items) 1 2 3 4 5 Next > ... Last »
  • Get Access ADOX Synonymous from Framework DataColumn

    static ADOX.DataTypeEnum GetAccessFormats(DataColumn col) { switch (col.DataType.Name) { case "Boolean" : return ADOX.DataTypeEnum.adBoolean; case "Byte" : return ADOX.DataTypeEnum.adUnsignedTinyInt; case "Char" : return ADOX.DataTypeEnum.adVarWChar; case "DateTime" : return ADOX.DataTypeEnum.adDate; case "Decimal" : return ADOX.DataTypeEnum.adDecimal; case "Double" : return ADOX.DataTypeEnum.adDouble; case "Int16" : return ADOX
    Posted to Office Systems Developer (Weblog) by Joao Livio on Wed, Apr 29 2009
    Filed under: Access 2007, C#, VSTO
  • VSTO (Access) – Convert a Field to Upper, Lower, Proper

    public string ConvertFieldToUpper( string MyTable, string MyField) { Access.Application oAccess = ((Access.Application) (Marshal.GetActiveObject( "Access.Application" ))); try { string strSQL; strSQL = String.Format( "UPDATE {0} SET {1} = UCase([{1}])" , MyTable, MyField); oAccess.DoCmd.RunSQL(strSQL.ToString(), null ); return "OK" ; } catch (Exception) { throw ; } finally { Marshal.ReleaseComObject(oAccess); } } public string ConvertFieldToLower( string MyTable, string
    Posted to Office Systems Developer (Weblog) by Joao Livio on Wed, Apr 22 2009
    Filed under: Access 2007, C#, VSTO, English Related
  • VSTO (Access) a Simple Database initialization

    /// <summary> /// /// </summary> /// <param name="hideNavigationPane"></param> /// <param name="myUIName"></param> /// <param name="myUIXML"></param> /// <returns>True/False</returns> public bool InitializeDatabase( bool hideNavigationPane, string myUIName, string myUIXML) { Access.Application oAccess = ((Access.Application) (Marshal.GetActiveObject( "Access.Application" ))); try { oAccess.SetOption
    Posted to Office Systems Developer (Weblog) by Joao Livio on Wed, Apr 22 2009
    Filed under: Access 2007, C#, VSTO, English Related
  • VSTO (Access) – Convert a Report to XPS

    public bool ConvertReportToXPS( string myReport, string XPSFileName) { Access.Application oAccess = ((Access.Application) (Marshal.GetActiveObject( "Access.Application" ))); try { oAccess.DoCmd.OutputTo(Access.AcOutputObjectType.acOutputReport, myReport, Access.Constants.acFormatXPS, XPSFileName, System.Type.Missing, System.Type.Missing, System.Type.Missing); return true ; } catch (Exception) { throw ; } finally { Marshal.ReleaseComObject(oAccess); } }
    Posted to Office Systems Developer (Weblog) by Joao Livio on Wed, Apr 22 2009
    Filed under: Access 2007, C#, VSTO, English Related
  • VSTO (Access) Detect if tables are similar

    public bool TablesAreEqual( string MyTableSource, string MyTableToCompare, string MyIndexField) { try { OleDbConnection cnn; using (DataSet ds = new DataSet()) { OleDbDataAdapter da; string cs = oAccess.CurrentProject.Connection.ToString(); string strSQL = String.Format( "SELECT * FROM {0} LEFT JOIN {1} ON {0}.{2} = {1}.{2}WHERE {1}.{2} Is Null" , MyTableSource, MyTableToCompare, MyIndexField); cnn = new OleDbConnection(cs); da = new OleDbDataAdapter(strSQL, cnn); da.Fill(ds); if (ds.Tables
    Posted to Office Systems Developer (Weblog) by Joao Livio on Wed, Apr 22 2009
    Filed under: Access 2007, C#, VSTO, English Related
  • VSTO (Access) How to Backup the Current project?

    Access.Application oAccess = ((Access.Application)                 (Marshal.GetActiveObject("Access.Application"))); // ---------------------------------------------------------------------------------------- // Author: Joao Tito Livio // Company: MACL // Assembly version: 0.0.* // Date: 21-04-2009 // Time: 23:47 // Project Item Name: M3DatabaseUtilities.cs // Project Item Filename: M3DatabaseUtilities.cs // Project
    Posted to Office Systems Developer (Weblog) by Joao Livio on Wed, Apr 22 2009
    Filed under: Microsoft Access, Access 2007, C#, VSTO, English Related
  • VSTO (Access) How to execute a SQL Statement from a File?

    public bool ExecuteSqlFromFile(String MyConnectionString, String MyTextFilePath) { using (OleDbConnection sqlConnection = new OleDbConnection(MyConnectionString)) { OleDbCommand cmd = new OleDbCommand(); try { using (StreamReader fh = new StreamReader(MyTextFilePath)) { String MyText; string s; while ((s = fh.ReadLine()) != null ) MyText = s; fh.Close(); cmd.CommandText = s; } cmd.CommandType = CommandType.Text; cmd.Connection = sqlConnection; sqlConnection.Open(); cmd.ExecuteNonQuery(); sqlConnection
    Posted to Office Systems Developer (Weblog) by Joao Livio on Wed, Apr 22 2009
    Filed under: Microsoft Access, Access 2007, C#, VSTO
  • VSTO (Access) – How to return a RecordSet from a OleDb Provider?

      // ---------------------------------------------------------------------------------------- // Author: Joao Tito Livio // Company: MACL // Assembly version: 0.0.* // Date: 21-04-2009 // Time: 23:55 // Project Item Name: M3Data.cs // Project Item Filename: M3Data.cs // Project Item Kind: Code // Class FullName: Macl.M3Data // Class Name: M3Data // Class Kind Description: Class // Class Kind Keyword: class // Procedure FullName: Macl.M3Data.ReturnRecordset // Procedure Name: ReturnRecordset
    Posted to Office Systems Developer (Weblog) by Joao Livio on Wed, Apr 22 2009
    Filed under: Microsoft Access, Office System 2007, Access 2007, C#, English Related
  • VSTO (Access) how to create a Table with fields in a Access Database (ADOX and JET SQL)

    /// <summary> /// /// </summary> /// <param name="MyPath"></param> /// <returns>True/False</returns> public bool GenerateLogDatabase( string myPath) { CatalogClass cat = new CatalogClass(); string strSQL; string cs; try { cs = "Provider=Microsoft.Jet.OLEDB.4.0;" + "Data Source=" + myPath + ";" + "Jet OLEDB:Engine Type=5" ; strSQL = "CREATE TABLE Issues (mID AUTOINCREMENT, mUser TEXT(100) NOT NULL " + "
    Posted to Office Systems Developer (Weblog) by Joao Livio on Wed, Apr 22 2009
    Filed under: Access 2007, C#, VSTO, English Related
  • SharePoint Designer 2007 is now FREE

    Great News SharePoint Designer 2007 is now FREE! Get it here
    Posted to Office Systems Developer (Weblog) by Joao Livio on Mon, Apr 20 2009
    Filed under: Other Stuff, Office System 2007, English Related
Page 1 of 9 (86 items) 1 2 3 4 5 Next > ... Last »