|
I would use a thread pool and fire off a thread to perform the DataWrite processing. Configure the thread pool to allow one thread to run at a time (since you can't start a new write while another write is in progress).
Let the thread pool manage that, and tyour background worker will be free to work as intended.
I wrote an article on using a thread pool here:
Multithreading, Delegates, and Custom Events[^]
You should be able to take what's in that article and massage it to fit your own needs.
.45 ACP - because shooting twice is just silly ----- "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001
|
|
|
|
|
I was wondering if there is possibility to avoid TCP packet sending thread addition. BeginWrite is asynchronous operation call and should return immediatly.
Чесноков
|
|
|
|
|
Hi ,
Which is the best tool for .net obfuscation ? i found that dotfuscator is good tool for obfuscation. is any disadvantages are there with dotfucator?can i go with this tool.
thanks in advance,
|
|
|
|
|
I'm using Xheo codeveil, and I'm very content with that. As for it being better or worse than any other, I don't know, because I'm not a hacker, so I cannot judge which obfuscation is easier or harder to crack.
But I would be very interested in following this thread and get some pointers from people who knows.
As for obfuscation, this is a very good link:
http://www.csharp411.com/net-obfuscators/[^]
It lists a lot of obfuscators, but unfortunately there's no feature comparison...
Good luck
|
|
|
|
|
|
If you're talking about the obfuscator that came with Visual Studio, it's crap and won't prevent reverse engineering.
You actually have to *buy* a product, and there are several on the market. Be aware that only one of them (that I know of) is capable of obfuscating wpf/silverlight code.
Try googling for "obfuscation tool", and you'll get many hits. I've seen them for anywhere from $169 to several thousand dollars, but have never had the opportunity to actually use one.
.45 ACP - because shooting twice is just silly ----- "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001
|
|
|
|
|
Dotfuscator sucks.
Phoenix Protector[^] is pretty good and free
As with any obfuscator, it is not actually immune to reverse engineering, it just delays it.
|
|
|
|
|
|
Beat me to it!
I have learnt that you can not make someone love you, all you can do is stalk them and hope they panic and give in.
Apathy Error: Don't bother striking any key.
|
|
|
|
|
|
HOW TO ELIMINATE ONE
<br />
<br />
<br />
DataTable dt = dataSet1.Tables["tmpItem_aux"];<br />
DataRow newRow = dt.NewRow();<br />
<br />
newRow["itemcode"] = itemcodeTextBox.Text.ToString();<br />
newRow["itemDesc"] = itemDescTextBox.Text.ToString();<br />
newRow["quantity"] = quantityTextBox.Text.ToString();<br />
newRow["unitPrice"] = unitPriceTextBox.Text.ToString();<br />
newRow["total"] =totalTextBox.Text.ToString();<br />
dt.Rows.Add(newRow);<br />
<br />
<br />
OUTPUT SAMPLE
ITEMCODE ITEMDESC QUANTITY UNITPRICE TOTAL
TEST123 ITEMTEST 1 50 50 --------SAME IN LASTROW
SAMPLE1 ITEMSAMPLE 2 100 200
SAMCODE SAMDESC 3 20 60
TEST123 ITEMTEST 1 50 50 --------SAME IN FIRST ROW
modified on Friday, May 14, 2010 2:34 AM
|
|
|
|
|
DON'T SHOUT!
Some of us may have hangovers.
I have learnt that you can not make someone love you, all you can do is stalk them and hope they panic and give in.
Apathy Error: Don't bother striking any key.
|
|
|
|
|
OriginalGriff wrote: Some of us mayWe have hangovers.
FTFY
DaveIf this helped, please vote & accept answer!
Binging is like googling, it just feels dirtier. (Pete O'Hanlon)
BTW, in software, hope and pray is not a viable strategy. (Luc Pattyn)
|
|
|
|
|
Not me - don't drink these days!
I have learnt that you can not make someone love you, all you can do is stalk them and hope they panic and give in.
Apathy Error: Don't bother striking any key.
|
|
|
|
|
OriginalGriff wrote: days
Only nights
I know the language. I've read a book. - _Madmatt
|
|
|
|
|
We can't possibly help you because we don't know what the code looks like that called the code you've already posted.
And turn off your CapsLock key.
.45 ACP - because shooting twice is just silly ----- "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001
|
|
|
|
|
Just don't add the second row. check the data being added for unique values against the existing table. If the data exists, don't add it.
- Kalvin
|
|
|
|
|
I have a border set in all my form controls to Fixed3D but when I run the app, it displays FixedSingle for all of them. And this is across many forms in this project. I have other projects where the border settings display correctly.
What could be causing this?
Thank you
|
|
|
|
|
You could try cleaning your solution, sometimes old settings 'stick'. It's on the Build menu. Then build it again.
Other than that it is very difficult to diagnose. I have occasionally had things like that and the only solution I have found is to start again in a new solution.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Trying to use FTPWebRequest to upload a file through a proxy server and get the error 'The requested FTP command is not supported when using HTTP proxy'. I've looked for help on the net but the only solution people come up with is set the proxy to null
request.proxy = null;
This doesn't help me at all because our firewall has a direct internet block rule. So basically I have to go through the proxy. I can access FTP by using Filezilla with the proxy settings configured correctly (HTTp/1.1 CONNECT method), so I know it is possible.
Anybody have any ideas?
|
|
|
|
|
I don't know myself, however one of my articles got this[^] reaction, which might help you.
Luc Pattyn [Forum Guidelines] [Why QA sucks] [My Articles]
I only read formatted code with indentation, so please use PRE tags for code snippets.
I'm not participating in frackin' Q&A, so if you want my opinion, ask away in a real forum (or on my profile page).
|
|
|
|
|
Hi All,
I am developing a C# library. In that library there is an abstract method in an abstract class which let the users to implement it. Now I want to call that method in some other parts of my library. My problem is that the library aware only about the abstract class not about the class which user implemented. This is something I want to implement.
abstract class MyBase
{
abstract void DoSomething();
}
class AnotherPartOfLibrary
{
public void AnotherFunction()
{
}
}
class UserImplementation : MyBase
{
public void DoSomething(){}
}
All I need to let the user to extent my library and I want to call these extended functionalities in some parts of library. One method I found that to force the user for an entry of user class name in configuration file. So that I can create an instance of user class using reflection. But is there any other methods to do this?
Thanks & Regards,
Thomas
|
|
|
|
|
Does AnotherPartOfLibrary inherit from MyBase? If not, what is the relationship between the two classes?
You can't call MyBase.DoSomething() because it is abstract. If everything in the base is abstract are you sure you want a base class and not an Interface?
|
|
|
|
|
No AnotherPartOfLibrary is not inherited from MyBase. They don't have any relationship. This a library which can be extent. Its a component for the programmers. My problem is related to design of the component. Ok I will tell you the scenario. In this library, I am not aware of the user implemented classes. The users will implement the classes by extending the classes in my library. So those classes are defined only at the time of user implementation, not at the time of designing the library. Here comes my problem. I want to call the user extended functionalities in my library. Hope I am clear now.
|
|
|
|
|
I agree with the other answer...are you sure you don't want an interface and not an abstract class?
Also, how are you not getting errors with what's written anyway? First, you need to specify that abstract void DoSomething() is public. Secondly, in order to implement it, you have to override it in the class that inherits from it. In other words, it should be
public override void DoSomething()
And why would you ever want to call a method within an abstract class? You want to call a method within a class that inherits that abstract class. Unless, you just want an interface.
If you just want an interface, you would want something like this:
|
|
|
|