asp.net

ASP.NET -> WCF concurrency problem

Hi, I'm developing an Ajax-based application which makes heavy use of server calls to a WCF layer that communicates with a DB. Whenever I effect from the client (an ASP.NET page) many calls within a short span of time to the underlying WCF services, the system hangs and goes into a idle state. How can I handle such concurrency problems?...

How to set Service Reference authorization?

How do you set the authorization for a Service Reference in web.config? I'm writing a password retriever, that sends the users password by e-mail. The e-mail is sent via a SOAP service reference. However, each time I try to declare a reference to the SOAP API the web app returns to the login page - the default action when you request so...

Janus GridEx for ASP.NET Designer Support

Hi all I've been working with Janus GridEx for Web for a few days. I'm afraid I'm unable to open the GridEx designer (Grid context menu in ASP.NET designer), which makes real work fairly impossible or at least unproductive. I get the following error message: Error invoking 'GridEX Designer'. Details:Exception has been thrown by the ...

Sharing a page between Modules in ASP.NET

I am programming an ASP.NET application that has different modules (each one with different styles and master pages), but there are some pages that I need to share between the modules. How do I share a page between two different modules in an ASP.NET application? ...

Move partial page property to View without code behind

I am refactoring a web app built with previous versions of Asp.Net MVC where all the views have 2 codebehind files each. Also if the views are working correctly I want to begin to remove all the code behind files as most of them are empty. There are few of them that have properties like this in the codebehind: public partial class Lis...

Disable controls while Ajax call in Asp.net

Hi, how can i disable a set of controls while waiting for a certain Ajax call to end? I'm aware of the method: Sys.WebForms.PageRequestManager.getInstance().add_beginRequest(onSubmit); but this will be triggered for every updatepanel, not only the one I want to control. Also, an UpdateProgress (maybe with an overlying semitransparen...

How to deliver an Excel spreadsheet over Web Service

Is it possible to deliver an Excel Spreadsheet via an Web Service. I believe not as ASP.NET web services seem only to deal in Serializable elements which the excel binary format isn't (I think). If the Excel is saved in XML format will this work? I have a number of reports that will be emailed, but the request has been put into allow th...

ASP.NET- Sending an e-mail

I am doing a Flight booking system and I want to send an E-Mail to the user which wiil contain the E-Ticket of his travel. The E-Ticket is generated dynamically with the booking ID fetched from the database and the other details from the previous pages like Name of the passenger and all. So how can I send him the dynamically generated E-...

IIS 7 websites share same Application Pool

Hello I have an ASP.NET app. I plan to run several instances of this app on the same server. Each instance has its own domain, like www.app1.com and www.app2.com. Each app instance has its own Admin area, that should be SSL protected. You can't install multiple SSL certs on the same machine and port number, so using https://www.app1.c...

Generating a PDF file of an aspx page without displaying it.

From my code I display an .aspx page with infragistics chart controls in it. I want to send out the same .aspx page as a PDF attachement through email without displaying the .aspx page on the screen. How can this be done. ...

ASP.Net URL rewriting and authentication

I have a web application using the .Net 2.0 framework. The whole website is restricted to authenticated users using Windows authentication. These rules are set in the web.config file the following way : <location path="/"> <system.web> <authorization> <allow roles="CustomerAdministrator, Manager"/> <d...

How do I get ASP.NET controls which visible set to false to collapse the area between controls?

I have some controls on the page which are Invisible on page load. But according to user input that many number of controls should get visible. I have done this. But my page looks little bit dirty because sometimes many controls are invisible. So lot of space is lost. How can I manage that? Is there any particular option in Visu...

ASP.NET and objects

Hi, Let's say I have a class Person, with a string[] nickNames, where Person can have 0 or more nicknames stored. I want to create an asp.net page where a user can go and add/edit/delete nicknames. Question is- how to i persist the Person object between postbacks? I query the DB and create the object then display it on a form, but the...

ASP.NET Base64 string corruption

I am passing an object from one asp.net page to another. I'm encoding the object as a Base64 string and passing it as a POST parameter. However, when the receiving page reads the POST value, if there is a + sign in the Base64 string, it is being replaced with a line break. For example: ...AABDEDS+DFEAED... becomes ...AABDEDS DF...

Why is my fully qualified domain name request url getting converted to an ip address request url by the Cassini web server?

I have a web application which depends on the browser client retaining the FQDN in order for it to work, but what is happening is that in multiple browsers I am seeing the url get converted into an ip address url (containing the correct IP address) which is getting changed by a redirect from the web server. The web server hosting the re...

How to guarantee uniqueness of a referrer who clicks on a link in a remote webpage("Request.UserHostAddress" not working correctly)?

we can use Request.UserHostAddress to catch referrer IP address(for example who clicked a link) but you know by this way we can't ensure about uniqueness of user! this ip don't work correctly in NAT environment because it might be refer to hundreds of machines. i'm looking for a posible way to detect really how many peoples clicked a spe...

Custom server control: specifying event declaratively on ASPX code

Hi, I'm currently working on several custom ASPX server controls. Of course these controls do also expose events. Now one possibility is to register a handler in the code, more specifically in the page where the custom server control resides...like protected void Page_Load(object sender, EventArgs e) { myCustomControl.Click += new ....

Dispose & Finalize for collections of properties?

I'm looking at some vb.net code I just inherited, and cannot fathom why the original developer would do this. Basically, each "Domain" class is a collection of properties. And each one implements IDisposable.Dispose, and overrides Finalize(). There is no base class, so each just extents Object. Dispose sets each private var to Nothin...

If I fill a GridView with anonymous objects, how can i get their properties?

Hi, I have a GridView what I fill through a LINQ expression. Something like this: GridView1.DataSource = from c in customers, o in c.Orders, total = o.Total where total >= 2000 select new {id = c.CustomerID, order = o.OrderID, total = total}; And in its RowCreated method I try to get a property, for example the id, but it has no...

null element id for DataGrid ButtonColumns

I have a bit of JavaScript in one of my pages that avoids the problem of users double-clicking buttons on a form and causing double submissions during asynchronous postbacks: var prm = Sys.WebForms.PageRequestManager.getInstance(); prm.add_initializeRequest(InitializeRequest); prm.add_endRequest(EndRequest); var btn; function...