Stuart McLachlan
stuart at lexacorp.com.pg
Wed May 23 18:42:37 CDT 2012
I wouldn't call it "wrong", just unnecessarily verbose. <quote>The With statement allows you to perform a series of statements on a specified object without requalifying the name of the object</quote> Note the word "allows". There is nothing to say that you always *have* to use shorthand notation inside a With...End With block. -- Stuart On 23 May 2012 at 23:16, Darryl Collins wrote: > Hi Dale, > > On another issue: The following bit of code > > With rstRS > .AddNew > rstRS![EmployeeTimesID] = strKey > rstRS![EmployeeTimesDate] = Format(rstRsNew![Time], "Short Date") > rstRS![[EmployeeTimesName]] = Trim(rstRsNew![Employee]) > rstRS![EmployeeTimesIn] = Format(rstRsNew![Time], "Medium Time") > .Update > End With > > Is wrong - it probably works, as VBA is very forgiving, but try using > -- Stuart McLachlan Ph: +675 340 4392 Mob: +675 7100 2028 Web: http://www.lexacorp.com.pg