asp.net

how to test aspx page behaviour when multiple requests(~50) are made simultaneously using visual studio

I have to test my asp.net web application for performance when there are simultaneous requests for the web site in my developer machine before deploy in production. how can i achieve this using Visual Studio?.(without using third party tools preferably Visual studio 2010 professional edition ...

How do I prevent URL entry and redirect the user to login page?

I am using forms authentication on ASP.NET. If I try to access a page by copying the query string and pasting it into the browser, it allows me access to the page. How can this be prevented? I want the user to always have to login. ...

ASP.NET Gridview paging does not work if the grid is not loaded during Page_load. Tried all methods

Hi, I have a gridview which I load with data on click of a button. For some reason the paging did not work. The paging number shows up but clicking on page # 2, 3 or 4 does not take you anywhere. the grid just disappears on clicking them. right after that when i click the button to generate the grid, the grid came up this time the gird ...

determine user control parameter at runtime

I have a user control which I call like this: <MyNamespace:MyControl runAt="server" ID="foo" /> Is there any way I can determine the ID parameter at run-time and pass it in? ...

How do static properties work in an asp.net enviroment?

If I had a class with a static property that is set when a user loads a particular page, is that static value unique to that users session? In other words, if a second user then loads the page and sets the static property, will each user have a distinct value, or will both use the second users value? ...

How to make password field not reset?

I want to edit an user. I dispay the corresponding data(username, email,..etc..password, confirmation pass) The problem is that those password fields are empty. Q: When i display data in the form the two password fields are empty. How can i make them contain data? Thanks. I am using asp.net-mvc 2 <div class="edi...

Execute ASP.NET Membership Login from codebehind in button click handler

I'm trying to seamlessly log in the user without prompting for credentials as part of a <asp:Wizard> process. My strategy is to handle the NextButtonClick event and login the user in code. I already have the user's credentials saved in session variables. Is it possible to login a user in code? Will a hidden <asp:Login> control behind th...

Does sensitive ASP.NET Session data need to be encrypted?

Do ASP.NET Session[string key] data need to be encrypted to be secure? If such data always stays on the server, doesn't that make it safe to store credit card information, passwords, etc. there, as long as the data were sent via SSL from the client? ...

asp.net+css+jQuery - how does it all work together?

Hi, I would like to understand how can I use jQuery to work with asp.net and css. When I'm writing asp.net code and for example I'm adding to a page DropDownList, I can't see it in the source when I'm opening source of a page in web browser. Instead of dropdownlist I can see select tag. When does the "magic" is done to change asp.net ta...

Sending Zip file to Client via Response - incorrect type being sent...

Hi Guys, OK, I've been pulling my hair out about this for ages. I have a WebService which sends a zip file to the browser. This works; when I test the WebService and 'invoke' the method through it directly, the zip file is downloaded to the browser correctly. The problem arises when I use jQuery to send an AJAX request to the WebServi...

Changing page title dynamically depending on a databinding result (ASP.NET)

Hi, I'm newbie in ASP.NET I have a page to show a thread content, it take the ID of the thread from the query string. depending on the ID, I show the content using the FormView control. how could I then change the page title depending on the databinding result? I've figured out that I can do that before the databinding in the Page_L...

How to protect the connectionstring in web.config?

Hi, I have a website about to go live. I'm wondering what I should be doing about the connectionstring in the web.config. Do I obfuscate it and it so how? Thanks! ...

Current way to setup ASP.NET site with demo data?

I need to set up ASP.NET and connect it to some demo (northwind) data. Considering all the versions of SQL, what is the most current /efficient way to get a database into a project and do a select against it? This question arose once we discovered we could download a MDB and a MDF format of northwind... ...

Returning strongly typed stored procedure results

Currently, if we want to get a list of records from the database, our DAL returns a DataTable to our business layer, which then returns the same DataTable to our calling interface (in this case an asp.vb page). However I don't believe we should be returning a DataTable from the BLL, I always thought it would be better to return a strong...

Pausing/resuming jobs based on job's datamap (Quartz.NET)

How easy would it be to be able to pause and resume jobs, based on whether they have a specific entry in their datamap? Would something like this work) foreach jobdetail if (dataMap.GetBoolean("config1") == true) pause job end if end for Can anyone give me ideas on how to construct the foreach look to loop for ev...

.NET Remoting: How to handle disconnected objects.

First, let me explain a little bit about my setup. My server is setup as a Marshaled singleton object: RemotingServices.Marshal(lsServer, ServerObject.objectUri); In order to have two-way communication from the server to the client, the client activates a ServerObject, then passes in its own ClientObject (which is also a MarshalByRe...

asp.net: using resource expressions with the resources in a separate project.

I'm pretty sure this is something super easy, but how do i access a resource that is in a separate project using the expression syntax? I thought it would be like so: <%$ Resources:SomeNamespace.Resources.Web, PleaseSelectAnImage %> where SomeNamespace.Resources is the project that the resources are located in. i normally just do <%=...

How can I programatically render Google Charts API images into a PDF file?

I'm rendering charts on my website using the Google Charts API and I want to export these into a report for the users, most likely a PDF file. What methods are available to do this programmatically into a PDF file? ...

Unit Testing Web Services - HttpContext

I want to write unit tests for a web service. I create my test project, reference my web project (not service reference, assembly reference), then write some code to test the web services - they work fine. However, there are some services which make sure the user is logged in to the web application by using HttpContext.Current.User.Ident...

server control onclick error

Hi, I am using a datalist inside which I have defined an itemtemplate. I am using asp:LinkButton inside this itemtemplate. I have used an OnClick="methodname" in this linkbutton tag. I have the corresponding mehtodname defined in my code behind, However I keep getting a Java runtime error when the page loads up and when I click on any ...