webforms

How can I make an entire HTML form "readonly" ? Server side only, please

Edit again: Surely this is standard stuff? I can't be reinventing the wheel??!! User fills in a form & you show it to him (using PHP, but that should not matter). YOu show it to him as confirmation, so he should not be able to attempt to change it again ... See related question, http://stackoverflow.com/questions/3503397/how-to...

Webform routing home page in a folder like mvc rather than root of site

Hi, I've got webform routing setup on my asp.net webforms 3.5sp1 project. I would like to have the files for the site in a directory called content including the home page as I would like to run multiple sites using the same system. In MVC there is a blank default page and the home page is in a folder called home. I can't seem to repli...

LinkButton in UserControl posts back but does not fire OnClick.

I've been looking at google for the past few hours, trying to find an issue to a apparently simple problem. I have a UserControl named RolloverLink that basically contains a asp:LinkButton and a <img /> . I tried setting the OnClick handler like this: <%@ Control Language="C#" AutoEventWireup="true" CodeBehind="RolloverLink.ascx.cs...

ASP.NET __doPostBack rendered after beginning or near end of form tag

I'm trying to manually call the ASP.NET (3.5) javascript postback function __doPostBack from my javascript code. The problem is that the postback script block, that is normally rendered right after the beginning of the <form> tag (and the hidden fields), is occasionally rendered near the closing </form> tag. Is there any way to force i...

Exporting ReportViewer to HTML

Does anyone know a way of providing an Export to HTML for ReportViewer WebForms? I know by default, Image, PDF and Excel are supported formats. I'm guessing there must be some sort of workaround to get the HTML of the report out? ...

how to view mvc template within a webforms hybrid app; staring with webforms.

I'm starting with a legacy webfoms program and adding mvc. I have mvc setup, but I can't get the mvc templates to show. I dont have a csproj file; I only have a solution file that points to a folder containing the files of the project;note, it is not pointing to a .proj file. It seems that you can only specify one guid that determines t...

Partial User Control

In Asp.net Web forms why must a user control be partial? I tried to remove the partial keyword and it says: Missing partial modifier on declaration of type 'test'; another partial declaration of this type exists Where is the other declaration? I am trying to pass a generic type with the user control how can I do that? I can...

Can a web server dynamically generate an executable on the fly?

Ninite.com seems to be doing it currently. I'm wondering how. While it's possible for them to have every combination of app pre-generated, it seems unlikely/hacky. [EDIT] Is compiling a Windows executable using this method resource-intensive? Can it be done ~100k times a day without exorbitant cost? I'm asking because Ninite announ...

asp.net 4.0 sys is undefined horror

[edit]: Figured out where it goes wrong. It has something to do with my Routing (note: im not using MVC but webforms). Here's the little piece in my global.asax which causes it: routes.Add( "Home", new Route("{PageIndex}", new p7r.Routing.HomeRouteHandler()) ); Now this is the route for the hom...

Joomla interaction with php script is problematic / the "action" attribute in forms

I have made a personality test. It is a set of multiple choice questions that when the user submits, gives a personality description as output. The test questions are placed in a Joomla "Article", so the owners of the test can easily change them, and the output is then via the form handle passed to an external php script. Like this: <f...

Display three level hierarchial data display in ASP.NET Web Forms

The coding is in ASP.NET 3.5. Here is the scenario. I am modifying a page that populates some data. In that page there is a table that displays pages. The pages have sub-pages and these sub-pages again have sub-pages. So thats three levels of hierarchal data presented. Example: Right now its populated using asp:Treeview for easier dis...

performance tuning of ASP.NET webpage

One of my ASP.NET webpage is taking more time to load and I want to optimize its performance. During debugging, I am not able to find where it is taking more time. It looks all fine. Is there any special way or any option with Visual Studio 2008 for performance tuning? ...

MVC philosophy applied to webforms.

I'm pretty new to programming in general (really started only 2 1/2 years ago) and I'm trying to decide what the best way is to approach a web app I'm making at work. A senior developer at work is encouraging me to get into MVC and after a good 24 hours of pouring over blogs, source code and other material on the subject I'm beginning to...

What is the most comfortable datatype I can use to populate a DropDownList with?

For example, I want a user to create a new fanclub for a given Team. Obviously the teams have to be loaded into a DropDownList so they are chosen from a pre-set choice group. The list of teams are returned from a database. As of now I'm doing things like this: //FindAll() returns IQueryable<Team> var Teams = teamsRepo.FindAll().AsEnum...

Submit a form that is saved in a string (ASP.NET) ?

I have a HTML form a string variable. e.g: there are below string in FormBody variable string. <form id='paymentUTLfrm' action='...' method='post'> <input type='hidden' name='CardAcqID' value='131211234234667' /> <input type='hidden' name='AmountTrans' value='1' /> <input type='hidden' name='ORDERID' value='1' /> <input type='hi...

c# web form Post file upload to from c++ program does not work for binary (zip) files.

I have a simple C# aspx script page hosted on IIs that uploads a file along with some email addresses and message etc. and sends an email with uploaded file as attachment. This all works fine from a browser, no problem, but that is not what I am trying to do :). I want to do this from within a c++ application so I wrote a class to mim...

Should I use a mixture of POST and GET for this form sequence?

I have a sequence of forms that follows the following algorithm: Form #1 Prompt for input of value A. Send X* request with value A. Form #2 Display value A and prompt for input of value B. Send POST request with value A and B. *Should X in step 2 be GET or POST? I was just going to make it POST, but hesitated and wondered if I s...

Where can I find an ASP.NET Webforms-compatible chat client with hooks to add additional functionality?

I have a client looking to add chat functionality to their Webforms-based site. They would like the following additional features (beyond the usual chat stuff): When a client conversation is started, the customer service rep is presented with a view of the order the customer is inquiring about. (As determined by the page on which th...

ASP.NET 4 Routing catch all

I have an ASP.NET 4 WebForms application which is using routing. I would like to catch the 404's for routes that do not exist: RouteTable.Routes.MapPageRoute("404", "{*url}", "~/error"); Problem is, this will also cause a mapping to /error for pages like ImageHandler.ashx and Resource.axd. So I add this: RouteTable.Routes.Ig...

Data binding boundfields in web form

I have the following DetailsView, with several BoundFields, and SQlDataSource that populates the fields: <asp:DetailsView ID="DetailsView1" runat="server" AutoGenerateRows="False" DataKeyNames="TICKET_ID" DataSourceID="SqlDataSource1" HeaderText="Completed IT ticket information" CellPadding="4" ForeColor="#333333" GridLi...