hello All,
I am having multiple file upload control in my mvc application please tell me how shall I do the functionality?
The files must get inserted into database at once .
Please tell me how shall I do?
If anyone one has ready code please post it
Thanks
Ritz
...
Any request to a non existent file or folder is throwing the following exception on my MVC project;
System.Web.HttpException: The controller for path ... could not be found or it does not implement IController
Important Edit:
I would like to handle this case so that this exception does not go into my Elmah logs.
Whatever I do inside ...
I am intending to develop a Finite State Machine in the following manner.
Extract Control IDs from a --> web-page,
Write control IDs to a XML --> Controls-XML.
Manually declare States and Transition in the --> Controls-XML
Scan Controls-XML and attach pre-declared Jscript to eventhandlers embed them in the --> web-page..
5.
How feas...
This is ASP.NET MVC v1 (not using the v2 yet)
I have a route entry like this:
routes.MapRoute(
"Srp",
"soeg-{searchQuery}/{listingType}",
new { controller = "Srp", action = "Search", listingType = string.Empty },
new { listingType = "privat|forhandler|"}
);
and a...
Heyho,
There´s a question in my mind for some time now, which hopefully can be cleared quickly by some of you:
I am a big fan of MVC, ASP.Net Mvc in my case.
What I have noticed is the hype about interfaces. Every video, tutorial and book seems to solve any kind of abstraction with interfaces. I have adapted these patterns, understoo...
Let's say that, theoratically, I have a page / controller action in my website that does some very heavy stuff. It takes about 10 seconds to complete it's operation.
Now, I use .NET's outputcache mechanism to cache it for 15 minutes (for examle, I use [OutputCache(Duration = 900)]) What happens if, after 15 minutes, the cache is expired...
I am using ASP.NET MVC, on my login action I am doing:
[AcceptVerbs("POST")]
public ActionResult Login(FormCollection form)
{
User validatedUser = // tests username/pwd here.
FormsAuthentication.RedirectFromLoginPage(
validatedUser.ID.ToString(), rememberMe);
if(String.IsNullOrEmpty(Request["ReturnUrl"]))
s...
(This is a more narrow question)
In my asp.net MVC action, I am looking if the ReturnUrl value is in the URL.
My Url looks like this:
http://localhost:56112/user/login?ReturnUrl=/user/settings
In my action, I am looking if that querystring value exists, and it is returning NULL?? How can this be?
The code:
if(Request.QueryString["...
I am refactoring this algorithm completely.
Basically I am re-implementing the ASP.NET MVC in C++ for another framework.
I'm trying to implement a URL matching algorithm and I figured that radix tree would be the best choice for the keys searching because some url prefixes might be shared.
Also searching may be very efficient considerin...
What is wrong with this ?
<%=Html.DropDownListFor(m=>m.Client,null,"Select",new { @style = "width: 630px" })%>
There is a ViewData["Client"] which contanins the source , the dropdown is filled but is not selected the value corresponding to Model.Client
...
Hi
How to set the readonly attribute to HTML Textbox helper class.
<%= Html.TextBox("Email", "[email protected]", new { @class = "required email" } )%>
Appreciate your response
Thanks
...
Hi
I have a dropdown that i need to set the default selected value from the database.
Example:
<%= Html.DropDownList("state", " -- Select one -- ")%>
The above code binds records from the ViewData["specialty"] from my entity model.
And "Select One" is added on the top.
Now if i need my dropdown to set the default value to 'NY'. How...
I am designing a database for an ASP.NET MVC application. I'm an expert in neither, and I'm curious what the best approach would be for the following database snippet:
We will be storing Events in our database. Each event will be of a different type with various fields exclusive to one or some of the types. An example:
Events
* Id
*...
I've got some MVC code that serializes an EF 3.5 object into an anonymous type for return as a JSON result to an AJAX call on my page. The hurdle I have is that when I send the object back to the server via JSON, (and let the ModelBinder deserialize it for me into my EF type), I have to update it in my Entity Framework context manually....
I just started using the Entity Framework 1.0 recently and believe I am beginning to feel the pains everyone is talking about. I'm trying to use best practices so I have a set of DTO that get mapped to and from my Entities via AutoMapper.
The real catch is when I'm trying to update an object. The first gotcha was that I could not find ...
I have a report page, that displays many rows, each row having its own checkbox with its value being an ID field from the database.
This is for a bulk operation, that will be preformed on all the row's where the checkbox was checked.
So if the user checks multiple boxes, hits a button, I need to send all the checkbox values to a contro...
For some reason an html helper is outputting this html which doesnt validate.
the validator tells me
There is no attribute "Length"
<%= Html.CheckBox("Medicamentos", Model.Medicamentos) %>
is outputting
<input type="checkbox" value="true" name="Medicamentos" id="Medicamentos" checked="checked" length="4">
...
I've got an MVC app that I've set the globalization in the web.config. All is well in the web app. But in my tests project I'm getting an issue in my service layer. I'm asking for date of birth in the following format dd/MM/yyyy. I'm passing this as a string to my service layer. I've got a RegEx to check that it is formatted correctly bu...
I have tried the code here:
http://dotnetslackers.com/articles/aspnet/Implementing-RESTful-Routes-and-Controllers-in-ASP-NET-MVC-2-0.aspx#s-reststyle-routes--controllers
But I just cannot get this to work with ASP.NET MVC 2.0 RC - the PUT and DELETE verbs do not get used. The output seems right, but the route handler seems to ignore t...
I'm working on an existing ASP.NET MVC 1 application in Visual Studio 2008. When I open a view about 10-20 seconds later I can't set the focus into Visual Studio. When I click with the mouse I get a system ding. Mouse wheel will scroll the source code window. Keyboard doesn't work, but the cursor is flashing.
Doing a few SO searches I f...