.net

How can I make a DateTimePicker display an empty string?

I would like to be able to display a DateTimePicker that has a default value of nothing, i.e. no date. For example, I have a start date dtTaskStart and an end date dtTaskEnd for a task, but the end date is not known, and not populated initially. I have specified a custom format of yyyy-MM-dd for both controls. Setting the value to nul...

How to get Uri.EscapeDataString to comply with RFC 3986

The Uri class defaults to RFC 2396. For OpenID and OAuth, I need Uri escaping consistent with RFC 3986. From the System.Uri class documentation: By default, any reserved characters in the URI are escaped in accordance with RFC 2396. This behavior changes if International Resource Identifiers or International Domain Name parsing i...

string.Replace not behaving as expected

Can someone explain why I get different results from these two statements? I thought that reassigning the value to the same variable would result in the value I get in the above example. What am I missing here? _body.Replace("##" + _variableName + "##", templateVariables[_variableName]) Hello pitty ##LastName##, _body = _body.Rep...

Using WCF with Excel 2003?

Hi there, Does anyone know or can find some sample code showing how to call a WCF service using Excel 2003? ...

DOT NET code to convert HTML to text

Hello All, I'm creating a little algo to fetch text from web sites.. then find answers (will post the script once completed). To do that, I need to convert all HTML code within and into plain readable english text. I've manually removed all html tags, but some css entries are hard to get rid of. Any simple ideas on how to convert h...

Programmatically Retrieving MS SQL View's columns including Alias in .net/C#?

How to retrieve the columns (including alias) name, tables involved in a 'View' in C#? ...

using MySQL Connector/Net with the help of NHibernate inside a commercial product

Is the combined use of NHibernate (LGPL) and MySQL Connector/Net (GPL) inside a commercial (non-GPL) product legal if the commercial product only directly talks to NHibernate and NHibernate is talking to the MySQL Connector/Net? (And if so what part of the license(s) is telling me that it is?) Here is what I think to know so far (correc...

Resize a shape object

In this question I talk about a star-shape: http://stackoverflow.com/questions/839843/reuse-path-object-in-xaml) <Path x:Name="NiceStar" StrokeThickness="10" Stroke="#ff000000" StrokeMiterLimit="1" Data="F1 M 126.578613,11.297852 L 162.373535,83.825684 L 242.412598,95.456055 L 184.495605,151.911133 L 198.167480,231.626953 L 126.578613,1...

Reset Scale in a GDI+ Transformation Matrix

I'm writing a function to draw UI handles (rotate, resize and so on) in my client area in a Windows Forms application. The function is called when an object is selected. The caller sends me a Graphics object properly rotated, scaled and translated to fit into the larger scheme of things (the selected object has its own rotation/translat...

Data Access Layer in .net

Hi, I am designing an application where I want to reduce the burden on the developers for future for development. In this I have list of classes e.g-"User,Account,Permission and etc" now these classes are associated to the table in the database with the name of the class same as data table. I want my business layer to be robust so that i...

Importing a python module to .net - "No module named signal"

I'm trying to import a Python module in a C# code like this: var setup = Python.CreateRuntimeSetup(null); var runtime = new ScriptRuntime(setup); var engine = Python.GetEngine(runtime); var module = engine.ImportModule("mymodule"); but I get an error saying "No module named signal", does this mean that ...

What is the difference between SqlCommand.CommandTimeout and SqlConnection.ConnectionTimeout?

Is there any difference between SqlCommand.CommandTimeout and SqlConnection.ConnectionTimeout in .NET? ...

Integration of Asp.Net website and Workflow Foundation

I'm building a web application which has some processing of user requests involved. A user submits request for something, it goes through few steps and channels and its status changes through some predefined statuses, in the organization before being approved or rejected. During processing the ball may roll back to the user's court for s...

Import data from asmx webservice to MS-Office in strongly typed manner?

(Answers that include advice to use xsd, please describe how to get the xsd from the wsdl!) I've written up a webservices tier for my office's line of business application. However, unless I can figure out how to get the results into MS-Access or Excel without all the column names turning to strings, then my API is all dressed up with n...

.NET WPF Remember window size between sessions

Hello, Basically when user resizes my application's window I want application to be same size when application is re-opened again. At first I though of handling SizeChanged event and save Height and Width, but I think there must be easier solution. Pretty simple problem, but I can not find easy solution to it. ...

Find page address in .NET

Does anyone know how I might programmatically discover the current page's full address. We share our codebase accross several clients in subdomains and I am trying to discover which client is viewing the page in order to load appropriate CSS, eg. red.website.com; blue.website.com; (I am looking to grab the red or blue, in my code). Man...

Visual Studio Setup and Deployment build fails with no errors

I have a setup and deployment project that, on our build server, reports the following in the summary: ========== Rebuild All: 25 succeeded, 2 failed, 0 skipped ========== I don't know what the two are that failed, though I believe one of them is the vdproj project because if I run the build without the installer there are no error...

Blanket Alpha Component in GDI+

Is there a way I can set an Alpha value that affects all subsequent GDI/GDI+ calls? in other words, I am looking to set the transparency for all calls on a Graphics object. (I'm looking for something similar to how the *Transform functions affect the Graphics object they are called on) ...

Where can I find good Immediacy CMS technical documentation?

I'm currently getting to grips with the Immediacy CMS platform and I'm finding that techincal material / documentation for it is pretty poor. I've looked through the documentation on the immediacy site but there only seems to be simple plugin configuration documents rather than a decent API / technical introduction. Ideally I'd prefer t...

Difference Between Application Exception and System Exception.

I want to know the difference Between Application Exception and System Exception. Can anyone explain ...