views:

42

answers:

0

hi

i try this in access 2007 and its work excellent !!!

but in access 2003 it dosent work

what can be the problem ?

public string Office2003 = @"C:\Program Files\Microsoft Office\Office11\msaccess.exe";
public string Office2007 = @"C:\Program Files\Microsoft Office\Office12\msaccess.exe";
ProcessStartInfo MSAccessInfo = new ProcessStartInfo();
MSAccessInfo.FileName = Office2003;
MSAccessInfo.Arguments =  Application.StartupPath + @"\Mydb.mdb /excl /compact ";
MSAccessInfo.CreateNoWindow = false;
MSAccessInfo.WindowStyle = ProcessWindowStyle.Hidden;
Process.Start(MSAccessInfo);