I have a MethodInto of interface method and type of a class that implements the interface.
I want to find MethodInfo of the class method that implements the interface method.
The simple method.GetBaseDefinition() does not work with interface methods.
Lookup by name won't work either, because when implementing interface method explicitly...
I have developed a project in VS2005(C#) which contains two crystal reports, the project is working fine and crystal reports are running properly on my system. But when my friend tries to run the project on his system, then the projects runs well but when I am opening crystal reports I am getting the error shown in image below
We are ...
I know there are implementations of Python and of Perl for .NET. Have you ever heard of any similar plans for PHP?
...
Hello everyone,
For the same ADO.Net statement, I want to make sure my understanding of isolation level and lock is correct.
In default SQL Server isolation level (read committed), after read each row, the row will unlocked;
If I raise isolation level to repeatable read, the lock (on the whole table? or some other level lock?) will be...
This is a C# WinForm question. I have a MDI child form, when the form is opened, it will generate many tables to display in a DataGridView. The tables can be big and I use DataBinding to connect the tables to the DataGridView. When I close the form, I notice that the memory taken by the form is reclaimed timely.
I use the normal way of ...
For performance purposes I want to write to memory, where an external application can read. I can't link both applications together, so I think the only way is by writing a file. But writing it to a physical disk isn't fast enough. I want to mount a virtual partition so any application can access it. How to do it?
...
I have a .xaml file and a .cs file that share value with Binding.
To make it simples, I have 1 button and 1 textbox. I want to button to be disabled when the textbox's text has no character.
Here is the two codes of the xaml for binding:
<TextBox Name="txtSend" Text="{Binding Path=CurrentText,UpdateSourceTrigger=PropertyChanged}"></...
If
var arrayStrings = new string[1000];
Parallel.ForEach<string>(arrayStrings, someString =>
{
DoSomething(someString);
});
All 1000 Threads will spawn almost simultaneously?
...
Hello,
I'm playing around with SubSonic 3.0 at the moment, and it looks really straight-forward (except that I still have to decide between SimpleRepository and ActiveRecord, but that's another story).
However, as the documentation is a bit sparse, I am not sure if it supports foreign-relationships and lazy-loading. Essentially, I have...
Imagine that during a
foreach(var item in enumerable)
The enumerable items change. It will affect the current foreach?
Example:
var enumerable = new List<int>();
enumerable.Add(1);
Parallel.ForEach<int>(enumerable, item =>
{
enumerable.Add(item + 1);
});
It will loop forever?
...
I want that a non-.NET application access a Memory Mapped file, but this application is not aware of the existence of Memory Mapped files, so I need the file path. It is possible?
...
I have written a simple WCF service that accepts and stores messages. It works fine when hosted locally. I still works when hosted on IIS 6. But when I enable the service's ability to store the messages to xml I get the following error: Access to c:\windows\system32\inetsrv\Onno.xml has been denied (translated from dutch, so may not matc...
How can I change the port number used by WebBrowser control? The standard port number is 80, but I would like to use a different port.
...
I finally discovered a way to use command line Matlab from .NET without linking:
Write variables from .NET to a MAT file using David A. Zier's "csmatio" dll.
Read the file from Matlab, process it and save the results to a MAT file:
var process = new Process()
{
StartInfo = new ProcessStartInfo()
{
FileName = MatlabExec...
Problem:
I have a class, say Foo, that implements an Id property. Foo must be
serializable. Foo.Id should be initialized to a new GUID on initialization
of Foo. Foo.Id should not be changable once it has been set. Deserialization will attempt to set the Foo.Id, so it must be made Public.
Private _Id As String=system.Guid.NewGuid....
There is any command line or .NET method that runs a process in the background hiding any window it tries to open?
Already tried:
var process = new Process()
{
StartInfo = new ProcessStartInfo()
{
CreateNoWindow = true,
WindowStyle = ProcessWindowStyle.Hidden,
FileName = TheRealExecutableFile...
Hi,
We've got into a very tricky scenario in a project. We have used lot of reflection in our project.
We have ..
Validation Framework driven by Attributes and Reflection
Extension methods that transaforms a DataRow to an Entity Object using Attributes and Reflection and vice versa. The same thing we have done for DataTable and Enti...
I have the following scenario. The client code only has access to FooHandler, not directly to Foo instances.
public delegate void FooLoaded(object sender, EventArgs e);
class Foo {
public event FooLoaded loaded;
/* ... some code ... */
public void Load() { load_asynchronously(); }
public void callMeWhenLoadingIsDone() {...
This is a pretty simple question but I'm somewhat stumped.
I am capturing sections of text that match "xxxxxxxxxx". It works fine.
string pattern = "(?<quotePair>\"[^/\"]*\")";
Now I want to make a new pattern to capture “xxxxxxxxxx”... I used:
string pattern2 = "(?<lrquotePair>“[^/\"“]*”)";
For some reason the second pattern w...
Hello everyone,
Could anyone recommend me a good tutorial about Silverlight animation for a beginner, and I am especially interested in how to read the animation code in XAML (I always feel magic code) and develop my own animation. If the tutorial covers any tools which could facilitate animation code rede and animation development, it ...