asp.net

Instruct the browser not to wait for more content while processing continues

How do I instruct the browser not to expect any more content to be coming down the line? Kinda like the server saying “I got what I need, you don’t need to wait while I finish the processing of the page”. I have a server-side task, which is initiated when a certain page is hit. The task may be time-consuming, but the rendered HTML will ...

What do I do with my exceptions in asp.net?

I'm working on an ASP.NET MVC application and just getting to error handling. Help me solve the issue of getting the error message back to the user. I have a controller: [AcceptVerbs(HttpVerbs.Get)] public ActionResult Show(string callNumber) { ServiceCallService sc = new ServiceCallService(); return View...

What is the dataKeyName for a gridview bound to a string array?

Can anyone give me a short snippet that, given a GridView that was originally bound to a simple string array, and given a GridViewRow row, will return the value that was bound to the row? ...

Handling Request Validation 'silently'

I'm trying to override the onError event handler of a web form to allow "A potentially dangerous Request.Form value was detected from the client" type errors to be handled within the form rather than ending up at the application level error handler. I found some sample code like this : protected override void OnError(EventArgs e) { ...

Orkut's URL Writing Method

I have a doubt about orkut's new URL Writing method. Earlier the home page was like http://www.orkut.com/Home.aspx Now its changed to http://www.orkut.co.in/Main#Home.aspx Whats the significance of "#" ? Why is it there and why have they used it? Is not "#" used to navigate to a particular section of Page using name="blah" in the ...

What happens if you fire a background thread to execute right before ASP.NET completes its page processing?

Hi everyone, what would happen if I spin off a thread to execute a long-running process right before the ASP.NET page lifecycle completes? Will the ASP.NET runtime kill the thread? Can this lead to undefined behaviour? Here's a sample of the code, which spins the background thread in the Page_Load event. Is this a safe thing to do? pro...

Joining Binary files that have been split via download

Hi I am trying to join a number of binary files that were split during download. The requirement stemmed from the project http://asproxy.sourceforge.net/. In this project author allows you to download files by providing a url. The problem comes through where my server does not have enough memory to keep a file that is larger than 20 me...

Can I use a single BIN folder for several ASP.NET applications?

Keep in mind that I don't want to use the GAC since my assemblies are frequently updated and I do not wish to register them after each update. ...

ASP.NET Deleting a directory results in application restart.

Hi, I have an application with 2 directories (books and export). If we create a book or a page of a book in the application a directory is added with the id of the page (this is for uploading resources). If we delete a page, the page (and it's directory) is removed from the database and the filesystem. However this resulted in a session...

How to configure WCF in a separate dll project

Aloha I'm developing a web application (ASP.NET 3.5) that will consume a number of web services. I have created a separate dll-project for each web service: these projects contains the service reference and client code. However, the calling website MUST have the <system.serviceModel> information (the <bindings> and <client> nodes) in ...

ABAP RFC Debugging

Hello! I'm a ASP.NET and ABAP developer. For years, I used RFC's to communicate with ASP.NET using SAP .NET Connector. During the integrated tests, sometimes we need to debug a RFC that has been called from ASP.ENT, just because the bug we are facing does not happens at SE37. So, everytime I needed to debug the RFC, I just inserted: ...

how to Intregate Yahoo API Search in web-Application using Asp.net

hello everyone i want to intregate yahoo search api in my web application in asp.net with c#. i don't know how to call yahoo api. pls tell me with code. ...

Role security with active directory

Hello, I have to ensure the security of a asp.net website at work. they ask me to do a role based security with the active directory of my work so i could do a sitemap and give the right acces at the right personne. wich class of the framework should i use? make generic identity? ...

ASMX page returning old Web Methods

I must be dumb (and i m sure i am making mistake but cant figure out at the moment) Actually i deployed ASMX page containing reference to a Class Library which contains few web methods. It exposes those methods when i browse the site. But some how it is not showing me any further methods which i have added in it. The DLL is strong name ...

Common method in datalayer for SQL/Oracle DB's..

In .NET if my DB is SQL Server then in datalayer we have statements SQLConnection, SQLCommand, SQLDataReader... Suppose we change the DB to oracle then we need to change the statements to OracleConnection, OracleCommand, OracleDataReader and so on everywhere. Instead how can I have some generic method so that at runtime based on DB typ...

Problem Converting byte[] to Bitmap c#

Hi, I have an urgent problem, i'm trying to convert a byte array to a bitmap but it always shows me: System.ArgumentException: Parameter is not valid. my code is as follow: Im passing the bytes through a webservice with: string DecodedString = string.Empty; DecodedString = System.Text.Encoding.GetEncoding(1251).GetString(bytes); s...

ASP.NET SessionID In URL

I'm taking over a ASP.NET web application that passes the session id in the URL string. There is an odd bug that I have to assume has something to do with a server configuration but I'm at a loss. Page A has a URL string that looks pretty much like this: http://whateverqa.com/NTapsWeb/(S(yn5cby55lgzstcen0ng2b4iq))/List_Forms.aspx?wid...

Strange communication error in Win2008

I have a windows service that hosts the main WCF service. The clients for this service are both hosted in IIS 7, the first one is an IIS hosted WCF service and the second is a standard Asp.Net application. Both of the IIS hosted clients communicate with the windows service over named pipes. The IIS hosted WCF service can communicate w...

How to design a public API in ASP.Net?

I'm currently developing a web application in ASP.Net with SQL Server and I would like to have some sort of public API so that my users can get their data and manipulate it at their own will. I've never done something like this, can you recomend some guidelines for me to follow? ...

Best practice to share DAL between ASP.NET and Silverlight 2

I have an ASP.NET 3.5 e-commerce site that has an admin section. I want to swap out the ASP.NET-based admin section and rewrite it in Silverlight 2. Silverlight requires async calls, so I can't just call my existing DAL from a new SL2 app. What is the best practice for doing something like this? Should I create a WCF service and call...