Hi,
I have a simple console application where I have the following setup:
public interface ILogger
{
void Log(string message);
}
class NullLogger : ILogger
{
private readonly string version;
public NullLogger()
{
version = "1.0";
}
public NullLogger(string v)
{
version = v;
}
public void Log(str...
i have filename according to this file name. i need to find file's path.
how to find file's path according to filename? i need to find file's path according to file name sample code:
string path= System.IO.Directory.GetDirectories(@"c:\", "kategori",System.IO.SearchOption.AllDirectories).First();
But i need :
string path= ...
Is it possible to compile some code-behind (.cs) files (eg. all .cs file under a particular folder) into one DLL, and the rest into another DLL?
We have some common codes and pages (aspx + cs files) that we want to use across many websites. We want this to compile into a DLL (eg. Common.dll).
The rest of the files will be website-speci...
How to send Points from below Result class with RIA services ?
I've tried what's written below but it doesn't work.
(Only one Point is sent from Points collection !?)
public class Result
{
[KeyAttribute]
public double Key {get;set;}
[Include]
[AssociationAttribute("AssociationName", "Key", "Key")]
public List<Point>...
Why is it not possible to have implicitly-typed variables at a class level within C# for when these variables are immediately assigned?
ie:
public class TheClass
{
private var aList = new List<string>();
}
Is it just something that hasn't been implemented or is there a conceptual/technical reason for why it hasn't been done?
...
I need to print out the querystring value "?type=xxx" inside my .aspx-page, why doesn't this work:
<%= Request.QueryString("type") %>
While this does:
<%= Request.QueryString(0) %>
The first prints out nothing, the second one prints out the value as expected, but it isn't always the first value I want...
Any ideas?
I redirect to...
I'd like to prevent the real setter code being invoked on a property on a partial class.
What is the syntax for this?
My current code to stub out the getter (I'd like to also stub out the setter):
var user = MockRepository.GeneratePartialMock<User>(ctor params...);
user.MyProperty = "blah";
Something like this?
user.Stub(u => u.MyP...
i can get file name via below codes. How can i send this file to remote computer. this remote computer ip: 192.168.2.105 also i can use 51124 port
class Program
{
static void Main(string[] args)
{
string[] dosyalarinYollari = System.IO.Directory.GetFiles(@"z:\20071008\1.2.392.200036.9116.2.6.1.48.1215...
Hi.
I have interface IModule and several classes that implements it.
In test i need to create instance of each type(class) implementing that interface.
Is is possible(with StructureMap)?
...
Hello,
when we scan a document with a resolution of 2400dpi or higher, we recieve (for example) the following error-message:
COMException: Ausnahme von HRESULT: 0x80010100 (RPC_E_SYS_CALL_FAILED)
or
COMException: Ausnahme von HRESULT: 0x8021006F
in one of the following lines
img = itm.Transfer(scanFormat.ScanFormat) as ...
I am "translating" a NUnit test to Visual Studios unit testing and I am wondering if the attribute [ClassInitialize()] in VS is equivalent to [SetUp()] in NUnit?
...
I have a curious problem with a .net usercontrol which is probably some page lifecycle issue that I've missed, but I'd be grateful for some advice.
The control has a "showContributor" boolean property which is supposed to turn some columns in the display on or off. It consists of a repeater control containing other custom usercontrols t...
hi
I have a custom control, (relevant code at the bottom)
it consists of some text/links and a hidden textbox (rather than a hidden input). when rendered, the user via another dialog and some JS sets the value of the textbox to an integer and clicks submit on the form.
i am trying to assure that the user has entered a number (via the JS...
My question is very simple to expose:
I have a few aplications that share data between then. I need a way to support that data sharing (cross several computers) and when one aplication changes data, others should be notified about that.
My question is about what tecnologies could be usefull to me. The solution i realise at this moment ...
Hi guys,
I've got a TextBox in which user can input a their desired username.
Underneath I've got a checkbox that once clicked it copies the user's email adress into the textfield and then disable it to prevent further changes. This feature is implemented by using jQuery.
The problem is that I've got a RequiredFieldValidator on that Te...
I have a System.Timer setup to trigger an event every day at 2AM.
If the process the timer starts fails then I want the timer
to be reset to run every 15 minutes until the process completes succesfully.
// this is how the timer is set up.
// this is working correctly.
double startTime = milliseconds_of_hour_to_start.
Timer = new Syst...
I'm writing a banking system and my customer wants support both Russian and American numeric standards in decimal digits delimiter. Respectively . and ,.
Now only , works properly. Perhaps because of web server's OS format (Russian is set).
String like 2000.00 throws a FormatException:
Input string was not in a correct format.
H...
What is the best way to implement a decision tree in SharePoint? Is there a web part available? Does any of Sharepoint's Fab 40 templates contain a decision tree web part? i have searched but i couldnt find a useful answer anywhere.
Please suggest.
...
sir im using visual studio 2008 and im making help desk project on asp and sql server so tell me hw can i add flash backgroung on my home page
...
I have a dll which is based on .net 3.5 -- it uses internally for example Linq, but the exposed API is straightforward, no fancy stuff. Since C# generics are resolved at compile time I assume that for calling party all it counts is API (all public parts).
However when I try to use this dll from net2.0 project I get info, that the dll ca...