|
Hi all ,easy question for experts
If we don't use an explicit attribute [NonSerialized]
BinaryFormatter doesn't serialize
private members .
Is that right ?
if so , what about other .Net Framework serialization classes ? Soap , XmlSerializer
?
|
|
|
|
|
Is it possible to customize the formclosing event?
I want to change the FormClosingEventArgs to be a custom EventArgs class but I can't seem to figure out exactly how to accomplish this.
I have created an EventArgs class that inherits the FormClosingEventArgs class but when I connect to the event it will only let me us the FormClosingEventHandler which brings with it only FormClosingEventArgs which is where my problem is. I have succeeded in using the formclsoingeventargs to fire a custom event but I would liek to do it directly if possible
|
|
|
|
|
You can compare what the sender is and cast it to EventArgs if it is castable, be careful though, I highlight checking the sender so that you specifically don't cause a crash with an invalid cast.
|
|
|
|
|
Wow that is interesting. It would seem you have to
public new event FormClosedEventHandler FormClosing;
To custom fire the event. For whatever reason I cannot compile inside of the form when attempting my own
FormClosing(this, new FormClosedEventArgs(CloseReason.ApplicationExitCall));
without it.
This may not work because of the way the new keyword works.
Need software developed? Offering C# development all over the United States, ERL GLOBAL, Inc is the only call you will have to make.
If you don't ask questions the answers won't stand in your way.
Most of this sig is for Google, not ego.
|
|
|
|
|
It seems that inheriting from a class removes your ability to directly call an event that is marked as public.
Need software developed? Offering C# development all over the United States, ERL GLOBAL, Inc is the only call you will have to make.
If you don't ask questions the answers won't stand in your way.
Most of this sig is for Google, not ego.
|
|
|
|
|
you need to create a new FormClosing event with your custom args in the delegate derived from CancelEventArgs. I've given an example in the previous thread[^]
DaveBTW, in software, hope and pray is not a viable strategy. (Luc Pattyn)Visual Basic is not used by normal people so we're not covering it here. (Uncyclopedia)
|
|
|
|
|
yeah but this goes back to what I was saying before about doing it directly. Eliott's idea actually worked. Is it better to do it all through the event or to do it the way you originally suggested?
|
|
|
|
|
Personally, I think the OrderCreated is a seperate thing that just happens to occur when the form is closing, so I would write a seperate method that I would call from an overridden OnFormClosing after checking that cancel is false (after calling base.OnFormClosing).
In the new method I would create the order and raise an event passing the order in the args.
DaveBTW, in software, hope and pray is not a viable strategy. (Luc Pattyn)Visual Basic is not used by normal people so we're not covering it here. (Uncyclopedia)
|
|
|
|
|
Hey guys
Ive got a console application that gets called by another program, its purpose is to communicate to an external device, retrieve data from it, and output it to a text file.
At the client where the error is occurring, A7Comms.exe is located on a server in a shared folder. The exe is intended to be executed from a client machine which has the shared folder A7Comms resides in mapped as a network drive.
When we try to execute the exe from the client machines command shell(cmd.exe) the following is output --> Screen Shot[^]
The app was tested on both that server and client and works fine if executed locally.
Now i tried this same setup(exe on server in a shared folder, map network drive on client machine, execute from network drive) in my office and it works fine.
Obviously there are some security policies in the OS preventing my executable from executing over my clients network, but i have no clue what it could be or where to set it i cant even reproduce the issue
Im going to the client to check it out Wednesday(28 Jan 2009) next week(only have access to the server Wednesdays from 8am to 12pm) bit i have no idea where to even start
Any ideas?
Thanks
Harvey Saayman - South Africa
Software Developer
.Net, C#, SQL
you.suck = (you.Passion != Programming & you.Occupation == jobTitles.Programmer)
1000100 1101111 1100101 1110011 100000 1110100 1101000 1101001 1110011 100000 1101101 1100101 1100001 1101110 100000 1101001 1101101 100000 1100001 100000 1100111 1100101 1100101 1101011 111111
|
|
|
|
|
Try bringing it directly on the client machine, that client machine might not have the necessary privileges to run an application through the network that reads/writes to its drives.
|
|
|
|
|
EliottA wrote: Try bringing it directly on the client machine
I cant, the program that calls A7Comms MUST reside on the server for backup purposes, and therefor the A7Comms app must be located with the calling app.
EliottA wrote: client machine might not have the necessary privileges
That's definitely whats going on, i need to know which privileges to set and how
Harvey Saayman - South Africa
Software Developer
.Net, C#, SQL
you.suck = (you.Passion != Programming & you.Occupation == jobTitles.Programmer)
1000100 1101111 1100101 1110011 100000 1110100 1101000 1101001 1110011 100000 1101101 1100101 1100001 1101110 100000 1101001 1101101 100000 1100001 100000 1100111 1100101 1100101 1101011 111111
|
|
|
|
|
|
I am developing a C# application and I want to know how can I protect the computer from being used> i think all software are not strong including the activation method which Microsoft uses that's why I want to know if it's possible to use a hardware protection like USB dongles with my .NET application?
|
|
|
|
|
you have to buy the dongle kit
check this
Link[^]
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87֦ʻ6ϣN8ȤBcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-iTV.C\y<pjxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
Yes, in fact many of the "dongle" vendors have API's you can use. However, keep in mind that it is very easy to reverse engineer .NET applications. Your time is better spent on a good business model than protecting your software from intentional, dedicated piracy.
One thing I have been considering, lately, is the concept of custom builds for clients using encryption based on their details. Then it would be much easier to catch a pirate. I haven't worked out all of the details yet, however.
Need software developed? Offering C# development all over the United States, ERL GLOBAL, Inc is the only call you will have to make.
If you don't ask questions the answers won't stand in your way.
Most of this sig is for Google, not ego.
|
|
|
|
|
Hi,
linking a license to some hardware characteristics has some drawbacks; what if the customer for good reasons wants to change the motherboard, the disk, the CPU, the amount of RAM, or anything else. He would like to be sure that won't affect the availability of his licensed software.
Also some internal "unique IDs" can be faked (MAC address) or are unreachable (CPU uniqueID).
I am in favor of adding a specific piece of hardware; the cheapest that holds a unique ID currently is a USB memory stick (I haven't found one yet without a very long ID; AFAIK there is no guarantee that they all will be different, but there will be a great many different values for sure); the nice thing is USB sticks is something your customer may already have or can buy himself.
What remains a problem is the reverse engineering being rather easy on .NET
|
|
|
|
|
The USB dongle solution is actually more complex and complete than Unique ID, you can load secure software and private keys onto them. Check out Aladdin eTokens for an example.
Need software developed? Offering C# development all over the United States, ERL GLOBAL, Inc is the only call you will have to make.
If you don't ask questions the answers won't stand in your way.
Most of this sig is for Google, not ego.
|
|
|
|
|
Sure, it is also more expensive and requires more effort to set it up. IMO it would not fit well protecting a 10 to 50$ app.
|
|
|
|
|
It makes no sense to secure a 10 to 50 dollar app. beyond keep them honest policies.
Need software developed? Offering C# development all over the United States, ERL GLOBAL, Inc is the only call you will have to make.
If you don't ask questions the answers won't stand in your way.
Most of this sig is for Google, not ego.
|
|
|
|
|
It makes little sense to buy a 10 to 50 dollar app.
But seriously, that sounds more like it should be on the honor system -- "If you like this software, please consider sending me $10 (or more!) to encourage future development."
That way, the users become the distribution medium, and there is no "piracy".
|
|
|
|
|
Hi,
vs2005 .net2
I have a win form app running on a number of different clients. The clients use a web service to communicate with a database.
When a client loads it instanciates a web service object and the web service instanciates its own log object which writes to a log file on the server specific to that client.
So if 50 clients are running I want 50 web service instances running.
Ive noticed that different clients write to different log files...
When 2 clients load and instanciate a web service - are 2 or 1 web service instances created on the server?
Can I ensure that a client only uses the web service that it instanciates?
Thanks in advance...
|
|
|
|
|
I think that's what is Happening.
A Client can use only the Web Service that it instantiates in your case
Vuyiswa Maseko,
Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers."
C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.tiyaneProperties.co.za
vuyiswam@its.co.za
|
|
|
|
|
Ok The problem is as follows:
Lets say Client A starts, it instanciates a web service that is configured to write to log file A on the server.
Then say Client B starts, it instanciates a web service that is configured to write to log file B on the server.
The problem is now when I call a web method on Client A it writes to log file B on the server.
So it appears that all clients will write to the file determined by the last instanciated web service. - This is not the way I thought it worked...
However to get around this issue I could modify the log methods to take a parameter (being the log file path) every time it writes...
|
|
|
|
|
Chazzysb wrote: are 2 or 1 web service instances created on the server?
I thought it was only one, but I'm certainly no expert.
I hope an expert can clear this up for both of us.
|
|
|
|
|
Hi
I have to convert a pdf file into doc/word file with all the images and formatting preserved. Searched all the options,tried all the free libraries but nothing seems to be working.
Anyone having idea ??????????
Thanks
Don't walk as if u rule the world,walk as if u don't care who tha Hell rules the world ...
|
|
|
|