473,378 Members | 1,536 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

Seeking Advice on MVC Synchronization

Following the advice of several of you on here (Thank You All!) I've
successfully constructed a Model-View-Controller (MVC) implementation. It
works great! Now, whenever the user manipulates one of the standard controls
- ie. clicks a checkbox, selects a radio button, changes text in a textbox,
etc. - the corresponding Property values in the Model are automatically and
instantly changed!

But I do have a question. When a radio button is pressed or a checkbox is
checked or unchecked it makes complete sense to instantly reflect the change
in the Model. But I'm not so sure whether I should be making these same
"instant" changes with each character change of the TextBox. Should I or
should I just wait until the user exits the textbox?

I realize that an instant response is "it all depends" but I'd like to get
feedback from developers who have had a similar circumstance before and am
wondering how they handled it.

Sincerely,

Robert Werner
MW Technologies
Vancouver, BC
Nov 17 '05 #1
3 1255
Firstly well done on deciding to use the MVC model. The answer is pretty
simple in my mind - always do it on commit of a change, that is on lose
focus. Also, I assume this is a Winforms implementation, so the
character-at-a-time metaphor does not map to a browser deployment.

FYI, interesting whitepaper on software development that has total
separation of presentation from business layer (and more):
http://members.optushome.com.au/rcer...WhitePaper.pdf

"Robert W." <Ro*****@discussions.microsoft.com> wrote in message
news:CF**********************************@microsof t.com...
Following the advice of several of you on here (Thank You All!) I've
successfully constructed a Model-View-Controller (MVC) implementation. It
works great! Now, whenever the user manipulates one of the standard controls - ie. clicks a checkbox, selects a radio button, changes text in a textbox, etc. - the corresponding Property values in the Model are automatically and instantly changed!

But I do have a question. When a radio button is pressed or a checkbox is
checked or unchecked it makes complete sense to instantly reflect the change in the Model. But I'm not so sure whether I should be making these same
"instant" changes with each character change of the TextBox. Should I or
should I just wait until the user exits the textbox?

I realize that an instant response is "it all depends" but I'd like to get
feedback from developers who have had a similar circumstance before and am
wondering how they handled it.

Sincerely,

Robert Werner
MW Technologies
Vancouver, BC

Nov 17 '05 #2
Thanks, Radek. Moving from the VB6 universe I didn't realize how difficult
it ended up being (read "steep learning curve") but now that I've done it I
feel a lot better about C# and dotNet in general. Powerful stuff!

I'll read your paper shortly.

Thank you again,

Robert W.

"Radek Cerny" wrote:
Firstly well done on deciding to use the MVC model. The answer is pretty
simple in my mind - always do it on commit of a change, that is on lose
focus. Also, I assume this is a Winforms implementation, so the
character-at-a-time metaphor does not map to a browser deployment.

FYI, interesting whitepaper on software development that has total
separation of presentation from business layer (and more):
http://members.optushome.com.au/rcer...WhitePaper.pdf

"Robert W." <Ro*****@discussions.microsoft.com> wrote in message
news:CF**********************************@microsof t.com...
Following the advice of several of you on here (Thank You All!) I've
successfully constructed a Model-View-Controller (MVC) implementation. It
works great! Now, whenever the user manipulates one of the standard

controls
- ie. clicks a checkbox, selects a radio button, changes text in a

textbox,
etc. - the corresponding Property values in the Model are automatically

and
instantly changed!

But I do have a question. When a radio button is pressed or a checkbox is
checked or unchecked it makes complete sense to instantly reflect the

change
in the Model. But I'm not so sure whether I should be making these same
"instant" changes with each character change of the TextBox. Should I or
should I just wait until the user exits the textbox?

I realize that an instant response is "it all depends" but I'd like to get
feedback from developers who have had a similar circumstance before and am
wondering how they handled it.

Sincerely,

Robert Werner
MW Technologies
Vancouver, BC


