.net-3.5

Embeding a chat in an existing desktop user-enabled .NET application?

Hello. I am builing a win application that has user access control against a sql db, all the data is stored in this db as well. This project is to be installed in one site on 30-40 machines (I mean to say that it's not web, it's all in one place, maximum call it intranet). I want that while the program is logged on, the logged-in user ...

.NET 3.5 RSS and XML Stylesheets

Can you add an XML-stylesheet to the RSS feed generated through the new System.ServiceModel.Syndication namespace? ...

System.IO.Pipes on Windows 2000

Is there any way to get .NET 3.5 working on Windows 2000? Specifically, the only part I need is the System.Core.dll to use the System.IO.Pipes namespace. Hackish workaround methods are fine, if necessary. Thanks! ...

What is new in .Net framework 3.5?

I try to keep it very simple. All I have seen in .Net 3.5fx is language upgrades i.e C# 3.0, VB.Net 9, still core CLR is based 2.0fx. I really did not find any new features (LINQ is again language feature). Is .Net framewors 3.5 just like fixed version of .Net 3.0 framework ? I really failed to find some thing new in core framework :( ...

How do I iterate through a list in my View?

In my view I'm returning some results from a webservice and storing them in a session variable. Here's the Session Storage Method: //AreaSummary[] is a reference to the webservice reference gubbins public AreaSummary[] Results { get { if (this.Results != null) { ...

linq-to-sql How can I get a few rows that don't match my existing rows?

I have a few rows of data pulled into business objects via linq-to-sql from large tables. Now I want to get a few rows that don't match to test my comparison functions. Using what I thought would work I get a NotSupportedException: Local sequence cannot be used in LINQ to SQL implementation of query operators except the Contains() ope...

Why Would a Dependency-Property Implementation Crash My Application When I Provide a Default Value?

Why would a dependency-property implementation crash my application when I provide a default value? This segment of code is in the class declaration for my UserControl object. Everything works fine - it compiles and runs perfectly. public static System.Windows.DependencyProperty DepProp = System.Windows.DependencyProperty.Regis...

How to get top 3 elements in int array using LINQ?

I think its easy LINQ question, but i am very new to LINQ I have this array: int[] array = new int[7] { 1, 3, 5, 2, 8, 6, 4 }; and i wrote this code to get top 3 elements in this array: var topThree = (from i in array orderby i descending select i).Take(3); and when i check whats inside the topThree i find: {System.Linq.Enumerabl...

Is it possible to create VB.net module-like in C# on .Net 3.5?

I need to use some feature of VB.net that is Module for my Asp.net MVC project. But I found that C# can't handle Module like VB.net does. Please look at the following code. VB.Net - Globalization Project Public Module [Module Name] Public Const WebsiteName As String = "[My Website Name]" End Module VB.Net - Asp.net MVC View Page ...

Launch a WPF window

Hi, Im uprading a .Net 2.0 project to 3.5. In the current project The code "System.Windows.Forms.Application.Run(winForm);" creates the initial windows form I am wondering if anyhow can tell me whats the equivalent to call a WPF window. Any help or advice really apprecaited. Steve ...

Rendering HTML Content within Silverlight application

In one of our application it is required to display bullet list in one of the Silverlight 2.0 container. We have decided to use HTML markup text for the same. While there are number of options available on Google like overlaying HTML div container etc., I would like to know what is the most workable way of doing this. ...

How do disable .net framework 3.5 on IIS 6.

Hi, Is there are some ability to disable .net 3.5 on IIS 6 for asp.net site? I just have an application (.net 2.0) that has not working on server with .net 3.5, is throw : Attempted to read or write protected memory. This is often an indication that other memory is corrupt. Description: An unhandled exception occurred dur...

How Can I Nest Custom XAML Elements?

<Window x:Class="WpfApplication1.Window1" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="clr-namespace:WpfApplication1" Title="Window1"> <Grid> <local:ElementType x:Name="FirstElementName"> <local:ElementType x:N...

Collections Question (.NET 3.5, C#)

I'm stuck and I need help. Anyway I have Visual Studio 2008 console program that needs to log a Date, String, Boolean, and an integer for each round of a game. Say the user plays 10 rounds I would have 10 of each. I want to save those records in a data structure (collection i believe) and then after the game is finished loop through th...

Define optional implementation methods in Interface?

Is it possible to define an Interface with optional implementation methods? For example I have the following interface definition as IDataReader in my core library: public interface IDataReader<T> { void StartRead(T data); void Stop(); } However, in my current implementations, the Stop() method has never been used or implemented. ...

Working with GUIDs and Entity Framework

This question highlights that you can not use server side generated GUIDs with the entity framework. But, I want the generation of the GUID handled at the DAL level of Database API (ie, when an entity's constructor is called, I want the id of the entity to be initialized to a new GUID). My plan is to write a small tool to generate a bu...

What's the Best Way to Catch the Return Key in a PasswordBox? (WPF/XAML)

What's the best way to catch the return key in a PasswordBox? (WPF/XAML) I have a TextBox field and a PasswordBox field on my login form (for username and password entry). I also have a login button which invokes the method that performs the login validation process. I need to make the Return key react the same way in the PasswordB...

Is WCF Username Authentication without Transport Security a security risk?

I am trying to use username message security in WCF. I am trying to find out if using transport credential type of None/Anonymous will pose a definite security risk. My concern is with the initial exchange where binary data is tunneled through using the WS-trust specification (TLS negotiation). Will this attempt to authenticate my user...

How Do I Create a System.Windows.Media.ImageSource From a Byte Array?

How do I create a System.Windows.Media.ImageSource from a byte array? I have a byte array, containing the exact and complete file contents of a TIFF image file. I need to display this on the screen, and I have no idea where to even start. Supposedly, it can be done (according to my boss, our dev team has done it in the past, but no...

Loadtesting vs Threading

i am running iis 7 with .net 3.5 sp1 Can anyone tell me if this is thread safe since it keeps on failing under high load of users private static void addQueryStringParameters(XElement inputs) { NameValueCollection qs = HttpContext.Current.Request.QueryString; XElement queryStringParameters = new XElement("QueryStringParameters...