asp.net

ASP.NET 2 projects to share same files

Well as the title says i have 2 web projects that have the same css files, master page and some resource files, how could i share those? atm i have 2 copies of them... ...

Getting configuration settings from web.config/app.config using class library

Configuration settings in 3.5 is driving me nuts... Help! ;) I have a class library (Named ADI), that needs some configuration settings from the project using it (like connectionstring, filesystem locations etc). I want to define these settings in my Windows Forms/Web Projects App.Config or Web.Config, like other settings. Here is par...

Strongly Typed Stored Procedure Resolution In VB.NET

Currently we generate classes in App_Code by returning all the sprocs from all of our databases and adding the correct parameter types and names to a SqlCommand object and then returning it in one giant class. This means we can do things like MyCmd.cmd.Parameters("MyParam").Value = "whatever" when we want to pass parameters to a SqlComm...

Looking for a good datagrid plug-in for jQuery

I have a requirement to let my users maintain some accounts and accommodations. Each account can 1 to many accommodations and each accommodation is link to only 1 account. I want to be able to let the users edit the account details. On the same page I would like to list the accommodations that are linked to that account and allow the us...

Add Gridview Row AFTER Header

Hi, i'm trying to add a new headerrow to a Gridview. This row should appear below the original headerrow. As far as I know I have two events to choose from: 1.) Gridview_RowDataBound 2.) Gridview_RowCreated Option 1 is not an option as the grid is not binding the data on each postback. Option 2 does not work as expected. I can add th...

Web Service Request

I am building a web site that consumes an external web service. I have added the WSDL of the external service as reference to my site. How do i view the contents of the SOAP envelope that is sent as request when i call the web method in the external service. I get an "XML Parse Exception" when i make the web service call. So i want to s...

Best way to run a tool from ASP.Net page

I have a developer tool that I want to run from an internal site. It scans source code of a project and stores the information in a DB. I want user to be able to go to the site, chose their project, and hit run. I don't want the code to be uploaded to the site because the projects can be large. I want to be able to run my assembly ...

Tilde not resolving in HyperLinkColumn in ASP.NET 2.0

I have an ASP.NET application originally deployed to a .Net 1.1 Framework on Windows 2000 server which i'm now using on a Windows 2008 Server using 2.0.50727. We use the tilde (~) to resolve to an absolute path in many areas of the application and it works for things like asp:hyperlink controls (with run-at server tags), but for our bou...

Determining an 'active' user count of an ASP.NET site

On an ASP.NET site, what are some techniques that could be used to track how many users are logged in to the site at any given point in time? So for example, I could produce a report showing something like this: 10:00am 11:00am 12:00pm 1:00pm 2:00pm .... 3/25 25 32 45 40 37 3/26 31 38 ...

Tips on speeding up a SqlDataSource?

I have two SqlDataSource controls on a page. One loads high level data and the other loads more details based on which high level item you choose. It is a part of a large search that has over 900,000 records and I am looking for ways to speed it up. Whether it is options I can add onto the SqlDataSource, things I can do to the sql que...

Should functionality that's only used once go in a UserControl?

Forgive me if this is a slight mis-use of the system, but I'd like fellow StackOverflow users to settle a debate a colleague and I are having. As a general rule, I prefer each separate item of functionality to be encapsulated within a UserControl even if I know it's only going to be used once. My colleage will eschew creating a UserCon...

URL Rewriter.NET web.config node issue

I'm using URL Rewriter.NET (which I'm liking a lot, by comparison to URL Rewriting.NET - more versitile it seems, don't get me wrong, I like URL Rewriting.NET, but it didn't seem to satisfy the need, given what I know of the tool). I'm trying to use the default-documents node to redefine the default documents for the site. I've tried add...

IIS 7 Rewrite Module rules

Hi I'm setting up some rewrite paths using the IIS 7 rewrite module. I just can't get my head around this one. My friendly URL should look like this: http://localhost/5f3ff4a5-1fb4-4470-904f-bd55e4fabc5d/marketing_performance/dashboard/ And rewrite to this: http://localhost/marketing_performance/dashboard.aspx?account=5f3ff4a5-1fb4-4...

Ensure page is only accessed via SSL

How do I ensure that my users can not physically type in http: to bypass my SSL and ensure that every page is https:? Possibly a redirect on my master page? ...

Asp.Net User Control Event Wireup from aspx file

I've got a user control that has an event that I can subscribe to. This works (ignore syntax): protected void Page_Load(object sender, EventArgs e) { ucControl.Event += new Event(ucControl_Event); } but if I removed this line and put the event wire up in my aspx page, it doesn't work. Ex: <uc1:ucControl id="uc_Control1" runat="ser...

Error while converting grid data to excel

This is the code : TextWriter writer = null; HttpResponse response = new HttpResponse(writer); response.ClearContent(); response.AddHeader("content-disposition", "attachment;filename=" + filename + ".xls"); // response.ContentType = "application/ms-excel"; StringWriter stringWriter = new StringWriter(); HtmlTextWriter htmlTextWriter =...

Finding Active Visual Studio 2008 Connection Strings

Is there a simple way to figure out which connection strings are being used in my web.config. After a lot of LinqToSQL testing, I have a few extra connection strings sitting in my web.config that I'm sure aren't being used, but I'm not exactly sure which ones are/aren't. Any quick ways to single these out. The obvious solution is to p...

Making an entire row clickable in a gridview

I have a gridview and I need to make an event fire when a row is clicked. Is there an existing GridView event I need to bind to to make this happen? ...

Sandboxing Google Custom Search Engine's Styles

I'm trying to incorporate Google CSE into my web site. The search works fine. I'm using Nijhof's ASP.NET Google CSE search control on a page in a site using a Master Page. The problem is Google's style's affecting not just the Google search results on the page but also other elements on the page such as my navigation. Google injects the ...

Master/Detail help needed for ASP.NET newbie. (screenshot too).

I'm just beinning basic data driven ASP.NET webforms design. I have the first part of a form working, but I don't know what to do next. Please see this screenshot of what I have created so far: http://www.twitpic.com/2gnmr I need help knowing what kind of HTML element to use in the master list, and what event/trigger on that element t...