asp.net

What is default hash algorithm that asp.net membership uses?

Hi all. What is default hash algorithm that asp.net membership uses? And how i can change it? Thanks. ...

ASP.Net Ajax client side framework failed to load while using MultiHandleSliderExtender

MultiHandleSliderExtender cannot be displayed in IE7 but gets dislayed in IE6. It is created at runtime and gives ASP.Net Ajax client side framework failed to load along with sys is undefined error. ...

aspx popup doesnt work with windows forms authentication

In my web application which is a ASP.Net site using Framework 3.5 at few places i need a popup to appear for user to fill out information. The problem is at majority of the IE it runs fine but at few IEs it takes the user back to login page. I am also sending the windows properties as argument in the showModalDialog function so as to re...

AJAX behaving differently for Submit button vs. this.form.submit?

I'm trying to auto-save a selection in a dropdown (ASP.NET, MVC, VB), but it's not behaving as expected. Here's the dummy action in the controller: <AcceptVerbs(HttpVerbs.Post)> _ Function TestAction(ByVal id As Integer) As ActionResult Return Content(id) End Function and the HTML: <script type="text/javascript" src='<%= Url.Cont...

Possible - cancel user control rendering if not loaded in x seconds?

This is probably a lark, but for the recaptcha control as it sometimes takes a long time to render, is this possible? If it takes more than say 5 seconds to render, I'd like to stop the rendering of the object and display my own captcha. I'd start a timer on page load and if 5 seconds has elapsed, in some event in the recaptcha con...

Javascript DoEvents equivalent?

Here is my shortened code snippet: $(document).ready(function() { $.get("/Handlers/SearchData.ashx", function(data) { json = $.evalJSON(data); }); //do some other stuff //use json data alert(json == null); }); Alert says true because evalJson is not done processing JSON data yet (21kb gzipped). I need to wait somehow for it to fin...

Set CommandField Select Visibilty from aspx page

Hi, I want to do something like this with a GridView: <asp:CommandField ShowSelectButton="True" Visible='<%# return Eval("SC_TABLE") %>' /> But that doesn't work, coming up with error: Databinding expressions are only supported on objects that have a DataBinding event. System.Web.UI.WebControls.CommandField does not have ...

Elmah - Download Log Is Empty

I recently started using Elmah on our ASP.NET site and it's great however I've run into a problem. Although my log contains plenty of errors (220 to be exact) and I can view them with the web viewer and rss, when I click Donwload Log it simply downloads an empty csv. There is one row for the headers, but no rows! Has this happened to ...

ASP.NET Page_Init Fired Twice!

I have AutoEventWireup="true" and in my code behind protected void Page_Init(object sender, EventArgs e) { } When I'm debugging the Page_Init method is getting fired twice! Whats going on!?! ...

Create select list with first option text with mvccontrib?

Trying to create a select list with a first option text set to an empty string. As a data source I have a List of a GenericKeyValue class with properties "Key" & "Value". My current code is as follows. <%= this.Select(x => x.State).Options(ViewData[Constants.StateCountry.STATES] as IList<GenericKeyValue>, "Value", "K...

How do I embed an ASP.NET Web Site (or Web Application) into another?

I have very little experience with ASP.NET and I am doing some self-training before I start writing my first web site/application, which will be a calibration utility. How that utility works is not my concern right now. However, the utility eventually needs to end up embedded in someone else's web site, either just as a URL to the page w...

Binding of repeater not showing anything after getting 2nd set of products

My Page_Load calls the following: pnlProductWrapper.Visible = true; pnlList2Column.Visible = true; rptList2Column.StartIndex = startIndex - 1; rptList2Column.NumItems = productsPerPage; rptList2Column.DataSource = UseManualProductList() ? lPage.LPageProducts.Values.ToList() : products; ...

Script control client object loss of scope

I've got a script control that has a control embedded within it that exposes a server side property for a client side click event. For example, embeddedControl.OnClientAppointmentClick. So my question is how would I wire this event to my script control client object. I've tried something like embeddedControl.OnClientAppointmentClick =...

Is there a way to add name/value functionality to jquery autocomplete for .net?

I've recently added the JQuery autocomplete plug in and have a textbox that autocompletes a list of employees. It works great and I commend the authors of the plugin. I think the textbox would be MUCH more useful though, when upon selecting, we can extract the StaffID (Ie. retreive the value of the selection). My code is below and y...

SQL Server 2005 - Pass In Name of Table to be Queried via Parameter

Here's the situation. Due to the design of the database I have to work with, I need to write a stored procedure in such a way that I can pass in the name of the table to be queried against if at all possible. The program in question does its processing by jobs, and each job gets its own table created in the database, IE table-jobid1, t...

C#, getting cookies with different names

Hi, I set cookies based on the referral links and they all start with the same letters, lets say "google", but they end with _xxx, _yyy, _zzz or whatever is the reference. Now, when I try to get the cookies later, I have the problem that I don't want to check for all of the different cookies, I would like to check for all cookies that s...

ASP.NET Application Suite Development - Gotchas

This may sound a bit general, but I have a startup that is working on an ASP.NET (greenfield) suite of software applications. We are aiming to spend a substantial amount of time in the architecture phase to develop a strong foundation for our software. I was wondering if anyone has any advice, anything we should focus on or any suggestio...

Autocomplete extender in Ajax Toolkit and JQuery limiting to "Starts with"

There are many flavours to the AutoComplete implementation, I first did a WPF implementation that was very robust, each entry took keywords, so when searching for an employee, it didn't matter if you typed the first or last name, the results came back similar to Google Suggest. What I have found limiting in both the JQquery autocomplete...

Why does Application_BeginRequest() fire twice when refreshing browser?

I'm observing some really confusing behavior with the Application_BeginRequest event in my Global.asax file (in an ASP.NET MVC app). When running through the debugger, if I Refresh my browser (IE7), this event fires twice. If I click a link or otherwise manually request a page, it fires once - as expected. Why does a refresh cause Beg...

asp.NET MVC Model State Validation Issues

I am having issues adding validation methods to a couple of controls in my MVC app. I use the following to test for the mm/dd/yyyy format: if (!Regex.IsMatch(candidateToEdit.availability.StartDate.ToShortDateString(), @"giantregex")) ModelState.AddModelError("availability_StartDate", "Start date must be in the mm/dd/yyyy for...