.net

Scrolling WebBrowser programatically sometimes doesn't work

I'm using the System.Windows.Forms.WebBrowser control and I need to do programaticaly scrolling. For example, I use this code to scroll down: WebBrowser.Document.Body.ScrollTop += WebBrowser.Height The problem is that in some sites it works but in others it doesn't http://news.google.com (works good) http://stackoverflow.com/ (doesn...

mouse followed drawing in C#

hey, I want to to make a shared drawing board in C#. This means that two people connected via a TCP connection can draw on this board. The idea (for now) is that people can click on the screen and draw. What do you think is the best method for this? It's easy enough to draw a dot when the user clicks on a certain spot, but it gets a lit...

httpwebrequest Cookiecontainer

Hello, How do I handle cookies with paths other than "/". An HttpWebRequest object returns these headers: HTTP/1.1 302 Moved Temporarily Transfer-Encoding: chunked Date: Wed, 10 Jun 2009 13:22:53 GMT Content-Type: text/html; charset=UTF-8 Expires: Wed, 10 Jun 2009 13:22:53 GMT Cache-Control: no-cache, must-revalidate, max-age=0 Server...

What's the best way to implement custom attributes in dotnet/.NET?

I don't really understand attributes. I've read all kinds of books & posts on them, but I just don't get it. Since I don't understand them, I also don't understand how to effectively use them. 1) Can you give me a good definition of what an attribute is & what it's used for? 2) Can you give me a good code example in C# of how to make ...

Cucumber alternative for .NET

Quick one, has anyone come across a library similar to Ruby's cucumber (a human readable DSL for defining use case stories that can be tested against) in the .NET sphere? ...

C# ListView - control

How can I select an entire row of a ListView control in Details view-mode? Or alternatively, how can I select a row in a ListView by clicking on any subItem? ...

Laboratory Information System interface to Remisol 2000 Data Manager

Hi, I need to develop an interface between a Laboratory Information System (LIS), developed in .NET, and the Remisol 2000 Data Manager , which is a API for lab instrumentation systems made by Beckman Coulter Inc. The idea is to fetch the test results programatically into the LIS. Are there any resources on the web that can give me a st...

synchronized execution across machines

I have a C# ASP.NET web app running on two machines behind a load balancer. We use sticky sessions so we do not have a shared out of process session state. Our code makes use of a SQL database and we process credit cards. We need to synchronize execution of a block of code that checks conditions in the database and also attempts to ch...

Store XML Local Until Network Connection Resumes

New to .NET, any point in the right direction would be a huge help. Trying to write a program to accept data input in a manufacturing environment and store it directly into a SQL database. A problem I can foresee is if the Wireless Network Connection is interrupted (or temporary out of range) Where would I research, or how would I g...

Regular Expression sub-expressions

I'm working on a regular expression (in .Net) that needs to mark subexpressions. Sample inputs are: EFBCFEyy EFBQFEyyQ EFBQFE yy Q EFBMFEyyMM EFByyMFEMM What I need is to pull out all of the sub-expressions delineated by "yy" or "MM". The expression I've got so far works for the first few strings, but not the final pair. There may be...

How to give access restriction to DLL's in .net

Hi , I have a 3 layer application(UI,Business Layer,Data Layer).My requirement is my datalayer should be only accessible by business layer,and the business layer should be only accessible by UI layer. That means even if i add a reference of adtalayer in the UI layer,it should not be able to access the methods in Datalayer. I should be...

Sending Automated SMS Messages

First, we use .net & sql server. I have a client that is interested in a system that will send SMS messages at scheduled times. I have never done anything like this except for sending an sms through an email gateway, like [email protected]. But, I don't think that is an option for this as, our database will store the phone number an...

Is My ASP.NET Session Too Big?

In our .NET web app, we have a session object for each logged in user that is around 5-7 kilobytes. The session stores a Dictionary object that contains a couple of classes and the user's authentication token. Does this session size seem too big? I really don't know what a good size is or what good practices I should follow for sessions....

How to specify a WCF known type in config that is generic?

I have a type, let's call it Data<TKey>. I also have a WCF service contract that accepts a type (lets call it Wrapper) with a property of type Object (for reasons I won't go into, this isn't optional). [DataContract] public class Data<TKey> { ... } [DataContract] public class Wrapper { [DataMember] public object DataItem { get...

Post-build Event error visual studio 2008

Hi, what's wrong with this post-build event? I want to copy the entire contents of a resources folder over to the target directory while maintaining the but it keeps exiting with code 1: copy $(SolutionDir)$(ProjectName)\Resources*.* $(TargetDir)Resources\ Thanks in advance! ...

LINQ vs regular enumeration

When you have some enumeration methods in some of your types (i.e. a custom collection), is it better to use LINQ syntax or just old school enumeration (for/foreach)? Using .NET 3.5 is a given. I am asking this for maximum performance and readability. The application is also designed to be parallel. Which one would you favor? ...

How to mirror a half 3D mesh object ?

Hi All, Let assume that we have a half 3D mesh object and want to mirror it, in C# 2008 Express. That is, we want to have its simetrical part according to the center line of the object. Could you help me to do that. Thanks in advance. ...

LINQ to SQL and Null strings, how do I use Contains?

Hi all, Here is the query from a in this._addresses where a.Street.Contains(street) || a.StreetAdditional.Contains(streetAdditional) select a).ToList<Address>() if both properties in the where clause have values this works fine, but if for example, a.StreetAdditional is null (Most of the times), I will get a null reference exception....

Socket Recommendations

Hi, I'm doing a little research in developing a simple socket server that will run as a windows service. I'm going to write this in C#, but I've been made aware that .Net sockets are slllooooowwwww. For the initial roll out using the .Net Networking classes will be fine, but I'm wondering if anyone has experience with a high performanc...

Free and Open Source BPMS for .NET

Have there been any free and open source BPMS released which run under .NET which are comparable (if not fuller) in functionality and maturity as JBPM? ...