.net

UUID collision risk using different algorithms

Hi Guys, I have a database where 2 (or maybe 3 or 4) different applications are inserting information. The new information has IDs of the type GUID/UUID, but each application is using a different algorithm to generate the IDs. For example, one is using the NHibernate's "guid.comb", other is using the SQLServer's NEWID(), other might want...

How are updates to the .net framework handled in azure?

If someone is hosting something in Azure and a new KB comes along and requires the .net framework to be updated, how is this handled in Azure? Do they automatically update it for you or give you the option to remain at the older version? I'm more interested in how the versioning is handled, rather than uptime etc. Do they force you to...

MMC Snapin development: 'MMC not responding' - Is there a timeout that can be set for debugging?

So I'm writing a snapin for MMC 3. Quite often I have the debugger attached and I'm stepping through some code. MMC has some kind of a fail safe for misbehaving snapins that automatically unloads them after a timeout. The message is 'This snap-in is not responding'. After that MMC can behave as though your snap-in has been unloaded. fai...

Display Consistent Value of an Item using MVVM and WPF

In my list view control (or any other WPF control that will fit the situation), I would like to have one TextBlock that stays consistent for all items while another TextBlock that changes based on the value in the ObservableCollection. Here is how my code is currently laid out: XAML <ListView ItemsSource="{Binding Path=MyItems,...

ClientRoleProvider and role caching...

Hi, Is it possible to disable to the role caching when using the ClientRoleProvider? The application in question is a console application... I've tried setting 'cacheRolesInCookie' to false (I know it's a console app, but I was running low on ideas!) - but it had no affect. ...

How to map LINQ EntitySet to List property in property setter?

In my model I have these entities: public interface IOrder { string Name {get;set;} List<IProduct> OrderedProducts {get;set;} } public interface IProduct {} In partial class generated by linq-to-sql I map these properties on my entity properties: public partial class Order : IOrder { List<IProduct> OrderedProducts { ...

Prevent painting of .NET form while form is loading?

Is there a way to turn off all visual updates to a .NET form while I am manipulating it? When my program first loads, for example, I set the tab control to the tab that was last open. The user can see the program switching tabs. I have looked into SuspendLayout and ResumeLayout, but either I don't understand what they are doing, or I ...

How can I implement partial serialization?

I've done a lot of serialization development lately, mostly for sending objects over sockets, but I've run into an interesting question: Is it possible to send just a few of the properties from an object through a serializer? My envisioned scenario is this: You have some sort of "state" object for each client, consisting of many propert...

Dowloading a bunch of files asynchronous wait till last finished

I'm trying to download a lot of files after downloading a sql statement must insert a record. I'm using System.Net.Client to download each file synchronously, still it could be done asynchronous. There's no relation or dependency between each download. At first I just tried to use WebClient.DownloadFileAsync but that shutted the progr...

Data Access example using Entity Framework

Does anyone know of or having any good examples of how to use Entity Framework version 2 in the Data Access layer and put an interface on it so the business layer uses the interface rather than knowing about EF? I have found some examples but they are all from 2009 and I'm not sure how they relate to Entity Framework version 2. ...

how can I restrict access to all files in a folder without web.config

Hi I need to restric access to my admin folder to certain people. Those with no authentication ticket should be redirectered to a "not allowed page". How do I identify all pages in my admin folder. I have so far but is it OK? If url.Contains("/admin") Then 'If authentication ticket incorrect then `Response.Redirect("~/notallo...

Automating Internet Explorer w/o ActiveX

I've been automating some tests against a web application using Python and COM. My scripts send clicks to the browser to emulate user behavior and verify the results. I'm trying to find out if moving out of Python to .NET would benefit me much. I'm quite fond of C# as a development language. I've tried some existing tools like WatiN ...

How to serialize a list with multiple data types in C# from xml?

I want to deserialize/serialize the following XML into an object. <Discounts> <Discount Type="Voucher" Key="ABCD00001" Percent="2" /> <Discount Type="Quantity"> <Periods> <Period From="Thu, 31 Dec 2009 23:00:00 GMT" Quantity="1" /> <Period From="Thu, 31 Dec 2009 23:00:00 GMT" Quantity="2" /> ...

i am using .net window application . i need to make my form UI better. how to do that?

i am using .net window application . i need to make my form UI better. how to do that? Is there any predefined shins available?... I am new in this suggest any good idea... ...

domainless kerberos authentication in .NET

I have a client application written in .NET which needs to use a credential cache of the current user to authenticate with a KDC/Directory outside of the domain before continuing execution. In Java there is a library called JAAS that handles this, I am trying to find a good .NET solution for this problem but everything seems to use the ...

How to check if a .net dll is registered ?

Hi all, I have .net solution (one project written in C++ COM others are written in C#) with its libraries. I would like to make some starttest-tool which would test if all C#, C++ libraries are correctlly registered. How I can do that ? How I can ask .NET if some C# or C++ COM library is regitered ? br, Milan. ...

How do you get a flat listing of all files in IsolatedStorage?

I need to get a list of all files in a given IsolatedStorage folder. There are sub folders off the root of the IsolatedStorage and these need to be included in the list. The usual System.IO classes can't be used with IsolatedStorage. ...

Instantiating ReportDocument on Windows 7 machine crashes app

When I try to instantiate a ReportDocument my app crashes - even when wrapped in a try/catch block. This only happens on Windows 7 machines (it might also happen on Vista - I haven't tested it there). Machines running XP don't have a problem at all. try { ReportDocument doc = new ReportDocument(); // This cause the app to crash } ca...

XML Document straight to Stored Proc Mapping in NHibernate

Hello. I'm building a mechanism to take XML data from a queue and call stored procs to save the data from the XML document directly to the database. This seems like something that NHibernate could address, but of course most of the information I find discusses going from objects to database instead of another data format (XML, in this ...

NHibernate Mapping Attributes + Spring

Hello everyone, I'm working on a C# .NET project in which I am mapping my classes to the tables in my database with NHibernate. I need to use NHibernate.Mapping.Attributes and transactions to be configured by Spring. The fact is that Spring 1.3.0 provides a sample project called "Spring.Data.NHibernate.Northwind" that almost provides a...