Hello, hope you all are good, Am kind of a new developer to .NET and currently doing one of my student project over .NET 4 (MVC-3), the problem i have been facing is:
I’ve an Array of string which contains few information of product such as names, description etc.
Now i want to pass this array to view and retrieve these details on the view page..
Viewbag["proinfo"]=proinfo; // proinfo is the array.
And retrieve it in the view page as:
var proinfo =ViewBag["proinfo "];
But that’s not happening.. So can some one of you please guide me to the right way of passing an array from controller to view?
Your issue is a bit off-topic in the C# General Forum. There are forums dedicated to various topics including ASP.NET and MVC.
Please refer to this link to the MSDN library for researching MVC3. http://msdn.microsoft.com/en-us/library/gg416514(v=VS.98).aspx
Please refer to this link for the MVC forum. http://forums.asp.net/p/1704590/4527506.aspx/1?A+Mvc3+Forum+app
Mark the best replies as answers. "Fooling computers since 1971."