Hi,
Few questions on ORM mappers like nhibernate (for .net/c# environment).
When queries are run against a sqlserver database, does it use parameter sizes internally?
paramaters.Add("@column1", SqlDataType.Int, 4)
Do they all use reflection at runtime? i.e. hand coding is always a tad faster?
does it support temp tables, table variab...
I've got some code that screen scrapes a website (for illustrative purposes only!)
public System.Drawing.Image GetDilbert()
{
var dilbertUrl = new Uri(@"http://dilbert.com");
var request = WebRequest.CreateDefault(dilbertUrl);
string html;
using (var webResponse = request.GetResponse())
using (var receiveStream = webResponse...
In our application (a document management system) we are supposed to be notified of screen changes (or notify the other program of screen changes) in order to keep the two applications looking at the same data, one being the order fulfillment app, the other the document viewer of the original fax. The fulfillment app is written in vb6 a...
I'm currently writing a blog post about the internals of the CLI, and I try to cite where something gets said. Mainly in the Partition III docs.
I'm currently linking to the ECMA page for it, where there are a bunch of pdf- and zip-files, and making section references where they are needed; but I would really like to link directly to t...
Here is what I have:
An external DLL, I have written in C. This DLL links to opencv. I don't want to call OpenCV directly from C# - there are already huge amounts of C code accessing OpenCV which will be used in the DLL. There is an exported function: passbitmap(void *mem, size_t s);
A C# project from which I want to call the DLL.
A Sy...
We have a service using WCF and Impersonation.
A user can log in to the client application with credentials that are part of an Active Directory system.
The users login is impersonated service side.
This works fine when the user who logged in is setup as a Local Admin on their host machine.
But a problem occurs when they are a non-...
I have a function in C# that is being called in F#, passing its parameters in a Microsoft.FSharp.Collections.List<object>.
How am I able to get the items from the F# List in the C# function?
EDIT
I have found a 'functional' style way to loop through them, and can pass them to a function as below to return C# System.Collection.List:
p...
Currently the project I'm working with does not have completely fixed models (due to an external influence) and hence I'd like some flexibility in writing them. Currently they are replicated across three different layers of the application (db, web api and client) and each has similar logic in it (ie. validation).
I was wondering if the...
I notice that Project 2007 has the functions that allow operations that can be undone to be placed in a single stack item, or "undo transaction". For example:
Application.OpenUndoTransaction "Create 6 tasks"
Dim i As Integer
For i = 1 To 6
ActiveProject.Tasks.Add "UndoMe " & i
Next
Application.CloseUndoTransaction
What this means ...
I am about to start a project (.NET) and need to decide between TFS and SVN.
I am more used to SVN(with tortoise client), CVS and VSS. Does TFS have all features available in SVN
Have any of you switched from SVN to TFS and found it worthwhile?
Also it looks like we may need Visual Studio if we need to work with TFS.
[Edit]
Money is n...
I'm using either WebClient or HttpRequest/REsponse to make http calls for images.
I'm not sure how caching specifically works for browsers, but is there a way to enable either WebClient or WebHttpRequest to use the systems "temporary internet files" cache that the browser utilize?
Or, do I have to write my own disk cacher?
...
Hi,
having to work in two parallel environments, developement and production, I want to use the same TableAdapter to connect to different databases (two Oracle databases running on different servers) with the very same structure. How is this possible?
Thanks.
...
In the search for resources to become a better developer, I am looking for good examples of how to structure the code in n-tier applications.
Like... What does the business object do and look, how does it interface with the data access layer etc. How does the UI interface the business layer, and does it interface the DAL directly.
Do ...
I am looking for best practices for creating collections made from anonymous types.
There are several approaches - this one and most answers on this thread assume that the whole anonymous collection can be constructed in one statement.
As anonymous types are usually used to replace classes that are to be used to store temporary (as put...
I have a GridView on my aspx page which displays a collection of objects defined by the following class
public class Item
{
public string ItemName{get; set;}
public object ItemValue{get; set;}
}
Then in my aspx markup I have something like this
<asp:GridView ID="MyTable" runat="server">
<Columns>
<asp:BoundField D...
Hi folks,
some of my MyOpenId persona's have avatars. Is there any way to programmatically request them with dotNetOpenId, like i can request email, etc?
I'm assuming it can't be done because i'm guessing they are not part of the standard openid schema?
...
I guess that this is a really stupid question, knowing that .net-code can be viewed with tools such as Reflector but here it comes.
I have written a library in VS2008 (vb.net) which I am distributing to some people for testing. With the distibution, I am also attaching a sample-project(application) which uses my library. I thought that ...
Start with these simple classes...
Let's say I have a simple set of classes like this:
class Bus
{
Driver busDriver = new Driver();
}
class Driver
{
Shoe[] shoes = { new Shoe(), new Shoe() };
}
class Shoe
{
Shoelace lace = new Shoelace();
}
class Shoelace
{
bool tied = false;
}
A Bus has a Driver, the Driver has t...
Hi,
I would like to be able to iterate through the values of a struct in C# (.Net 2.0). This is to be done at runtime, with no knowledge of the possible values in the struct.
I was thinking along the lines of either using Reflection to add the struct values to a list, or converting the struct to a data structure that implements the ...
Hi folks,
I have some data from a 3rd party that includes some string Language property data. Some sample data retrieved looks like :
"Australia/Melbourne"
When i investigated that what the property data-type was based on, it's a Zone Info (tz database / Olson database). Wtf is that? i googled and here's the info....
ZoneInfo da...