.net

Financial Market Developer Dilemma

In the no-so-distant future I plan to work for a corporation in the financial sector as a software developer. I have a few of options as right now: Learn and focus on .NET since (presumably) it is widely used in the financial industry. Study the programming concepts, learn algorithms, learn a little bit of C/C++, C#, JAVA, Objective-C...

Why would you need to run regasm and caspol on a .net component more than once?

Why would you need to run regasm and caspol on a .NET component more than once? I have a COM client that uses a .NET component residing on another machine. Consequently I need to run regasm and caspol on this .NET component. What could cause there to be the need to do this again on the same machine to the same component? Is the effec...

Decoding Decimal64 data

I'm looking for a simple way to decode data stored in the Decimal64 format (described here: http://en.wikipedia.org/wiki/Decimal64_floating-point_format) using C#. Any thoughts? ...

why assign null value or another default value firstly?

i try to generate some codes. i face to face delegates. Everythings is ok.(Look below) But appearing a warning: you shold assing value why? but second code below is ok. namespace Delegates { class Program { static void Main(string[] args) { HesapMak hesapla = new HesapMak(); hesapla.Calculator = ...

Serialize nested interface

Hello, how can i serialize this class? public class MyClass { IInterface MyProperty { get; set;} } ...

JavaScript/JSON Serializer

I see that a JSON serializer is present in the System.Web.Script.Serialization namespace, and is shipped in the System.Web.Extensions.dll assembly. Is this assembly distributed with the .NET framework v4.0 redistributable? Is it also guaranteed to be present on a user's machine if any edition of Visual Studio 2010 is installed? Adde...

.NET compact framework - barcode scanner

Hello I have Motorola MC55 with Windows Mobile 6.5 on-board. This nice palm contains also an embedded bar-code scanner. My question is - Will I need anything special in .NET CF in order to use the bar-code scanner? I would expect that the bar-code are read as normal strings and delivered as keyboard events? Is any special .NET CF libra...

Adding reference to Office library failing: type or namespace name Word not found

I'm trying to use the sample code here: I went to "Add Reference" dialog and added "Microsoft Word 12 library", but it doesn't appear in the Solution Explorer. I also added: using Microsoft.Office; I get the following error message when trying to declare a "Word" object. Error 1: The type or namespace name 'Word' could not be f...

Run Dotfuscator as a post build event

I'm using Dotfuscator in Visual Studio 2010. I want to run Dotfuscator as a post build event so every time I build a project Dotfuscator will run on the output DLL using a configuration I've created and I'll get a new Dotfuscated DLL without having to manually open Dotfuscator. After it will be obfuscated, I'll resign it (using sn.exe)...

WPF Databinding INofitfyPropertyChanged problem with nested types

We have a datasource that has a multiple nested classes. In general, there's a datastore which represetns a calendar year. It contains a collection of months, and each month contains a collection of days. Now, the problem is that we have a dozen or so properties that calculate total horus and what not for a month, half a year, and the en...

coordination transform issue in Silverlight

Hello everyone, I am using Silverlight 3.0 + .Net 3.5 + VSTS 2008 + C# to develop silverlight application based on ASP.Net. I am very confused about what are the function of "TranslateTransform" and "RenderTransformOrigin" in the following code snippet? BTW: I roughly understand RenderTransformOrigin means move an UI element in x-axis ...

WPF Data Binding won't work

Hey, I have got an UserControll with a DependencyProperty called "Risikobewertung" whitch has the own Datatype "RisikoBewertung"(Datatype created by LINQ). So in my Controll I try to bind the Fields of RisikoBewertung to the TextBoxes on the Controll, but It won't work. I hope you can help me, and tell me why ;) Code: UserControl.xaml...

How can I specify processor affinity?

I have an application that's having some trouble handling multi-processor systems. It's not an app that I have a particular affection for modifying and would like to avoid it if possible. However, I'm not above modifying the code if I have to. The application is written in VBA (and hence my inclination to avoid touching it). We've no...

Is there a .net 4.0 provider for IBM DB2?

I can do any .Net development using v2 of the CLR (.net 2, 3, 3.5) but when I try to use .Net 4.0 then I get an error saying that the version of IBM.Data.DB2 is too old / out of date (it's compiled for CLR v2). Where would I find a .Net 4 version of IBM.Data.DB2? ...

Can .NET AppDomains do this?

I've spent hours reading up about AppDomains, but I'm not sure they work quite like I'm hoping. If I have two classes, generic Foo<T> in AppDomain #1, Bar in AppDomain #2: App Domain #1 is the application. App Domain #2 is something like a plugin, and can be loaded and unloaded dynamically. AppDomain #2 wants to create Foo<Bar> and us...

How do I dynamically load raw assemblies that contains unmanaged code?(bypassing 'Unverifiable code failed policy check' exception)

I'm going to give an example of using System.Data.SQLite.DLL which is a mixed assembly with unmanaged code: If I execute this : var assembly= Assembly.LoadFrom("System.Data.SQLite.DLL") No exceptions are thrown, but if I do this : var rawAssembly = File.ReadAllBytes("System.Data.SQLite.DLL"); var assembly = Assembly.Load(rawA...

Paging in ActiveRecord

Does CastleProject ActiveRecord support paging? I need to load only data which is now seen on the screen. If I use [HasMany], it will be loaded as a whole either immediately or at the first call (if lazy attribute is true). However I only need something like first 100 records (then maybe 100 next records). Another question is how to loa...

Extending the .NET type system so the compiler enforces semantic meaning of primitive values in certain cases

I'm working developing a system right now that deals with lots of conversions between semantically different values that have the same primitive .NET type (double/string/int). This means that it's possible to get confused about which 'semantic type' you are using, either by not converting or converting too many times. Ideally I'd like ...

WPF on a iX104 Tablet PC - efficient enough?

Hi, I'm considering to use WPF for an application running on an iX104 (unfortunately I don't have one of those yet). Do you guys think that this combination would be efficient enough? Or is WPF just to slow for such a machine, so better stick with WinForms? Relevant specs of the iX104: Intel Pentium U2500 CoreDuo 2x 1.2 GHz 1 GB RAM, ...

Prevent(manually entered) Code Removal in Resources.Designer

I've added a small function in the Resources.Designer.cs and it working great, the problem is that when I add or remove something from the Resources.resx this function always get removed, is there any indicator I could put or anyway to bypass this? Thank you! It is a really simple method used as an indexer. internal static string K...