.net-3.5

Centralized Credentials Service For Various Apps

We are researching the possibility to build a centralized credentials storage for internal applications. These apps (vb6, vb.net, web apps in asp.net, etc) are using various instances of SQL servers and iSeries. We want to implement a central credentials facility that would act as a security broker. Basically it should work like this: C...

What are some good alternatives to multiple-inheritance in .NET?

I've run into a bit of a problem with my class hierarchy, in a WPF application. It's one of those issues where you have two inheritance trees merging together, and you can't find any logical way to make your inheritance work smoothly without multiple inheritance. I'm wondering if anyone has any bright ideas for getting this kind of syste...

Moved to Windows 7 (64) for development. What about UAC settings? [Windows Application]

For years Windows XP (32 bit)was my development desktop (personal projects). I develop many hobby projects and distribute it as open source and have never worried or bothered about checking it in Vista (I have used Vista only for a week). But none of my users have complained much about my apps in Vista. Now I have moved to Windows 7 64 ...

Scheduled Task Fail error

I am running a C# .NET 3.5 console app on Windows Server 2003 x64, that I want to run every 5 minutes as a scheduled task. The code runs on schedule and correctly (gathering data and writing to a SQL Server 2005 database) when I am logged into the machine. When the task runs with no user interactively logged in, it fails with the error...

Fails to start .NET app, ConfigurationErrorsException

Hi, I've installed a clean XP virtual machine for test purposes, only .NET 3.5 SP1 redistributable is applied. When I try to start our WinForms app, it gives the following exception: System.Configuration.ConfigurationErrorsException: Configuration system failed to initialize ---> System.Configuration.ConfigurationErrorsExcept...

Difference between Activator.CreateInstance() and typeof(T).InvokeMember() with BindingFlags.CreateInstance

Forgive me if this question has already been asked and answered. Given a class of type T, what is the difference between the following? T myObj = Activator.CreateInstance<T>(); T myObj = typeof(T).InvokeMember(null, BindingFlags.CreateInstance, null, null, null); Is one solution preferred over the other? ...

How to get ID of MP3 player?

I would like to recognize what mp3 player i put into USB is what. So if I put my podcast mp3 player I would like my app to recognize it and erase and put my podcasts on. And if not it should do nothing. To do this I need to read some kind of unique identifier of a mp3 player device. Do you know how to do this in C#, .NET 3.5? ...

How to test app for Vista

I've written an app that connects to websites APIs and does some things there. It is a app written in C#, .NET 3.5 on a XP OS. Now I have a problem. Some people reported that this application hangs on Vista, and not on the more new version of Windows (what was the name?) So I do not have Vista and do not have money to buy this system ...

Where should I go to ramp up to complex .NET 3.5 and WPF applications coming from a .NET 2.0/WinForms background?

Title says it all really. I come from a C#/.NET 2.0 and WinForms background, but I'd really like to find a great WPF resource or tutorial. ...

Create app.config file dynamically on Application startup

How can I create the app.config file programatically on Application startup (if the file doesnot exist)? ...

Is it a bad practice to reference System.Windows.Form in your Unit Test project?

I have a class that I want to test the DialogResult value for. To get that type I need to add a reference to System.Windows.Forms. Is it bad practice to have this included in a test project? ...

Is this JSON correct and if so how to iterate through each object in JavaScript - Asp .Net 3.5

I have created a C# web service that retrieves a data table with 2 columns, that data table is serialized using JavaScriptSerializer. Using FireBug, I see the following JSON which appears correct to me: "{"d":"[{\"Text\":\"4 blah blah2\",\"Value\":\"16\"},{\"Text\":\"asdf\",\"Value\":\"15\"},{\"Text\":\"qwerty\",\"Value\":\"13\"}]"}" ...

WCF client config: centralized endpoint address

Hi, i've a WCF client wicht refers to multiple services hosted in the same machine. like this example <client> <endpoint address="net.tcp://localhost:8731/TrackingService" binding="netTcpBinding" ... </endpoint> <endpoint address="net.tcp://localhost:8731/CommonService" binding="netTcpBinding"... </endpoint> </client> is ...

How to convert random XML into RSS with linq

I have this XML data dump <?xml version="1.0" encoding="UTF-8"?> <File> <Row> <Column Name="Job Code"></Column> <Column Name="# of Positions"></Column> <Column Name="Justification (Text Only)"/> <Column Name="Reason"></Column> <Column Name="Job Title"></Column> <Column Name="Purpose...

Why is my Windows Service not showing in Services after it installs?

I've created a Setup Project to create an installer for my Windows service I am writing. The Windows service has a ProjectInstaller and the ProjectIsntaller has a ServiceInstaller and ServiceProcessInstaller. When I compile and install the MSI created for the service, the files copy to the correct directory but the actually service doe...

Is it possible to "cancel" a dependency-property assignment from an IValueConverter, if there was no change in the property value?

I have a data-binding set on a dependency property of a class. I also have an IValueConverter to handle the calculation of this value based on other elements. The context of my question is inside the IValueConverter.Convert method. #1 If the calculated return value is equal to the current property value, can I tell the framework not t...

bidirectional named pipe question

I have 2 apps that I want to make communicate via named pipes on .NET 3.5. Its a request/response paradigm, with the data transmitted as XML to make my life easier. There is a listener app, and an app that posts requests to the pipe. I'm trying to use a bidirectional pipe to do this. The problem i have is that the call to StreamReade...

Get Calling function name from Called function in C#

Possible Duplicate: How can I find the method that called the current method? How can I get the calling function name from the called function in c#? ...

User cannot Install Click once application

I have a relatively simple support application which I have chosen to deploy to our support staff via click once. I assume it's still called Click-Once. I'm using the publish tab of the project's properties in VS2008. Several users have managed to click through to the url, download and run the application. One specific user cannot. H...

.net reflection finding object from interface memberinfo object

Okay, I have a an interface, lets call it public interface bar { string Foo; } also have a class that implements the interface public fooBar : bar { public string Foo {get; set;} } I then have a property hanging off another object that contains a list of interface "bar" that contain different implementations, like so, pu...