No type was found that matches the controller named ...
No type was found that matches the controller named ...

I created a simple sql table to add a datagrid to an existing project. The existing project was created using the Editor Generator and the existing grids work fine. The new grid I tried adding gives me the error:
No type was found that matches the controller named 'test'
When I use the Generator to create a new project with this sample test grid it loads just fine. I then merely copy/pasted the code form the new project to the existing project and I still got the 'no type found' error. Why does it work on a stand-alone project created by the generator but not when added to an existing project. does the generator do some type of registering that I need to do manually when adding a grid?
This question has an accepted answers - jump to answer
Answers
Where does that error popup please? Also, can you show me your controller code? And have you loaded the DataTables.dll as a reference?
Thanks,
Allan
so i changed it from 'test' in case there was some issue with 'reserved words' or something. I figure make it a real table that I need anyway. still no luck. I added the new table to existing pages. It is the first one called BillingMethods. Again, all the other tables that were created using the generator work, except any new ones I add:
table id = BillingMethods - ajax error.
Do you have your
BillingMethodController
being imported in the program somewhere? I'm wondering if its just not being used! Also, is it an Generator program you are adding this to? If so, have you updated all of the namespaces accordingly to match?Allan
sorry, I don't understand the questions. I have one controller file and one model file containing all the data for all the data grids. Most work, but the new one doesn't.
What do you mean by "being imported"?
I believe they are all in the same namespace: namespace Billing.Controllers. Am I missing something?
I found a post somewhere that talked about a temp file that may need to be deleted: MS-ApiControllerTypeCache.xml. Lo and behold, when I look at the contents it does not have the new controller that I added. However, when I delete the file, rerun the package, the xml file that gets recreated still does not have the new controller. Why isn't it getting added?
ok. this is crazy...after rebooting, clearing cache, deleting that cache.xml file...nothing..that one controller is still not registering. So then I delete the controlers.cs file from the project compeltely, figuring now there wont' be any controllers registered....nope...it ran pefectly (except that one missing controller). How is it not crashing with the controller.cs file missing??????? I cleared cache and everything one more time after deleting the file. Where is this controller data getting stored and why is it not refreshing?
i went ahead and started a whole new VS project. I then copied and pasted the code from the old to the new. Everything worked perfectly. I had another post here about a drop-down not populating. That was fixed too!!! The code was right the whole time...it is just something with the project was not refreshing with the new controllers!!!