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

  • SEARCH
  • Home
  • 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 3455922
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T09:40:24+00:00 2026-05-18T09:40:24+00:00

Hey design pattern experts- I’m trying to build a four step process into a

  • 0

Hey design pattern experts-

I’m trying to build a four step process into a VB.NET GUI. The application transfers objects from AppA to AppB.

The application will follow these steps:

  1. User constructs a general query in the GUI to identify which AppA objects to transfer.
  2. Model gets queryResults, datagrid in View lists each result
  3. User deselects items not to be transferred to AppB
  4. Model transfers selected items

I’m new to MVC and am trying to figure out how this should work. I’ve have the following functions implemented in the model, but don’t know the MVC-way to tie them into my GUI:

Function getQueryResults(queryParams) as Items 
Function transferItems(items)

Do I keep the Items data structure in the model?

How do I remove deselected from the Items data structure without building logic into the view?

Both of the above functions take time, how can I design thing to allow me to BackgroundWorker the model’s functions?

Thanks

  • 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. Editorial Team
    Editorial Team
    2026-05-18T09:40:25+00:00Added an answer on May 18, 2026 at 9:40 am

    Please note that I’m a C# rather than VB dev, but it should work the same way regardless.

    Think of your view as being really, really dumb.

    Your view shouldn’t have any logic in at all. Every time it sees the user do something (like deselecting an item) it should tell the controller. Every time the controller wants the Gui to display something new, it should tell the view to do that. Normally there’s a subject / observer pattern between the view and the controller or between the model and the view, so that the view will automatically update or notify the controller when things happen.

    In this instance, imagine a conversation like this.

    • V: Hey, C, what shall I display?
    • C: Here you go. Have a model. M, please load your items.
    • M: Sure thing, boss… there you go. By the way, anyone watching, I just changed.
    • V: Oh, look, the model changed. I guess I should display those items.
    • C: Just waiting on user input now.
    • V: Hey C, someone just deselected this value from the list.
    • C: Yeah? Cool. M, remove that value from your list of Items, please.
    • M: Sure. By the way, anyone watching, I just changed.
    • V: Oh, look, the model changed. I should reload the items.
    • V: Hey, C, now someone clicked this button.
    • C: Excellent. M, please transfer the items.
    • M: Sure thing, boss. By the way, anyone watching, I just changed.
    • V: Oh, look, the model changed. Now it says its busy… I display the “processing” bar for that.
    • M: Okay, we’re done. By the way, anyone watching, I just changed.
    • V: Oh, look, the model changed. Not busy any more. No items. No processing. Whatever.

    You can either keep the Items data structure in your domain object, or you could just make the list of Items your Model for MVC purposes.

    A nice thing to do which makes it more like MVP or MVVM would be to present the view with a wrapper around the model giving it exactly what it needs and only what it needs – so for instance, you could give it a wrapper which included the items and also a flag which said “busy” for when your worker is off doing stuff.

    Hope this helps.

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

Sidebar

Related Questions

Hey im new to database design and having trouble trying to figure this one
Hey, I've been developing an application in the windows console with Java, and want
Hey all. Newbie question time. I'm trying to setup JMXQuery to connect to my
Hey having some trouble trying to maintain transparency on a png when i create
Hey guys, im not well versed in dealing with asynchronous design patterns, and im
Hey, I've been assigned to design a flex 3 volume control component similar to
hey everyone... so i'm working on a database design class for university. I've got
Hey guys..I am designing a set-up wizard using CPropertySheet and CpropertyPage in MFC application...I
Hey. We're building a large ASP.NET website, and have hired an external firm to
Hey everyone, I'm using Virtual PC and working with a virtual hard disk (*.vhd)

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.