asp.net

Problem in Caching Images in ASP.Net in IIS 7

I have implemented caching Images in my website, It is working fine in IIS 6 but not working in IIS 7 problem is images not shown on my website on iis7 hosted server but shown on iss6 hosted server I have implemented caching using this Article.... http://www.codeproject.com/KB/aspnet/CachingImagesInASPNET.aspx Does anyone have any idea ...

Firefox does not deliver pdf if it is handled by http-handler and inside iframe

I have a site that runs on IIS7 ASP.NET 3.5 I implemented a http-handler that serverves pdf. If I request a pdf-document (www.mysite.com/mypdf.ashx?id=doc1) in Firefox 3.0 I get the result in the browser. I now have an iframe on my page. The src - attribute is set to www.mysite.com/mypdf.ashx?id=doc1. The document is displayed in IE7...

Why do i get "uselpffregexps is undefined"-error in FireBug, while debugging AJAX Control Toolki enabled website

Hello, i'm getting the error stated in question title, when i'm debugging a site where i use MS AJAX Control Toolkit aspx-controls? Anyone have any idea that where is this error coming from? Google didn't find a single hit, so i don't have a starting point for fixing this problem. Here is the output from FireBug: uselpffregexps is un...

Validation of email addresses (ASP.NET)

I have a asp.net web form where i can can enter an email address. i need to validate that field with email addresses ONLYin the below pettern : [email protected] [email protected] [email protected] Please help ...

Last Five Pages Visited Cookie

Hi, So, I have a series of product pages and all I'd like to do is store the last 5 products viewed in a cookie so it can be displayed as a site-history. The problem I have isn't adding the five initial items to the cookie, its when they view 6, 7 or 10 items. Does anyone have any really decent suggestions on how to tackle this? Curr...

How can I know under which IIS version my Asp.Net application is running?

How can I know under which IIS version my web application is running in development server? As .Net framework 2.0,3.0,3.5 have support built in IIS.... Thanks ...

IF EXISTS IN STORED PROCEDURE

hi guys, I am using following storedprocedure set ANSI_NULLS ON set QUOTED_IDENTIFIER ON GO Alter PROCEDURE [dbo].[GetUserDetailsByUserID] ( @UserId varchar(100) ) AS BEGIN IF EXISTS(Select * from Registration where UserId=@UserID) BEGIN Select [Name], [UserId], [PermanentAddress], ...

Validate Gridview

hello, I have gridview with template fields(textbox,dropdown list,...) and I use required field validators for the textbox and dropdownlist where I make the validation on textchanged and dropselected index changed my problem is that the validation happend on all rows not just on the row where i change the text any idea? validation is go...

check if javascript is enabled and display a message if it is not using an asp custom control

Hi, I'm using Javascript, ASP.net and c#. I want to write a custom control to check if javascript is enabled on the browser and display a message. I'm using the following approach: -the control shows a message "Javascript disable" in a tag -the control adds in the section a javascript section with this line: window.onload = function()...

keyboard shortcuts for creating Event handler stubs in Visual Studio

When you edit a simple page in the design view you can add an event on most components by simply doubleclicking the relevant event in the design view, which does the binding and generates the function declaration in the codebehind for you. In larger projects where the pages are complex, the design vew can be extremely slow. Is there a w...

How do I set the selected value in an ASP.NET Drop Down List?

I'm using an ASP.NET dropdown. I want to set the selected element using an ID (Id) which is stored in the DataValue field. ddlTest.DataValueField = "Id"; ddlTest.DataTextField = "Name"; ddlTest.DataSource = searchResultList; ddlTest.DataBind(); But all I can see is the SelectedIndex property which isn't the correct thing. How do I...

How to Send a Any File Type through Redirect in ASP.NET?

I currently have a TreeView showing a directory in a web page. I don't think you can capture click events on a Node so instead I'm creating the navigation link to the same page which processes a parameter (path). I've tried a couple things: Response.ContentType = "text/txt"; Response.AppendHeader("Content-Disposition", "attachment; f...

ASP.NET MVC, LINQ and UpdateModel issues

Ok - I have two tables in the database, employees and companies. Here are the basic schemas for each Table Companies CompanyID - GUID - PK CompanyName - NVarChar(100) Other Descriptive Fields.... Table Employees EmployeeID - GUID - PK CompanyID - GUID - FK Employee Descriptive Fields... So now I have a one to many relationship as ea...

asp:GridView style not chaning in IE

I put a gridview on a page and used one of the default styles that VS 2008 comes with. I used brown sugar and then changed the values for the backcolor, forecolor, etc, but when I run it in IE, it still takes on the Brown Sugar appearance. When I run it in firefox, it is applying the styles I gave it. ...

How to include different Javascript files depending on build configuration?

Is there a way to include a different Javascript file in an ASP.NET page depending whether it's a debug or release build? For release builds, I want to include the minified (using yuicompressor) Javascript, but I would like to use the more readable file for debug and development. ...

asp.net scheduling / booking system

Hi, We want to try fast track developing a booking/scheduling system for a doctor's room. The faster to market the better! End of the day, a scheduling product is dirt standard, and i reckon that there must be a ton of good components out there. It just takes time to go through and evaluate. Ideally we want to do this in asp.net - the s...

web.config error

i am trying to deploy my website to my host and get following error message on my web. config file: The configuration section 'connectionStrings' cannot be read because it is missing a section declaration at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse respon...

Why does Visual Studio add an at sign (@) to my namespace?

I have a web application project called Site, and in it is a folder called SITE (I know, not the best naming conventions, but that's another story). When I check the designer generated code it starts like this: namespace Site.@__SITE__ { Why is the at sign added? I can remove it and the project compiles and runs fine. Also, with or w...

Sending JavaScript Array to .ashx for handling

I need to send a JavaScript array via querystring to my .ashx. In my .ashx (handler) I'll have a method that will need to parse through each value in the array and populate a generic List Just trying to think about the way to go about this both passing it to the querystring as well as how to take that querystring value and convert it t...

How Can I Make the XmlIgnore Attribute Method-Specific in a WebService (ASP.Net)?

I understand that I can make the property nullable or use a bool called [PropertyName]Specified to determine whether the property is serialized to XML, but I would like the auto-generated examples to hide these elements in one method's definition, and show them in another. This way the user knows whether they'll be there or not. For ex...