Inner Join in LINQ to SQL Not Working

What's wrong with my code? For the Funcionario table and the Projeto table are underlined in red ...

DataContext db = new projfuncionarioDataContext();

var query = from p in db.Funcionario
            join c in db.Projeto on p.Cdfunc equals c.Cdfunc
            select new
              ID = p.Cdfunc,
              Produto = p.Nome,

GridView1.DataSource = query;


DataContext db = new projfuncionarioDataContext(); 

Should be:

projfuncionarioDataContext db = new projfuncionarioDataContext(); 


GridView1.DataSource = query.ToList();

Does your GridView have the AutoGeneratedColumns property set?

Need Your Help

Using Python to check words


I'm stuck on a simple problem. I've got a dictionary of words in the English language, and a sample text that is to be checked. I've got to check every word in the sample against the dictionary, an...

Apache Domain Registering

html apache web dns hosting

I'm making a website using Apache as the web server. Would I have to register a domain with someone like godaddy? I don't want someone like godaddy hosting a website for me. I want to be in control...