A design pattern for managing the activation and deactivation of menus and buttons etc in an applica

  • Thread starter Thread starter thechaosengine
  • Start date Start date
T

thechaosengine

Hi all,

Does anyone know of a design pattern to deal with the issue of making UI
controls active and inactive according to the context of what the user is
doing?

I've been thinking about the best way to handle this but the only way I can
really think to do it would likely be very messy - trying to deal with it
in event handlers. I can imagine that trying to disable and enable buttons
and menu items and toolbars for a whole host of ui elements for a whole host
of different application contexts could be very messy.

Are there any particular approaches that i should be looking at to manage
the problem a bit better?

Thanks everyone

Simon
 
Set up a single handler that is called from the various postback events that
cause situtations that enable/disable controls. The basic design pattern is a
command pattern, but you will not likely go full bore on this, as you will
end up moving away from the UI or creating a rather complex page.


---

Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA

***************************
Think Outside the Box!
***************************
 
Back
Top