I want to use MVC to structure my Swing application, but there seems to be a conflict.
As I understand MVC, the controller should handle input and update the model. The model should notify its observers of which the view is one.
I have two problems
Swing is all part of the view. The fact that components have their own models is an im...
I'm trying to auto-save a selection in a dropdown (ASP.NET, MVC, VB), but it's not behaving as expected. Here's the dummy action in the controller:
<AcceptVerbs(HttpVerbs.Post)> _
Function TestAction(ByVal id As Integer) As ActionResult
Return Content(id)
End Function
and the HTML:
<script type="text/javascript" src='<%= Url.Cont...
I have a PHP web application built with CodeIgniter MVC framework. I wish to test various controller classes. I'm using Toast for unit testing. My controllers have no state, everything they process is either saved into session or passed to view to display. Creating a mock session object and testing whether that works properly is straight...
Hi, I am building a Windows form application using .NET 3.5. I would like to use the MVC design pattern. The app has two forms: a quick launch and a view showing the details. The quick launch just has a tree with 2 levels, so the tree structure looks something like
Category 1
Subcategory 1-1
Subcategory 1-2
Category 2
Subcategory 2-...
Hello,
I'm having problems repopulating a TextBox from data coming from a complex structure involving Dictionaries.
So, I have VM structure like this:
public class AnswerVM
{
public int Index { get; set; }
public Answer Answer { get; set; }
public Dictionary<int, QuestionResult> QuestionResults { get; set; }
}
public class Questio...
I have seen some developers attempting to shoehorn the MVC or MVP patterns into Winforms applications, presumably on the premise that, if it's good for WPF and ASP.NET, then it must be good for Winforms.
Is this a good idea, or is it lipstick on a pig? Why or why not?
...
In my ASP.NET MVC app, I'm handling errors by overriding OnException in the controller. What is happening is that if a runtime error happens on the page, the Error.aspx page opens inside the page on which the error happened. Here's the code (with some extra error message stuff removed):
Protected Overrides Sub OnException(ByVal filterCo...
I currently make use of JQuery UI dialogs across my site. However, I've recently started to make use of the MVC TempData collection for notifications of success/failure of various actions triggered by my dialogs. Nothing particularly fancy or new. However, it's brought up an issue that I can't find a simple, obviously solution to.
On so...
In my web application framework (currently WebForms) I have a control that behaves like a classic propertygrid. It is initialized with an object ID (database key), then it reads metadata to determine the type of the object and the attributes of the object. It displays the attributes, string attributes as textboxes, bool attributes as che...
Does ASP.NET MVC provide any way to implement UpdateProgress WebForms control analog? Can anyone explain me how to achieve such client-side functionality with MVC?
...
Hi All,
I am now to MVC F/W. I developed an application where i need to Open a new URL (WHich comes from other server)
I developed and it worked in my Local Machine ... But when i try to run on DEV Machine it alwsys asks userID and Password.
Is it anything related to Credientals of the URL Opened. (I am able to open it when ...
I am using asp.net's modelbinder functionality to bind form values to my entity when posting from a view.
The html renders correctly in the initial view with correct option and value items.
When completing the form and posting, all values are populated correctly into the entity except the value from the dropdown list. not sure what I ...
I have a weird timing issue, it seems. I open a uiimagepicker as a modal view. When the user picks an image or I want to take the image, save it to a variable, then open an email interface as a modalview.
My problem is that I am calling dismissModalViewController on the imagepicker, then calling presentmodalviewcontroller for my email...
I'm trying to whip up a skeleton View system in PHP, but I can't figure out how to get embedded views to receive their parent's variables. For example:
View Class
class View
{
private $_vars=array();
private $_file;
public function __construct($file)
{
$this->_file='views/'.$file.'.php';
}
public funct...
I was just starting to get comfortable with MVC when somebody mentioned IoC containers to me, and now I feel like I've fallen a few thousand feet and need to climb back up again. I was tempted to just ignore them, but then I read up on the Component Lifestyle. This seems like a big deal to me, as explained, uncommited changes to databa...
I have a 1:1 has_one / belongs_to relationship between users and registrations. One user has one registration.
When I try to iterate through users in a view and display their registration info (source to follow), I get the following error:
ActionView::TemplateError: You have a nil object when you didn't expect it! The error occurre...
How to convert/map MVC objects to CSLA.net 2.1 and potential issues? Please help me. Thanks.
MVC Object means Model in MVC.
...
Consider the following from CodeIgniter. If I am doing this wrong, then please tell me:
<html>
<head>
<title><?=$title ?></title>
</head>
<body>
<h1><?=$heading; ?></h1>
<?php foreach ($query->result() as $row):?>
<p>
<?=$row->LastName . ', ' . $row->FirstName . ' ' . $row->MiddleName?>
</br>
<?=$row->...
Is it possible to grab specific elements from a database via the entity framework and display them after clicking a 'Find' button on the page?
Lets say there is a textbox and you have to enter a number. Upon entering a certain number, a certain database table's column will be searched for that number and all instances will be returned ...
Having used some PHP frameworks such as Codeigniter and Kohana for some smaller sites, I'm starting to wonder if MVC is still applicable for larger projects and, if so, what precautions need to be taken to maintain clean clode. What practices do the larger sites use in order to prevent this? Does Amazon's or Flickr's code use MVC or some...