.net

Raise event from http listener (Async listener handler)

Hello, I have created an simple web server, leveraging .NET HttpListener class. I am using ThreadPool.QueueUserWorkItem() to spawn a thread to listen to incoming requests. Threaded method uses HttpListener.BeginGetContext(callback, listener), and in callback method I resume with HttpListener.EndGetContext() as well as raise an even to no...

Nonblocking webserver on .Net for Comet applications

I am trying to implement a Comet style (e.g. chat) application using IronPython. While I don't need to scale to twitter like dimensions, it is vital that the response time is lightening fast. All the possibilities in Python (Twisted, Tornado, Magnum-Py) do not work with IronPython, often because of epoll support. Is there a default ch...

UI automated testing within SharePoint

Hi All, I'm looking for automated Functional Testing tools that can manipulate SharePoint sites, libraries, and documents thought the web interface. It needs to be extensible enough to handle any custom pieces that are added later. This does not need to be specifically for sharepoint, but it is necessary that it is to work within a ...

Programmatic HTML POST with C#.NET 1.1

Hello, I'm trying to integrate the Moneris Hosted Pay Page into my .net 1.1 app with an iFrame. I've done this many times before, but not with .net 1.1. I can't seem to find a good resource for doing a programmatic HTML Post with 1.1. Any suggestions? Thanks! Edit: Poking around with the suggestions given, I'm realizing that the HttpW...

.NET HttpSessionState Case Insensitivity

.NET's HttpSessionState using an "InProc" store seems to treat session variable key values as case insensitive. For example: session["foo"] = 1; session["Foo"] = 2; Trace.Write(session["foo"].ToString()); // => 2 This behavior appears to be undocumented, so I'm wondering if it is simply a side-effect of the underlying session store me...

handling timeouts with NServiceBus

i know that i can implement a message in NServiceBus with the TimeToBeReceived attribute but does nservicebus has an infrastructure facilities for executing an event-handler when the sent message was not received after the configured time in the TimeToBeReceived attribute? ...

MS Access db over network share

I have a simple web site that needs to connect to an access database over a unc share. The server is a windows 2003 box running IIS 6. The connection is via ODBC. We're receiving an error message that says " ERROR [42000] [Microsoft][ODBC Microsoft Access Driver] Not a valid password. ERROR [IM006] [Microsoft][ODBC Driver Manager] Dri...

Get blend of two colors in .NET

I have two colors in my .NET application that are user defined. I'd like to somehow get the color in between those two colors. It's the color in the middle of the gradient. Is there any way to accomplish this? ...

'Microsoft.Web.Services3.Addressing.Address' cannot be serialized

I'm trying to write a WCF wrapper web service for a WSE3/ASMX web service. [The ugly reason why is that a 3rd party vendor won't support SSL and that is what's needed for BizTalk 2009 WCF adapter to work with WS-Security. So if the vendor doesn't change - I need to call a local WCF web service...] I followed this article to get the ...

Simulate the page lifecycle to grab the html from the UI layer

I'm working with a rather large .net web application. Users want to be able to export reports to PDF. Since the reports are based on aggregation of many layers of data, the best way to get an accurate snapshot is to actually take a snapshot of the UI. I can take the html of the UI and parse that to a PDF file. Since the UI may take up ...

How Reliable is Mono on Linux vs .NET on Windows?

I am trying to decide upon using Mono with C# or Python (Django) for a Linux based Web Site. My concern with C# is that Mono may not be as reliable as .NET. Does anyone have any experience with this? ...

In depth C# Book to read next

I have recently finished reading C# in depth by Jon Skeet and I'm looking for the next book to read, one that extends a little more "in depth" my knowledge of c# and .NET in general and I'd be open to other kind of books. I've read Code Complete and The Mythical Man-Month, and though I find them both to be awesome, I'm looking more for a...

Datasets do not regenerate code behind.

So I was lucky enough to inherit a project where someone decided to use datasets as a model. The problem is that a column has been added to table in the database. Using the dataset desinger I added the column to the table and tryied to run the 'Custom tool' That tool is doing absolutly nothing from what I can tell. So is there a way to m...

Question about the garbage collector in .NET (memory leak)

I guess this is very basic but since I'm learning .NET by myself, I have to ask this question. I'm used to coding in C, where you have to free() everything. In C++/.NET, I have read about the garbage collector. From what I understand, when an instance is no longer used (in the scope of the object), it is freed by the garbage collector. ...

percentage symbol to decimal numbers in .net

Using .net To add a $ symbol for numbers I did Texbox1.Text.Format = "C" How to add % symbol at the end of each integer to represent a string in textbox. ...

OLEVariant to .Net byte[]

I have an OLEVariant disguised as a .Net object that I recieve from a client-side component over the net. I know that the contents are an array of bytes, but I don't know how to convert those contents to a native .Net byte array (byte[]). Any clues on how I can accomplish the conversion? Edit: We answered our own question. To take an Ol...

center MessageBox in parent form

Is there a easy way to center MessageBox in parent form in .net 2.0 ...

Entity Framework with MySQL connector in c#

I have been trying to get the Entity Framework to work in my web application using MySQL. It works fine on my local pc, but doesn't work when I put it on the server. Since the server is a shared server I can install the connector if that is the issue. ...

Need help with MS Access and RichTextBox's

Basically, I am displaying a time table of booked rooms. I have 25 RickTextBox's on my form and I set up this loop to get the data from a database for the bookings: cn = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; Data Source=F:\Project\database.mdb;") cn.Open() ' Looping for two weeks in advance For x = 0 To 13 cmd = New...

How can I have context menu for selected text? &

Hello, 2 problems: In google chrome if you select a word (say problem) and then right click on this selected text, the context menu shows two items 1. Copy 2.Search google for problem 3. Inspect element. The context menu is different from the context menu of that entire window. How can I have this separate context menu for selected t...