ASP.NET C# pass object to method
<p>How do I pass an object from one method to another?
From the code below, I would like to pass <code>newEvent</code> from <code>xmlReader()</code> to <code>outputData()</code></p>

<pre><code>public class Event
{
    public int ID {get; set;}
}


public void xmlReader()
{
    Event newEvent = new Event;

    newEvent.ID = 56;

    outputData(newEvent);
}


public void outputData(object theEvent)
{
    MainContainerDiv.InnerHtml = theEvent.ID;
}
</code></pre>

<hr>

<p>Thank you,
Jordan</p>
