asp.net

The calendar control in ASP.NET

Calendar Class .NET Framework 2.0 Other Versions Displays a single-month calendar that allows the user to select dates and move to the next or previous month. Namespace: System.Web.UI.WebControls Assembly: System.Web (in system.web.dll) Questions By default which calender type does it use? (english,german,western,eastern etc...

Asp.Net Nested Websites

What I'm trying to do is have a portfolio type of site where there is the main site and then say a customers folder and in each customers folder is the customers site. so something like mysite.com/cuustomers/customer1 would bring up there whole site. What do I need to do to the web config file of the nested site to get this to work. T...

Third party service to trigger web service

I am looking for a third-party service or tool that can trigger or hit a web page at scheduled times. Does anyone know of any? I currently use my windows scheduler to hit these pages, but there are gaps in this since I don't run my computer 24 / 7. ...

asp.net web application

i am new for asp.net. i want to develop a simple web application(asp.net+c#) which display questions and multiple choice answers and calculate result. i want to know which one is the best way for me to do it. i want to use linq to sql. please guide me. thanks in advance and sorry if you feel my question style is bad. ...

HttpHandler for Asp.NET MVC application

For general ASP.NET WebForms applications, the web page derives from Page class which implements IHttpHandler that servers actual web request. In ASP.NET MVC the webpage base class is System.Web.Mvc.ViewPage that also derives from Page class which in turn implements IHttpHandler. But in the ASP.NET MVC Razor, the "cshtml" file derives ...

Why did they use this C# syntax to create a list of links in ASP.NET MVC 2?

I'm having hard time understanding the following C# code. This code was taken from Pro ASP.NET MVC 2 Framework by Steven Sanderson. The code esentially creates URLs based on a list of categories. Here's the code: Func<string, NavLink> makeLink = categoryName => new NavLink { Text = categoryName ?? "Home", ...

Asp.NET MVC - Difference between ViewPage and WebViewPage class

Waht is the difference between ViewPage and WebViewPage in ASP.NET MVC? ...

Object persistence in .NET and SQL Server, with incomplete values

I am building a form in Net framework 4.0 using linq to sql , and had a question about object persistence. I have a case where a user is asked to fill out a very long form several pages in length. Since it is so long, there is a need to SAVE the data midstream. Session level persistence is not an option, since they could SAVE the form...

ASP.NET AsyncFileUpload RegisterClientScriptBlock not working

Hi guys. I have a problem working with ScriptManager's RegisterClientScriptBlock which is not working. I have a AsyncFileUpload and I want to preview the uploaded image dynamically after the upload. the UploadedComplete is wired in Page_Init and here's the UloadedComplete block code in server side void fileUpload_UploadedComplete(obj...

ASP.NET FormsAuthentication and membership

I can use forms authentication in ASP.NET without membership. i.e: FormsAuthentication.RedirectFromLoginPage(usuario.UsuDs, false);//usuario.UsuDS is the textbox username in login's form Then i can write code like: [Authorize(User="UserTest")] public ActionResult Criar(Usuarios usuario) { try ...

Would a browser ever ignore case sensitivity of the location header when responding to a redirect?

If a browser requests http://site.com/?q=abc and gets a 301 redirect response to location http://site.com/?q=ABC (note case of querystring) Is it possible for the browser to ignore the difference in case and re-request http://site.com/?q=abc, thus causing an infinite redirect loop? That's the scenario that appears to be happening acco...

How can I throw an Exception if Session is written to in ReadOnly mode?

I would like to find a way to raise an exception if the Session is written to when in readonly mode. When EnableSessionState is set to "ReadOnly", values can still be put in Session, but the next request they will not be there. This seems somewhat dangerous. One option is to create a helper class which we alway use to access session. H...

How to MSDeploy a built website package to a virgin IIS website

I am trying to automate our build/deployment process. So far I am using: a Visual Studio 2010 solution with a main Web Application project (and dependent projects) MSBuild MSDeploy CruiseControl.Net So after much wrangling and gnashing of teeth, I now have CCNet kicking off an MSBuild script to build, package and deploy the website....

Pass ID from GridView row to Javascript function

The first commented line below is working with a hardcoded ApplicantId, and all I need is to make it work by passing the current ApplicantId column on the same gridrow. I've tried for many days now, and something like the second commented line does not work for me. Please help. <asp:GridView ID="GridView1" runat="server" AllowPaging="...

showing and hiding a div using jquery and asp.net in the middle of screen

hi folksI have this following code but it gives me "invalid argument" error when I click on the 'a tag'. what is my mistake ? <script type="text/javascript"> $(function () { $('#click').click(function () { $get('log').style.top = (screen.y / 2).toString(); $get('log').style.left = (screen.x / 2).toSt...

Get .NET Page from URL

I am using jQuery within a server side control to post back to a common handler. For instance, I have "/handler.ashx" which services pages all over my application. How I want some code within handler.ashx to be able to get the class which created the page that the control is on. In handler.ashx I can see the referer (for example Refe...

REtrieving Client IP in ASP.Net Request

Hi, I would like to fetch the client ip address of the person visiting my website. in this case my webpage is an iframe application in facebook. i have tried using Request.UserHostAddress and the server variables. REMOTE_ADDR , HTTP_X_FORWARDED_FOR . However it does not seem to work. it always returns an address in California. { probab...

Creating a Website Widget / API

Hi all, I recently created a website for a friend (asp.net/sql server), the website includes news of his company and he and his team update this frequently. The question has been asked if i could now create a widget / api of some sort that visitors of the website could now include the news on there own website should they wish too. I f...

Facebook signed_request validates but no data in decoded payload: C#

Folks, would really appreciate your help on this as maybe I'm just missing something really obvious. Basically, i'm trying to develop a Facebook canvas iframe app in C# ASP.NET that a business can install on a fan page and users can access via a tab. Main Requirements: 1. Business clicks install which takes them to apps.facebook.com/m...

What's wrong with these asp.net mvc routing rules?

I have defined a series of Routes in Global.asax.cs: public static void RegisterRoutes(RouteCollection routes) { routes.IgnoreRoute("{resource}.axd/{*pathInfo}"); routes.MapRoute(null, "", // Only matches the empty URL (i.e. ~/) new { cont...