asp.net

How to set dropdownlist in .aspx page from managed code via DOM

I've a control that sits in the .aspx page, but the dynamic code is in separate project in Page.xaml.cs. On the same page as the control, I have: <asp:DropDownList ID="DropDownAppServer" runat="server" > In the Page.xaml.cs I've tried doing this: HtmlElement element = doc.GetElementById( "DropDownAppServer" ); element.SetAttribute(...

ASP.net dropdownlist load on demand

Hello, I was wondering if anyone know or come across any tutorial or howto on loading data to the dropdownlist on demand like the rad control by telerik where you can initially load say 10 items to the dropdownlist control then at the very bottom of the dropdown there is a continue or load the next 10 items, click on it then the control ...

Any good references or tools available for converting ASP to ASP.NET?

What tools, practices, or documentation have you used in your conversion process that you would recommend to others? ...

What does the utmscr or utmcct values mean in reference to the Http cookie Server variable?

What does the utmscr and/or utmcct values mean in reference to the Http cookie Server variable? Are they acronyms or short for something? We are getting Elmah errors with the title "System.Web.HttpException: Unable to validate data." In each Elmah error message, the Http Cookie server variable value contains a property called utmscr s...

Adding "onclick" attribute to asp.net dropdownlist item.

I can add an attribute to items in a RadioButtonList item like so: PaymentMethodDropDownList.Items[0].Attributes.Add("onclick", "javascript:showNoMethods();"); PaymentMethodDropDownList.Items[1].Attributes.Add("onclick", "javascript:showCreditCardMethod();"); PaymentMethodDropDownList.Items[2].Attributes.Add("onclick", "javascript:showS...

Handling Login.Authenticate event

Hello, A) Book I’m learning from says that if we handle Login.Authenticate event, then we have to authenticate users on our own. Thus control won’t automatically validate username and password. I thought book suggested this would only happen if we override Login.OnAuthenticate() method, but it appears that even if only add an event ha...

Login control template and Control ID = Login

Hello, When using custom template for Login control, if we add control with ID = Login and set its CommandName to “Login”, then Login control will automatically handle authentication. Control with ID=Login can be any control that supports event bubbling. Thus I assume this control can be either Button, ImageButton, LinkButton o...

Moving Settings to another config file

Hi. Is it possible to move applicationSettings to another config file as it is possible with connectionStrings or appSettings? When I create Settings for my web application using the designer I get applicationSettings section in my web.config such as: <applicationSettings> <TestWebApplication.Properties.Settings> <setting...

ASP.NET RadioButtonList generating extra HTML for a ListItem that contains an image

In my application I have a RadioButtonList: <asp:RadioButtonList runat="server" ID="CardTypeRadioButtonList" RepeatDirection="Horizontal"> <asp:ListItem Value="Visa"> <img src="../images/icon_visa.gif" alt="Visa" align="absmiddle">&nbsp;Visa </asp:ListItem> <asp:ListItem Value="MasterCard"> <img src="../image...

a little complex Linq2SQl insert operation (Dynamic user control and page insertion)

hi, i am really trying to do this but i am failing to find a way. here is the scenario, i got a blog module i made for my clients, because it is a repeatative task, so i all i have to do is to just upload it to new client and he can start blogging, but some clients need extra custom fields, let us say he wants to add a phone number for ...

Error when deploying ASP.NET MVC NHibernate app to IIS7

I have an Asp.Net MVC application that works in the vs.net development web server. When I publish to IIS7 I get the following error. I have spent many hours and still no solution! [NullReferenceException: Object reference not set to an instance of an object.] System.Web.PipelineStepManager.ResumeSteps(Exception error) +929 System...

Javascript error in Firefox when using ASP.NET AJAX Control Toolkit

I have recently been building a website that utilizes the .NET Framework 3.5 SP1 and the AJAX Control Toolkit. The standard AJAX controls such as UpdatePanel work without problem. As soon as I add a CollapsiblePanelExtender control from the AJAXControlToolkit to the page I receive a Javascript error. (NOTE: this problem occurs on Firef...

How can I convert a .Net Datetime to a T-SQL Datetime

MyDataSource.SelectParameters["startDate"].DefaultValue = fromDate.SelectedDate.Date.ToString(); As you can see I am setting the default value of a parameter in my .Net SqlDataSource. I don't think the string is outputting the correct format though. What is the correct format so a T-SQL Datetime wil...

Attach RequiredValidator on custom server control rendering a TextBox

Hi, I don't know whether this is really possible, but I'm trying my best. If I have a (complex) custom server control which (beside other controls) renders a TextBox on the UI. When placing the server control on a page, would it be possible to attach a RequiredField validator to that server control, such that the validator validates th...

ASP.NET MVC REST Service

If you have been following my past question, located here,link text I had more ?'s If I go with ASP.NET MVC service, my client at prersent has 1 stored procedure which has 20 nullable parameters and returns the search result which I could turn to json or pox. The question is how would I invoke the MVC with so many parameters? They pre...

Could aspnet_regsql.exe be used to create DB capable of storing several email addresses...

Hello, Q1 A) Is there a way to create membership database ( using aspnet_regsql tool ) where each user could have several email addresses specified ( instead of just one ) during registration process? B) Is there also a way to somehow "inform" Security wizard in WAT to include new input fields ( where additional email addresses w...

Why are backward slashes removed from querystring - ASP.NET & Javascript

I am trying to generate a URL that contains a UNC path as one of the query string variables. The URL will open in a pop up window when an ASP.NET button control is clicked by the user. When the clicks the button, the backwards slashes are removed from the UNC path causing the page to break. The button renders correctly in the page sou...

VS2008 ASP.NET Website vs. Web Application

Hello, In Visual Studio 2008 ASP.NET in C#, what are the pros and cons of starting with an ASP.NET Web Site vs an ASP.NET Web Application? Which was introduced first? Is one approach the "more modern" approach? In what situations would you use one versus the other? Thanks! Adam ...

Should i write in C# first then port to web?

I wanted to write a website but i know almost no web programming. I looked at ASP.NET and i wanted to know. Should i write my app in straight C# with a form and many buttons to test each page/component? then port or have someone help me port? or should i do it from straight ASP.NET from the start? -edit- I edited the below after the fir...

C# sqlite syntax in ASP.NET?

-edit- This is no longer relevant and the question doesnt make sense to me anymore. I think i wanted to know how to create tables or know if the syntax is the same from winform to ASP.NET I am very use to sqlite http://sqlite.phxsoftware.com/ and would like to create a DB in a similar style. How do i do this? it doesnt need to be the ...