MVC :: Short Hand Name Attribute For Controller?
Feb 1, 2010
I noticed the ActionNameAttribute lets you alias your controller methods. This is nice but I was curious if there was a comparable attribute for a controller name. Specifically, I have a controller with a lengthy name in c# world but would like to shorten / alias it in the actual URL. I was hoping for some kind of controllername attribute. Is there such a beast?
View 3 Replies
Similar Messages:
Nov 16, 2010
i wanna use HandleError attribute on my Controller. but it doesn't work .
here's my sample:
[Code]....
[Code]....
View 10 Replies
Aug 2, 2010
I am experimenting with the relationship between Elmah and MVC's plumbed in exception handling, and am surprised at the outcome of the following code. This is a brand new, straight from project template MVC application, and I have only added Elmah modules and handlers to the web.config.
[Code]....
Break when error is thrown is set to off, yet the debugger still breaks. When I continue I get a YSOD, and an Elmah error log, but it seems HandleError is doing nothing.
JUST IN I didn't think I had to have custom errors turned on, as I thought that was only for 'my' unhandled errors.
View 1 Replies
Feb 17, 2010
here's my situation - I've created some ActionFilterAttributes that I want to apply to a custom Controller class that my other controllers can inherit from. The problem is, I need to set a property on the attribute from the final inheriting controller. So I have something like this :
[Code]....
[Code]....
View 2 Replies
Dec 28, 2010
UML and Patterns: An Introduction to Object-Oriented Analysis and Design and Iterative Development, that follows the UP(Unified Process). It uses a Grasp Controller pattern to interact with domain classes by some methods like NewSale(), AddNewItemToSale() and CloseSale. In windows form, I can instantiate a object of this class in the UI and then use its methods to perform the actions. This works well in Client apps, but when I use asp.net mvc, I cannot find a way to instantiate an object (one for each user) that was always visible for a Controller (MVC). I cannot insert as an attribute inside Controller because it always create a new one.
View 1 Replies
Apr 8, 2010
Do you struggle with the size and the number of entries in the web.config file? Do you understand every element?Is it time for Microsoft to relook at how an ASP.NET site is configured, perhaps by splitting the web.config file into multiple files?
View 2 Replies
Dec 16, 2010
What property do I need to set here ?
<cc1:Accordion ID="Accordion1" runat="server" FadeTransitions="true" AutoSize="Fill"
SelectedIndex="0" RequireOpenedPane="false" DataSourceID="objQues" TransitionDuration="250">
<HeaderTemplate>
I tried this..not working:-
<script type="text/javascript">
function fnover(id)
{
document.getElementById("Accordion1").style.cursor = "pointer";
}
</script>
View 1 Replies
Aug 16, 2010
I have a web-application (ASP.NET) and want to open another external webpage on another machine. I have to forward some information (variables) to that webpage, but they should not be part of the URL. So my question is, how can I achieve this without querystrings?
View 1 Replies
May 13, 2010
This week my team spent way too much time trying to do simple things in reporting services, and I've decided to start evaluating other options. I know there are some good options out there now that aren't too expensive. I've heard that Telerik, ActiveReports, and a few others are widely used.I was hoping to get some first hand accounts regarding reporting toos that you've used. Specifically, I definitely want to hear your thoughts about:Pain points and gotchas you ran into.Ease of use for report design. It's a little bizarre to me that Access still seems to hold the throne in this area!
View 2 Replies
Sep 23, 2011
I have the following piece of code which works fine on all browsers except IE9:-
Code:
panArticle.Attributes.Add("onmouseover", "this.style.cursor='hand'")
Why this is happening and this there an alternative way?
View 5 Replies
Mar 31, 2011
<asp:GridView ID="GridView1" runat="server">
<Columns>
<asp:TemplateField>
<ItemTemplate>
<asp:TextBox ID="TextBox1" onchange="calculate()" runat="server" Text="0"></asp:TextBox>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
I'm getting this error on the above markup: Message 1 Validation (ASP.Net): Attribute 'onchange' is not a valid attribute of element 'TextBox'.
View 2 Replies
Mar 17, 2011
I have a problem with my web site 1stSigBdeAssn.org. I have made no changes to the site but I now get the following error message:
Parser Error Message:
Unrecognized attribute 'targetFramework'. Note that attribute names are case-sensitive.
Source Error:
[code]....
View 4 Replies
Aug 23, 2010
i am using Asp.net Chart and showing bar chart. i used dataPoint.MapAreaAttributes to call a JS func(which retrieves the ID) to show next chart on click of a particular bar in the existing chart. but i am unable show hand pointer on mouse over the particular bar on the chart. And when i use Datapoint.Url which is changing the mouse pointer to hand on mouseover the bar but i am unable to call the JS func. how to show Hand pointer on mouseover of a particular bar?
View 1 Replies
Jan 8, 2010
In my code I will be presented with url strings to pages... All I want to do is to extract the page name, nothing else... (Example)
string page1 = "./default.aspx";
string page2 = "./subfolder/gallery.aspx";
string page3 = "./subfolder/anotherSubfolder/demo.aspx";
I've used the substring feature before, but I am struggling with this one since I only want the page names which are on the right hand side, I basically want to chop of everything else (folder paths).. all I want to end up with is default.aspx, gallery.aspx and demo.aspx
View 4 Replies
Feb 1, 2011
I created a simple Master Page in Visual Studio 2008:
<%@
Master
Language="VB"
CodeFile="MasterPage.master.vb"
Inherits="MasterPage" %>
<!DOCTYPE
html
PUBLIC
"-//W3C//DTD XHTML 1.0 Transitional//EN"
and got green underlined 'Master' with two warning messages: 1.Validation (ASP.NET): This attribute name must be followed byan equal (=) sign and a value. If the value is in quotation marks, the quotation marks must match. 2. Validation (ASP.NET): Attribute 'Master' is not a valid attribute of element 'Control'.How I can get rid of the messages?
View 3 Replies
Jan 7, 2011
<td id="btnIcOld" style="text-align:center;">
<img src="<%= VirtualPathUtility.ToAbsolute("~/img/chic/Load.png")%>" />
</td>
[code]....
the image is my button, and that is the JQuery that handles the button click. when you hover your mouse over the image, it stays as the basic arrow pointer. How do I make it change to a hand so the user knows they can click on it?
View 4 Replies
Jun 1, 2010
I have a gridview that has LinkButtons and when I hover over the link instead of seeing an hand cursor, that allows me to click the link, I see a vertical bar, that's not clickable. This was working normally until recently, so I must have done something to cause it, but I don't know what?
View 2 Replies
Jul 4, 2010
I've been using the LongURL.org API for expanding short URLs. The great thing about this service is that it returns a long URL, the title of the actual page and meta-info.The real problem I have is that it seems to take an inordinate amount of time to fetch the data. I'm considering shifting the request to JavaScript so that the URL is fetched via an AJAX update panel, in order that the page loads quickly, and the URL data is updated while the user looks at the content (some search results).Does anyone know how else I could gather the info described above, n a better time-frame? I'm using C# ASP.NET but would consider solutions in other languages.
View 2 Replies
Oct 9, 2010
I have installed SQL Server 2008 express, reinstall it with advanced services, uninstall TFS 2010 and tries to reinstall it but fails. It doesn't want to completely uninstall.
So I'd like to clean everything by hand (deleting registries, folders) but can't find any info. I have deleted install directory but installer still memorized that TFS is installed.
View 2 Replies
Jan 8, 2010
I needed to display data from a table in this style:
Hotel: hotel1 Destination: United States
From: UK
Hotel: hotel2 Destination: United States
From: UK
Hotel: hotel3 Destination: United States
From: UK
This would all go in a box or table, the bold text is the column names from the table, but id be quite Happy to just have them as text and not display the coloumn headers. whats the best control to display data in this way, ive messing about with different controls but cant get this layout
View 3 Replies
Oct 8, 2010
I have this code in my view..
<div>
<input type="button" value="Cancel" id="btnCancel" onclick="window.location.href='../Reviewer'" /> <input type="submit" value="Save" id="btnSave" onclick="saveCreateHeader()"/><input type="button" style="margin-left:50px;" id="btnNextStep" value="Next Step"[code]....
due to this code I am getting a pageload error? is that something wrong with this?this is the Error I am getting in IE.Webpage error details
User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; GTB6.5; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E; InfoPath.2; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; AskTbF-ET/5.8.0.12304)
Timestamp: Fri, 8 Oct 2010 19:30:36 UTC
Message: Expected ';'
Line: 273
Char: 21
Code: 0
URI: http://localhost:25973/ProductTemplate/CreateHeaderIndex/42567
View 3 Replies
Feb 10, 2011
We are having an issue with a website...the short story is a date is selected from a calendar control such as 11/15/2010 but when it is saved it becomes 11/15/201 (last digit truncated). I am not the programmer debugging this so I don't know all the details, but it seems to be working on one server but has the problem on another.Could this have anything at all to do with the Regional and Language Options where you can specify your date format to be M/d/yyyy or MM/dd/yyyy? I would *hope* that would only change 02/09/2010 to 2/9/2010 and not truncate a year! But I remember this being a problem on the last project I worked on where dates were getting returned in a different format than that expected (again, suppressing the month from 2 digits to 1, or the day, but not the year...) Since this is machine-specific, it would explain why one server had it but the other didn't. But I don't want to suggest to the SA that he take a look, if I am way off.
View 7 Replies
Nov 9, 2010
Is there any way to tell a band to be shorter if there is no data in the fields in the bottom area of the band? Lets say we want to print in detail band:Line 1: Invoice Code, Invoice Total, Invoice Shipment ToLine 2: Invoice CommentsNormally if you set two lines of fields in detail band, Crystal Report force Min Height of Band to be the bottom of the second line, or bottom of objetcs in Band in general.I want to be able to tell him, make this Band As Short As possible, so if bottom controls or fields havent Data set the Height of Band to be not that tall !!!In other words if you let me "Can Grow" for some objects, please let me "Can shrink" for the whole Band.
View 1 Replies
Apr 29, 2010
I want to user accesskeys on my linkbuttons but somehow they trigger the browser's short keys.. like this
[Code]....
i want to change the ALT to CTRL instead to?
View 2 Replies
May 28, 2010
Let's say we are building some public service that grabs the setup of a user (what server, user and pwd he wants to perform the call), logs in into that server and do some processing...
the process takes about 15 seconds to complete each user has a different setup (server/user/pwd), so the process needs to run against each one
if 1000 users tells the system to run the method at 1:00PM
How can I insure that the method is processed in the next 15 minutes?
What should be the correct approach to this little problem?
I'm thinking that I need to do something Asynchronously, and parallel processing could speed up things, maybe throttling the processes, maybe execute 100 calls per each 30 seconds?
I never did something like this and would love to get your feedback on ideas and future problems just to spend 100 hours of work and realize that I took a wrong road
View 2 Replies