Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 148281
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T08:55:50+00:00 2026-05-11T08:55:50+00:00

Trying to find some examples on the intertubes. I am thinking of state or

  • 0

Trying to find some examples on the intertubes. I am thinking of state or strategy pattern but if anyone has any war stories, examples or resources that they could point me to it would be appreciated.

I don’t/can’t use windows workflow.

My example is that i have a complex wizard that changes the state of the process based on what user is doing and by who the user is.

For example:

  • Cancelled
  • Requested by user
  • Request by manager
  • Confirmed
  • Refereed
  • Administrator Received
  • Administrator Confirmed
  • Administrator Cancelled

Cheers John

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-11T08:55:51+00:00Added an answer on May 11, 2026 at 8:55 am

    How about the State pattern (wikipedia link)?

    public abstract class State {     /// <summary>     /// Holds the current state we're in.     /// </summary>     public State CurrentState     {          get;          set;      }      public virtual string Cancelled(State context)     {         return '';     }      public virtual string RequestedByUser(State context)     {         return '';     }      public virtual string RequestedByManager(State context)     {         return '';     } }  public class CancelledState : State {     public override string Cancelled(State context)     {         context.CurrentState = new SittingState();         return 'Cancelled.';     }      public override string RequestedByUser(State context)     {         context.CurrentState = new RequestedByUserState();         return 'Requested by User.';     }      public override string RequestedByManager(State context)     {         return 'You can't do this before it's been requested by the User';     } }  // (RequestedByUserState and RequestedByManagerState classes have been cut out) 

    As you can see, the pattern does fit exactly though.

    Chain of Responsibility might be also be relevant if there’s security concerns. If the wikipedia article makes no sense then this book has a good examples of both. Another is the Command pattern for wizards. None of them fit perfectly but they give you some good ideas to start with.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 73k
  • Answers 73k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • added an answer Python 2.6 added a new strftime/strptime macro %f. The docs… May 11, 2026 at 2:02 pm
  • added an answer It sounds like it can't find the app.config/web.config file. With… May 11, 2026 at 2:02 pm
  • added an answer Look at the tools around hibernate that generate hibernate classes… May 11, 2026 at 2:02 pm

Related Questions

Trying to find some simple SQL Server PIVOT examples. Most of the examples that
I'm trying to find some references in regards to x86 Assembly languages. Tutorials/Examples to
I'm trying to find some info on the best and most common RESTful url
I'm trying to find out some matrix multiplication/inversion benchmarks online. My C++ implementation can
I'm trying to find URLs in some text, using javascript code. The problem is,
I am trying to find some examples but no luck. Does anyone know of
i'm trying to upload some data from an ActiveX control to a webpage. The
I am trying to get to speed on the use of dictionaries. I spent
Ok, so this is an alternative to this question. I'm trying to produce an

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.