Nov 17 '05 #3
Robert, be careful to not mistake or confuse good design with OOP and code
reuse. OOD is whats important - Object Oriented Design. Think OO, draw
lots of pictures and clarify what goes where BEFORE a mass coding exercise.
OOP and code reuse are by-products of OOAD, and luckily c# gives pretty much
all you need to implement good OO design (except one major flaw - in my mind
anyways - no multiple inheritance or MI).

You'll probably think you've done a good job, but 6 months later realise a
much better way, and rebuild. Third generation will be great, 4th gen will
be fantastic and there may not be a 5th generation. By then however, you
will be extremely productive and your design artefacts will be far more
valuable than your code, so a rebuild will be not that painful.

Very powerful stuff indeed....

"Robert W." <Ro*****@discussions.microsoft.com> wrote in message
news:6A**********************************@microsof t.com...
Thanks, Radek. Moving from the VB6 universe I didn't realize how difficult it ended up being (read "steep learning curve") but now that I've done it I feel a lot better about C# and dotNet in general. Powerful stuff!

I'll read your paper shortly.

Thank you again,

Robert W.

"Radek Cerny" wrote:
Firstly well done on deciding to use the MVC model. The answer is pretty simple in my mind - always do it on commit of a change, that is on lose
focus. Also, I assume this is a Winforms implementation, so the
character-at-a-time metaphor does not map to a browser deployment.

FYI, interesting whitepaper on software development that has total
separation of presentation from business layer (and more):
http://members.optushome.com.au/rcer...WhitePaper.pdf

"Robert W." <Ro*****@discussions.microsoft.com> wrote in message
news:CF**********************************@microsof t.com...
Following the advice of several of you on here (Thank You All!) I've
successfully constructed a Model-View-Controller (MVC) implementation. It works great! Now, whenever the user manipulates one of the standard

controls
- ie. clicks a checkbox, selects a radio button, changes text in a

textbox,
etc. - the corresponding Property values in the Model are automatically
and
instantly changed!

But I do have a question. When a radio button is pressed or a

checkbox is checked or unchecked it makes complete sense to instantly reflect the

change
in the Model. But I'm not so sure whether I should be making these same "instant" changes with each character change of the TextBox. Should I or should I just wait until the user exits the textbox?

I realize that an instant response is "it all depends" but I'd like to get feedback from developers who have had a similar circumstance before and am wondering how they handled it.

Sincerely,

Robert Werner
MW Technologies
Vancouver, BC


Nov 17 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: John Goerzen | last post by:
Hi, I'm the author of OfflineIMAP, a bidirectional IMAP synchronization tool. Its job is to let you read IMAP mail with any mail reader that can understand a Maildir, and to keep your mail...
6
by: user451 | last post by:
As the most Access-savvy person in my office, I have been handed the task of proposing a nationwide expansion of a project that I have developed in Access. A brief overview: Right now, about 25...
3
by: dlesandrini | last post by:
I need advice about my decision to go with Replication in general. This post was placed on the Microsoft Replication newsgroup, but I really value the feedback that comes from this group as well. ...
2
by: Joseph Geretz | last post by:
I don't know if this is the right group for my question, but I'm seeking advice from knowledgable .NET developers. Hopefully I've come to the right place. I work with a document management...
4
by: scott | last post by:
hi all, Thx to any one that can offer me help, it will be much appreciated. iv got a multithreaded program and need to use thread synchronization. The synchronization does not have to...
5
by: Kevin Carne | last post by:
First, Merry Christmas. I have been doing intensive Java programming for two years in school (no choice on the language), but now I need to return to C++ because my resume is filled with it both in...
4
by: Ben Fidge | last post by:
My application uses a singleton static class for writing entries to a log file. The location and name of the log-file is read from web.config each time an entry is written, but has the current date...
12
by: emma_middlebrook | last post by:
Hi Say you had N threads doing some jobs (not from a shared queue or anything like that, they each know how to do their own set of jobs in a self-contained way). How can you coordinate them so...
7
by: Joseph Geretz | last post by:
I have a Service which runs OK, but I'm abviously not starting it properly. In my OnStart event I commence a long running process which polls a database table and performs various processing. Since...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.