1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

c# printpageevnet args

Discussion in 'C#' started by markyjj, Feb 6, 2006.

  1. markyjj

    markyjj New Member

    Joined:
    Dec 7, 2005
    Messages:
    19
    Likes Received:
    0
    Trophy Points:
    0
    Can any one shine some light on this problem that I Have.

    Am currently doing an assignment and I have to create a program that prints an ellipse on the page in 5 second intervals using the following signature:

    'private void MyHandler(object sender, ElapsedEventArgs args)'

    This does not make sense to me as I thought you have to use the (object sender, Printpageevent args) signature to do the actual printing. However, the above signature is what ive got to use.

    Maybe am missing something and any advice would be of grat help!!!!!!!!
     
  2. coderzone

    coderzone Super Moderator

    Joined:
    Jul 25, 2004
    Messages:
    734
    Likes Received:
    37
    Trophy Points:
    0
    Can you explain the problem in a bit better way as to what you want. It looks like you have a function name and want the body of it without specifying what is the input each is to be used for. I guess if its a Home work you can ask the teacher or whoever has given the function signature as to what is sender and args behave actually or expected to behave.
     
  3. markyjj

    markyjj New Member

    Joined:
    Dec 7, 2005
    Messages:
    19
    Likes Received:
    0
    Trophy Points:
    0
    From what ive learn't I know that I can write a message on the screen at 5 second intervals by using 'private void MyHandler(object sender, ElapsedEventArgs args)' as the signature.

    Now I have to do a program that prints an ellipse to the page also at 5 second intervals and I have to use the same signature as above. Am not sure how to use this signature with the print arguments. I hope this is clearer.
     
  4. coderzone

    coderzone Super Moderator

    Joined:
    Jul 25, 2004
    Messages:
    734
    Likes Received:
    37
    Trophy Points:
    0
    Probably by writing a handler to the Timer event

    Write the same event to draw the ellipse.
     

Share This Page