I'm writing a suite of programs for client PCs --
a Windows Service
a user-space Windows Forms application
I need to be able to publish an updated version of these programs and have the client PCs automatically and transparently (with no user interaction) update themselves. This update will be done over an unreliable 3G connection (E...
I'm getting a "cannot convert from 'int' to 'TValue'" in the following code. How can I fix this? I understand why there is an issue, but I'm wonder the best way around this. Do I need to make a decision to specific type the ReturnValuesDict, and not leave it generic?
public class ReturnValuesDict<TKey, TValue> : CloneableDictionary<T...
I'm trying to link a DataGridView to a data table in a database. I want the DataGridView to update the data table automatically (without having to click "Save" or anything like that). Seems to me that the best way to do this is by handling the RowValidating event. I've been testing this code and this is my problem: let's say I add row #1...
I've got two classes : Unit and User.
a Unit class has a User as leader, and a User can be part of many units.
class Unit
{
User Leader;
public void SetLeader(User leader)
{
this.Leader=leader;
}
}
class User
{
Unit UnitLed;
public void LeadUnit(Unit unit)
{
this.UnitLed=unit;
unit.SetLeader(this...
I am working with a financial application and am looking for the best solution for designing my application.
We have 100's of stored procedures where most/all of our business logic sits. We have WCF web services projects built using Web Service Software Factory (http://servicefactory.codeplex.com/). We have stored procedures built for...
I am looking details on the internal working of asp.net architecture. The topics need to include the following:
Asp.Net Thread/Application Pools
HttpRuntime
HttpApplication - When and how it is
set up
How HttpContext is set up
How objects can passed along the
pipeline using
HttpContext.Current.Items
Why does modification of static
va...
I currently use the code below but its not uncommon for it to throw an "tried to read past the stream" error once the mysql table has reached over 20 thousand entries.
MySqlConnection connection = new MySqlConnection(MyConString);
MySqlCommand command = connection.CreateCommand();
connection.Open();
c...
I am in the process of puting together a custom workflow activity to be used in Microsoft Dynamics CRM 4.0
What I would like to ultimatly acheive is configure a workflow that runs on a schedueled basis i.e run every 2 hours Monday to Friday, rather than on a particular "CRM event" like create, delete status change ect.
Does anyone ha...
Hi All
I have the following method:
/// <summary>
/// Calculates the last trade date.
/// </summary>
/// <param name="tradesDictionary">The trades dictionary.</param>
/// <returns>The last trade date.</returns>
public DateTime CalculateLastTradeDate(ConcurrentDictionary<Guid, TradeRecord> tradesDictionary)
{...
Hello.
I want to check if a field in my XML is of type positive double/decimal. There is a type="xs:positiveInteger" datatype in XSD but no positive double or decimal. Is there a way to achieve this either by defining custom datatype or some other way?
...
I need to download a text file from the internet using C#. The file size can be quite large and the information I need is always within the first 1000 bytes. Is this possible?
...
Hi guys,
I am studying the Code Access Security of .NET 2.0. My current understanding is as below:
The basic mechanism of the CAS is for the CLR to collect certain evidences from the assembly, and then use the evidence and policy to work out a permission set for the assembly's code. And the assembly's code can do nothing beyond that pe...
Hi i want to convert following number to character equivalent but without using any special character. Please Help me. Thank you very much
32545352515049515448524848495270484848484870706670666970
...
The thing is, i really dont want the console window to show up...but the solution should be running.
My point here is, I want to keep the application running in the background, without any window coming up.
...
Here is the problem:
I want to add row indexer (row number or iterator) to each row in log file.
I don't need it to be unique for the whole log file, but only for the "application session" (i. e. each time Win32 application started, we begin our countdown: 1, 2, 3 and so on)
Is where any built-in way (conversionpattern tag syntax) or so...
Been searching for a free reliable CRC library. I've tried rolling my own from the wikipedia algorithms posted but I read from some other sources that I have to take some other things like performance, endian, etc. into account. I don't think I have the time to explore every small thing. Can you recommend any libraries? Also this is i...
Hi,
Sorry for the lame question, but I can't think of a decent way to ask.
When I have certain text selected, Visual Studio highlights certain other related text. If my caret is within "Get", the "Return" and "End Get" lines are highlighted. If I put the caret within the name of an instance, all references to it are highlighted. "If" h...
I'm new to threading and I came accross a custom thread pool implementation example in a blog. I'm pasting just the necessary parts of the code:
Public Class ThreadPool
Private CountLock As New Object
Private _Count As Integer
Public ReadOnly Property ThreadCount() As Integer
Get
SyncLock CountLock
...
Hi
Is there any way to slow down a bit scrolling ? I have a canvas where I put some controls witch I can move. If control reaches current maxWidth of canvas I use method called LineDown to scroll my canvas. However the scrolling is very fast. Is there any way to slow it down a bit ? Maybe I can set some property wich 'tell' scrollviewer ...
Hi All,
I am looking for a web service that accepts a (date, Latitude Degrees, and Longitude Degrees) for a certain City,and returns if Daylight Saving is on for that city in the given date or not.
any help please?
thanks,
...