c# - Check If Query Exists if Yes - Delete -
I have the following syntax to use C # to delete an access query ... but how do I check Do the query exist? You can loop on the QueryDefs collection and check if you get this Has been ... DAO Database DD; DAO.D.B.E.gen. DB = new DAO.Begen (); dd = db.OpenDatabase (path); dd.QueryDefs.Delete (queryName); I also tried to do it - but it can not be assigned to 'equality' because it is a 'law group' that has received a compilation error. >
var qd = new dao .QueryDef (); If (qd.Name.Equals = "Hello") {dd.QueryDefs.Delete (queryName); }
Comments
Post a Comment