Pass enum as method parameter
texasnomad: I declared a method named EnterTrade() that only takes one variable, an enumeration named TradeDirection. The compiler throws the errors TradeDirection - declaration without type. Why won't this compile?

Play videoPlease edit your post.
For large amounts of code, attach it.
void EnterTrade(TradeDirection dir){} // TradeDirection not defined (yet) enum TradeDirection{ Long, Short }; // Too late
I declared a method named EnterTrade() that only takes one variable, an enumeration named TradeDirection. The compiler throws the errors TradeDirection - declaration without type. Why won't this compile?
void EnterTrade(TradeDirection dir)
{
}enum TradeDirection
{
Long, Short
};