Stuart McLachlan
stuart at lexacorp.com.pg
Sat Apr 16 01:59:33 CDT 2011
Docmd.ShowToolbar has also been around for a long time too. The only thing that hasn't is a toolbar called "Ribbon". That constant is only evaluated at runtime if the Docmd.ShowToolbar is invoked by the If condition. Not a problem for the compiler. -- Stuart On 16 Apr 2011 at 0:59, William Benson wrote: > This is quite a surprise. This implies that the code compiles even > though vba for access 2003 ought to have no idea what that constant > is. Thus compiler is ignoring the code on the "Then" part of the > statement. On Apr 15, 2011 8:52 PM, "Stuart McLachlan" > <stuart at lexacorp.com.pg> wrote: > Application.Version has been around > for a long time. That code certainly works in A2K3. It > does nothing. > because Application.Version = 11. I use it for frequently for mdbs > that are > runnning in a mixed environment (A2K3 and A2007). > > > On > 15 Apr 2011 at 20:15, William Benson wrote: > >> Dumb question > maybe... but have you tested that code in anything >> earlier than > 2007?? I would think that the intrinsic constant is not >> > recognized.... maybe compatibility mode handles...? > > ... >> If > Application.Version = 12 Then DoCmd.ShowToolbar "Ribbon", acToolbarNo > > > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > Website: > http://www.databaseadvisors.com -- AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd Website: > http://www.databaseadvisors.com >