.net

VB.NET EnvDTE Up-To-Date check before building project

Hi all, how do I check if a project is up-to-date? I'm basically trying to programmatically build each project in a list but only if they have changed. So does anyone know of a way (using EnvDTE maybe) to check if a project changed and therefore needs to compile? Thanks in advance for all the help. ...

How can I make an image grow x % on mouseover event in wpf?

Hi, I have a ListBox containing a set of images in a C# WPF application. When the image enters the image area, that is, on the MouseEnter event, I want the image to grow approx 10 %. This is to notify the user that the mouse pointer is now on a new "clickable" image. Do anyone know how I can accomplish this? Thanx in advance! ...

Removing duplicates from a list with "priority"

Given a collection of records like this: string ID1; string ID2; string Data1; string Data2; // : string DataN Initially Data1..N are null, and can pretty much be ignored for this question. ID1 & ID2 both uniquely identify the record. All records will have an ID2; some will also have an ID1. Given an ID2, there is a (time-consuming...

[c#] That assembly does not allow partially trusted callers

hello, i have developed c# gui application on server computer, and now i want to run it from client. access to aplication is via mapped directory. but, when i run it, next error occure: > See the end of this message for > details on invoking just-in-time > (JIT) debugging instead of this dialog > box. > > ************** Exception T...

Call Ruby or Python API in C# .NET

I have a lot of APIs/Classes that I have developed in Ruby and Python that I would like to use in my .NET apps. Is it possible to instantiate a Ruby or Python Object in C# and call its methods? It seems that libraries like IronPython do the opposite of this. Meaning, they allow Python to utilize .NET objects, but not the reciprocal of t...

How to upload a file over 2MB

There is a limit, i cant upload a file over this limit. When i set the maxRequestLength property over this limit i will get this error: The value for the property 'maxRequestLength' is not valid. The error is: The value must be inside the range 0-2097151. So how could i upload an image that is 5 MB big ? I can't use FTP access. ...

Misuse of Observer Pattern?

I have a Car object which contains a latitude field and a longitude field. I use the observer pattern so that any time either of these fields change in my application, my car object is notified. I now find the need to create several other car objects whose default values I wish to have the same as what is the current latitude and the cu...

Convert from 32-BPP to 8-BPP Indexed (C#)

I need to take a full color JPG Image and remap it's colors to a Indexed palette. The palette will consist of specific colors populated from a database. I need to map each color of the image to it's "closest" value in the index. I am sure there are different algorithms for comparing and calculating the "closest" value. Looking for C#, .N...

Is there a managed API for kernel32.searchpath?

Is there a managed API for kernel32.searchpath? i.e not using a pinvoke. http://www.pinvoke.net/default.aspx/kernel32.searchpath ...

Extendable .Net Document management for under $30K

hi there guys, i am looking to answer one of those problems that sometimes get give to us devs by sales staff trying to get a sale in under budget. We have a client that requires the following: Document management system that support AD authentication (even if the server may be in another location - potentially on a VPN) Ability for ...

Multiple Windows Services under the same process not starting

We are trying to implement a single Windows Services that starts multiple services under the same process. According to code I've seen you do the following: static void Main() { ServiceBase[] ServicesToRun; ServicesToRun = new ServiceBase[] { new Service1(), new Service2() }; ...

Writing a CSV file in .net

I have a requirement to export a dataset as a CSV file. I have spent a while searching for a set of rules to go by and realised there are quite a few rules and exceptions when writing a CSV file. http://knab.ws/blog/index.php?/archives/3-CSV-file-parser-and-writer-in-C-Part-1.html http://bytes.com/topic/c-sharp/answers/236875-problems...

How do I configure .net framework 3.5 in windows 7

I am trying to use the .net configuration tool in windows 7 but can not find it. Does anyone know where to download this tool from or where it is located in windows 7 (prof)? ...

Example of generic DataReader code (.net)

Hi, As my experience with .Net really began as working on existing in-house applications for a company, I feel I've picked up so many bad coding practices without realising it. One that i am desperately trying to move on from is that DataSets are used for everything. (I do get that strongly typed datasets have there place and they certai...

Single instance app with message passing via cmd line?

I have a C# app that is launched via command line. Usually data is pass through the command line such as add (app -a string). I would like only ONE instance of the app to be opened and if more strings are added via command line i would like the single instance to know about it and update itself. I can either put the data into the databas...

How to detect that there are no appdomain proxy objects left

I have a system which loads assemblies into an appdomain and then hands out object proxies to other domains (basically a simple IoC container). We need to achieve very high uptime, and being able to update implementations at runtime helps this a lot. I've go no problems with this in that I can fire up a new appdomain, load new assemblie...

What are good priciples for creating a scalable website?

What are good priciples for creating a scalable website predominantly C#? What design patterns are more common for a C# based website? Links to good books or articles are welcome. ...

COM Interop registration problem

I have a .net assembly which I am exposing to com. the assembly has two public interfaces and one public class. When I build the assembly I get this warning. "(assemblyName.dll) does not contain any types that can be registered for COM Interop." My assembly info includes the following line. [assembly: ComVisible(true)] Most people...

Types of UML diagram - VISIO - ASP.net

Hi All I have below extract from design spec and need to create UML diagrams as .net specifications. No coding is yet started or is there any solution structure yet. What would be best highlevel UML diagrams for such scenarios (by not including any class diagrams). Example Scenario: Display Drop Zone Queue The following steps are ...

Textbox autocomplete Property in .net 2.0

I have a question regarding Textbox autocomplete propert. I have set textbox autocompleteMode to "Suggest" and have set AutoCompleteSource to CustomerSource. I have a AutoCompleteCustomSource collection : "A" "A" "AA" "AAA" When i type "A" in textbox, suggest displays only one "A".Why is this ? And how to display both characters "A" ...