MVC3 ASP.NET Objects within viewmodels?
I'm trying to pass a view model out to my views from my controller. I have a basic ViewModel working which contains simple things like strings/ints etc but now I want to pass out an object within my view model. I've made the appropriate changes to the view model to now contain this object but I'm struggling to retrieve the data in my view. Within my view I have...

@model StockTake.Controllers.ViewModelTest

But @Model.ObjTest doesn't seem to be working. When it only contained strings I could type @Model.str1 and it'd access it, could somebody set me straight on what I'm doing wrong? :)

Thanks
MVC3 ASP.NET Objects within viewmodels?
===

I'm trying to pass a view model out to my views from my controller. I have a basic ViewModel working which contains simple things like strings/ints etc but now I want to pass out an object within my view model. I've made the appropriate changes to the view model to now contain this object but I'm struggling to retrieve the data in my view. Within my view I have...

@model StockTake.Controllers.ViewModelTest

But @Model.ObjTest doesn't seem to be working. When it only contained strings I could type @Model.str1 and it'd access it, could somebody set me straight on what I'm doing wrong? :)

Thanks