tags:

views:

69

answers:

1

I am trying to create a simple task manager solution based on the Nerd Dinner tutorial

weblogs.asp.net/scottgu/archive/2009/04/28/free-asp-net-mvc-nerddinner-tutorial-now-in-html.aspx.

EDIT: I have removed the http:// on these urls because I have not got enough rep to add links into a post.

I have built my model as shown here: nerddinnerbook.s3.amazonaws.com/Part3.htm It is identical except that Dinner is a task and RSVP is a project.

Relationship task.projectId -> project.projectId I have more fields in these tables but I have kept the public partial task class in the model simple so far to match the tutorial.

My question is that when I try to add a new view and in the dialog I select "strongly typed view" my model class for the task does not show up in the drop down, anyone know why??

Probably a bit vague, i am just trying to get some ideas on why this could be happening.

I thought maybe my namespace was incorrect somewhere or my class was not public but it is.

I have got a reference to my repository in my controller by doing TaskRepository taskRepository = new TaskRepository(); and the controller has a using reference to TaskManager.Models;

All confusing me.

+1  A: 

I don't know how the dialog picks classes (other than it requires a clean compile), but you can just choose any random class and then edit the first line of the resulting aspx to substitute the class you prefer.

Craig Stuntz
Thanks for the suggestion of substituting it, I tried that but wanted to use the T4 template for detail scaffolding too and this was greyed out for me when I typed in my model name directly.My code didnt have any highlighted errors but I didnt try compiling so I will try that later today. Thanks
Pricey
Your correct in saying I should do a build. I was missing a "using System.Data.Linq;" on my task class and fixed that did a build and then worked fine. Thanks
Pricey