Hello everyone,
I am using VSTS 2008 + C# + .Net 3.5 + IIS 7.0. I have created a new web site and put an html file into the directory. And when I use browse function in IIS manager to browse the html file, I met with the following error, any ideas what is wrong?
BTW: I am very confused about unauthorized error since I run the worker pr...
Hi Geeks,
I have an ASP.NET application which will be running in a web server (Windows Server 2003) for serving my intranet users. Now i would like to monitor the performance of the application: like memory management, unclosed db connection, etc... The ultimate aim is to make the application work optimized. What are the things i should...
Hey guys!
I'm trying to learn c# (so go easy on me!) and as part of a coursework I have been asked to create a game called strikeout.
The game rules are very simple. It is simply a case of knocking one counter into another, with the aim of leaving one counter left on the screen.
I am having trouble simply moving one counter into an...
how to change the window style of a form outside your app?hard question?
i am actually trying to move a form witch is topmost and has no border.
i have the handle(hWnd) of the window.
i can write thousands of lines of code if guaranteed to work.
...
I'm interested to know who uses JScript.Net and for what sort of applications.
Whenever I'm reading MSDN .Net documentation, I always notice the JScript samples but in all the years I've been a C# dev I've never actually known anyone to use it.
What sort of applications are people using this for, and how does it measure, in terms of fle...
I ran the code below expecting flow to be locked on the 2nd time i lock a mutex. After running it twice i realize it can lock many times (assuming in the same thread) without stopping. How do i change this behavior?
using System;
using System.Collections.Generic;
using System.Text;
using System.Threading;
namespace Test
{
class Pr...
I have extended the RichTextBox control to implement much of the missing functionality provided in the native RichEdit class.
I'm running into an issue where if the control is set to wrap to the window or to wrap to printer the horizontal scrollbar appears even though it shouldn't when the control is resized.
Cycling the wordwrap to ...
Hi,
I have the following tables:
create table Users(
Id uniqueidentifier primary key,
InfoId uniqueidentifier not null unique,
Password nvarchar(255) not null
)
Create table UserInfo(
Id uniqueidentifier primary key,
Company nvarchar(255) not null,
ContactPerson nvarchar(255) not null
)
And InfoId is a foreign key referencing ...
I want to generate querys but i wont be executing. Just showing the text query after everything has been escape. I cant figure out how to get the escape value. I searched the object browser for escape hoping to find a function but i didnt. I then had a longshot idea that this (string)new SQLiteParameter("@dummy", text).Value may work but...
I'm creating a simple console application under Windows XP and wondering if there is a way to keep the console window open after the application is run from the Windows run prompt, without putting an endless loop at the end of main(). I want the app to behave like it was run from the run prompt after first typing cmd.
...
I am trying to find out a way to handle unhandled exceptions at server side. I want control over exception handling at Domain Service level so that when any operation is called then I can log the exception and wrap it in some beautiful words to send it to the client.
I found many ways for WCF and classic web services but nothing for RIA...
I'm currently using the Paralle Extensions that are part of Reactive Extensions for .Net(Rx). I believe they are also available through .Net 4 beta releases.
1) Is there any way to determine how many threads are actualyl being utilized. I assume this is related to Environment.ProcessorCount (# of logical cores) but I want to check this....
I have a UserInfo object that is generated on each page_prerender event. This object is generated from the db and contains general info and permissions info. Since this object is always the same for each user - unless the user updates his profile - I'd like to cache it.
Does anyone know how I would do so per user (as each user of the w...
I'm looking for a simple implementation of a parallelized (multi-threaded) sort algorithm in C# that can operate on List<T> or Arrays, and possibly using Parallel Extensions but that part isn't strictly necessary.
Edit: Frank Krueger provides a good answer, however I wish to convert that example to one that doesn't use LINQ. Also note t...
Hi I coded this OneAtRandom() extension method:
public static class GenericIListExtensions
{
public static T OneAtRandom<T>(this IList<T> list)
{
list.ThrowIfNull("list");
if (list.Count == 0)
throw new ArgumentException("OneAtRandom() cannot be called on 'list' with 0 elements");
i...
Does .NET natively support Ahead of Time Compilation? I see that Mono has done this to avoid JITing issues on other platforms (IPhone for example), and was wondering if its possible to build dll's to native code and run those in IIS. For dev, I would really like to be able to flip a switch on VS and IIS, so I only have to wait once for...
Why is it a bad design for an object to refer to another object that refers back to the first one?
...
I was wondering if it makes sense to have objects inherit from a class that implements the interface when dealing with dependency injections
example
public interface IPeople
{
string Name { get; set; }
int Age { get; set; }
string LastName { get; set; }
}
public class CPeople : IPeople
{..implemente...
I've put mail settings in app.config and can successfully pull them into a mailSettingsSectionGroup object. However, I'm not sure how to send a message using these settings.
This is what I have so far:
System.Configuration.Configuration config =
ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None);
MailSettingsS...
Hi, everybody
I have a some computation program. Now, this program is a single-thread, I need to enhance it to do it multi-thread. In general, program computes, dynamic evolution of thermal circuit (Some configured types of different involved elements (Tube, Pump, Active zone, and its connection), for each of it for every time step progr...