Re: event arguments

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



> It seems odd to specify a convention which only becomes useful several
> years later though!

Bill Gates once said he couldn't imagine a computer needing more than 640 KB
of memory. I suppose Microsoft has learned that lesson. In spades!

--
;-),

Kevin Spencer
Microsoft MVP
..Net Developer
If you push something hard enough,
it will fall over.
- Fudd's First Law of Opposition

"Jon Skeet [C# MVP]" <skeet@xxxxxxxxx> wrote in message
news:MPG.1de2f14832fa2b7d98ca40@xxxxxxxxxxxxxxxxxxxxxxx
> Jon Skeet [C# MVP] <skeet@xxxxxxxxx> wrote:
>
> <snip>
>
>> No, that doesn't work. Try this:
>>
>> using System;
>> using System.Windows.Forms;
>>
>> public class Test
>> {
>> static void Main(string[] args)
>> {
>> MouseEventHandler handler = new MouseEventHandler(Foo);
>> }
>>
>> static void Foo (object sender, EventArgs e)
>> {
>> }
>> }
>>
>> With 1.1, it doesn't compile. I can't remember whether it would in 2.0
>> - I seem to remember that there's some covariance changes, but
>> unfortunately I'm between beta and release at the moment, with nothing
>> actually installed to try it out on...
>
> Just tried this with 2.0 and it *does* work due to delegate covariance
> (or contravariance - I never get those two the right way round).
>
> It seems odd to specify a convention which only becomes useful several
> years later though!
>
> --
> Jon Skeet - <skeet@xxxxxxxxx>
> http://www.pobox.com/~skeet Blog: http://www.msmvps.com/jon.skeet
> If replying to the group, please do not mail me too


.



Relevant Pages

  • Re: Interesting math
    ... divisible by an even number with no remainder, ... this is, modulus zero. ... divisible by an odd number with no remainder, ... An enjoyable convention, ...
    (alt.usage.english)
  • [fitsbits] Comments on image distortion conventions
    ... The document should specify default values for any coefficients that are absent from the header, but might be expected based upon the value of A_ORDER or B_ORDER. ... Presumably either the values would be taken to be zero or the convention should require that all keywords be present. ... The convention would appear to mis-use the CTYPEi reserved keyword in a way that at least technically violates the FITS standard. ... first four characters specify the coordinate type, the fifth character is a hyphen, and the remaning three characters specify an algorithm code for computing the world coordinate value...." ...
    (sci.astro.fits)
  • Re: Table Size
    ... Seems odd to me that they'd specify a files size limit for a table of 1GB ... Access database file is limited to 2GB. ... Memo fields and OLE object fields have a size limit of 1GB. ...
    (comp.databases.ms-access)
  • Re: infinity
    ... Matt Gutting said: ... > Tony Orlow wrote: ... specifics of the set that we can specify the properties of the set. ... If using an odd base, it is odd, since an odd to any ...
    (sci.math)
  • Re: Random String for passwords
    ... passwords that I specify. ... Odd...here it was crashing VB everytime run. ... That's very odd, indeed. ... Compile error: ...
    (microsoft.public.vb.general.discussion)