How to change the "Validation Rule" property of a filed in a table using VBScript
-
Hi, I want to change the "Validation Rule" property of a filed in an access table using VB Script. Current value is "=1". I want to change it to either NULL or ">=0". Please help me...! THe following code giving me an error...! ' Establish connection strConnString = "Provider=Microsoft.Jet.OLEDB.4.0;" & "Persist Security Info=False;" & "Data Source=" & strDest Set objConnection = CreateObject("ADODB.Connection") objConnection.Open strConnString ' Create a catalog for the database. Set cat = CreateObject("ADOX.Catalog") Set cat.ActiveConnection = objConnection ' Get the table. Set tbl = cat.Tables("App") ' Get the column. Set col = tbl.Columns("ID") ' HERE I AM GETTING AN ERROR saying "Item canot be found in the collection corresponding to the requested name or ordinal" ' Set the Description property. col.Properties("Validation Rule").Value = ">=0" Thank you, Regards, ADIDADPU