asp.net-webforms

Getting the url of an aspx page using the page type

I'm using a web application project. I have a folder in my web root called Users and in the folder I have a page called UserList.aspx What I want to be able to do is type in Response.Redirect(Users.UserList.URL) What I reckon I can probably do is create a class that extends Page and add a static property called URL that calls MethodIn...

Listbox items client side reordering not reflected in server side (ASP.NET)

I reordered some items in a listbox using Javascript. When I read the items in a postback in the code behind (ASP.NET), the order is in the original order. How do I get the same order as shown in the screen after Javascript manipulation? ...

How do I do an http post to code behind in asp.net webforms?

Hi, How can I call a method in the code behind from a jQuery post in asp.net webforms? In MVC it's simple, I just do this: $.post("/MyController/MyMethod", { data: somedata; }, function(result) { alert(result); }); but I can't figure how what to put for the first parameter if I wanted to call a method in the code behind in webforms....

Windows authentication mode in ASP.NET uses the Active Directory group name (pre-Windows 2000)?

Here is the background. I had an .NET MVC v1.0 project that I was trying to secure it by using Windows authentication mode. So I set the web.config to: <authentication mode="Windows" /> And then went into my controller and did the following: [Authorize(Roles="IT")] public class LicenseController : Controller In AD we have a group c...

How to perform same operations on both WebControls and HtmlControls.

I find myself needing to preform the same actions on both HtmlControls and WebControls. I am a firm believer in DRY and find the fact that there is only the Control class to use if I want to consolidate the functions on both types. The problem that I have with using Control is that there certain properties that both HtmlControl and Web...

ASP.NET MVC + WebForms

Hey, I've been searching how to add webforms to MVC project but there lots of sites explaining only how to add MVC to an existing webforms project. Is there a way to do that ? Maybe need to add some code at Web.Config ? The .aspx.cs can't find any control on the .aspx webpage, that's the trouble ! Thanks! ...

Is jquery worth a try with an asp.net webform application?

Hai guys, I ve been using javascript to get my validations,effects and so on... Now i ve decide to use jquery in one of my webform application Is jquery worth a try with an asp.net webform application? Will ajax update panel be an issue for me when using jquery? I ve studied that the ready event will not fire for an asynchronous po...

Prevent multiple logons for a single user in ASP .Net

I am looking at how best to prevent a single user account logging on multiple times in a webforms application. I know that MembershipUser.IsOnline exists, but I've read a few forum and blog entries suggesting that this can be unreliable, particularly in scenarios where a user closes a browser (without logging out) and attempts to logon w...

How could I use ASP.NET MVC framework in conjunction with my CMS software?

I have been reading on MVC and I created some db-driven pet projects with it and I am very pleased with the shift from WebForms. However, I have a bit of a limitation that holds me back with WebForms and I was wondering if you could help me with it. I work for a Web CMS company as a Consultant, therefore all websites (public sites, int...

Help with a regular expression to validate a series of n email addresses seperated by semicolons

I'm using an asp.net Web Forms RegularExpressionValidator Control to validate a text field to ensure it contains a series of email addresses separated by semicolons. What is the proper regex for this task? ...

Learn Asp.Net WebForms or Asp.Net MVC

It might be a dupe but I cannot find a straight answer. If a person is about to start learning web development over .Net framework, which technology should he go for ? Asp.Net WebForms Asp.Net MVC keeping in view these three aspects future scope complexity features Note: has done some WinForms programming using C# Thanks ...

Data Bound RadPanelBar in ASP.NET Not Collapsing

Hello, I'm binding to a RadPanelBar control using the ItemTemplate; it creates the RadPanelBar correctly using this approach, but the panel bar doesn't close when you click on the header??? How do you get the header click to close the item, or is there an alternative way for this kind of setup? <tel:RadPanelBar ID="r" runat="server" D...

How to use Thickbox with jqGrid on a ASP.NET WebForms Page ?

I have a asp.net webforms page in which I'm using the jqGrid component. The problem is that thickbox is not working on the links inside jqGrid (ajax). I got this peace of code on Gupta's blog but I don't know how to add it as I'm using the jqGrid component for ASP.NET. Can anyone help ? Thanks. gridComplete: function(){ // ThickBox - t...

Ninject.Web.PageBase still resulting in null reference to injected dependency

I have an ASP.NET 3.5 WebForms application using Ninject 2.0. However, attempting to use the Ninject.Web extension to provide injection into System.Web.UI.Page, I'm getting a null reference to my injected dependency even though if I switch to using a service locator to provide the reference (using Ninject), there's no issue. My configur...

What would be considered straight asp.net? (not mvc and not webforms)

I know the difference between ASP.NET webforms and ASP.NET MVC and I've seen quite a few videos explaining that they both run on top of ASP.NET (and I've used both). However, my question is, how would one develop right on top of ASP.NET without webforms or mvc.net? Would this be the equivalent of having a project with only .ASHX files?...

Ckeditor value saved on explicit save only, any ideas why?

Trying to troubleshoot a bug on this little legacy app and have run into a problem. The left column contains a gridview with the master records, when a row is selected the main area of the page populates with the details for that row including a ckeditor instance to capture notes and a save button calling a click event which saves the d...

ASP.NET: Compress ViewState

What are the latest and greatest ways to compress the ASP.NET ViewState content? What about the performance of this? Is it worth it to keep the pages quick and minimize data-traffic? How can I make: <input type="hidden" name="__VIEWSTATE" id="__VIEWSTATE" value="/wEPDwUKMTM4Mjc3NDEyOWQYAQUeX19Db250cm9sc1JlcXVpcmVQb3N0QmFja0tleV9fFgkF...

ASP.NET: Moving ViewState to bottom of page

What are the latest and greatest ways to move ViewState to bottom of the page Can this be done in a IHttpHandler that can be specified in the web.config to intercept requests to "*.aspx"? <httpHandlers> <add verb="*" path="*.aspx" type="MyApp.OptimizedPageHandler" /> <httpHandlers> Other options is that this could be done in a IH...

Uploadify not working with ASP.NET WebForms

Hi ! I'm trying to use Uploadify in a ASP.NET webforms project. The problem is that my script is not calling the generic handler. Here is the script. <input id="fileInput" name="fileInput" type="file" /> <script type="text/javascript"> $(document).ready(function() { $('#fileInput').uploadify({ 'uploader': '/Ferramenta/C...

How to find what ActiveX control is referred on a web page?

I have developed a web application (ASP.NET Web Forms). One of my customer has very restrictive policies. When he accesses the web page, IE shows this message: Your security settings do not allow Web sites to use ActiveX controls installed on your computer. This page may not display correctly. As far as I know, we don't use ActiveX con...