Wednesday, September 30, 2009

oledbconnection problem "Unrecognized escape sequence....."

cn = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\\ temp\\abc.mdb;User Id=admin;Password=;");
or
cn = new OleDbConnection(@"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\temp\ abc.mdb;User Id=admin;Password=;");

Sunday, September 27, 2009

Microsoft.Jet.OLEDB.4.0' provider is not registered on the local machine --------- dev error on vista x64 machine

this is because the driver is not x64. Solution: in project properties --> Build, select x86 in Platform Target

what's the status of a form after form1.show() and form1.hide() - Visual Studio 2008 Windows Form Application

in windows form application you can use Application.OpenForms collection to find the forms opened

Thursday, September 24, 2009

TSQL check if a view exists before create it

IF EXISTS (SELECT * FROM INFORMATION_SCHEMA.VIEWS WHERE TABLE_NAME = 'vw_abc')
DROP VIEW [dbo].[vw_abc]