Click here to Skip to main content
15,885,757 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
XML
Server Error in '/' Application.

Parser Error
Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.

Parser Error Message: Could not load type 'JobPortal.view_jobseekers_byarea'.

Source Error:



Line 1:  <%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage2.master" AutoEventWireup="true" CodeBehind="view_jobseekers_byarea.aspx.cs" Inherits="JobPortal.view_jobseekers_byarea" %>
Line 2:  <asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
Line 3:


Source File: /view_jobseekers_byarea.aspx   Line: 1


Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.34248
Posted
Comments
phil.o 24-Oct-15 5:47am    
Do you have a view_jobseekers_byarea.aspx.cs file in your project? If yes, is its build-action set to 'Compile'? If yes, can you show a short sample of this class declaration?
ASPDevloper 24-Oct-15 5:49am    
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data.SqlClient;
using System.Data;

namespace JobPortal
{
public partial class view_jobseekers_byarea : System.Web.UI.Page
{
SqlConnection con = null;
SqlDataAdapter adp = null;
string expyrs, mnth;
int areaid;
string connstring=@"";
protected void Page_Load(object sender, EventArgs e)
{

}



protected void btnsearch_Click(object sender, EventArgs e)
{
expyrs = ddlexpyrs.Text;
mnth = ddlmnth.Text;
areaid = ddlarea.SelectedValue;

}

public void area()
{
con = new SqlConnection(connstring);//@"Data Source=.\SQLEXPRESS;AttachDbFilename=E:\PRJ\JobPortal\JobPortal\App_Data\JobportalDB.mdf;Integrated Security=True;User Instance=True");
con.Open();

string query = "";
adp = new SqlDataAdapter(query, con);
DataSet ds = new DataSet();
adp.Fill(ds);

ddlarea.DataSource = ds.Tables[0];
ddlarea.DataTextField = "area_name";
ddlarea.DataValueField = "area_id";
ddlarea.DataBind();
ddlarea.Items.Insert(0, new ListItem("select", "0"));

con.Close();
}
protected void Button4_Click(object sender, EventArgs e)
{
Multiview1.SetActiveView(view2);
}

protected void ddlarea_SelectedIndexChanged(object sender, EventArgs e)
{
area();
}

protected void GridView1_RowCommand(object sender, GridViewCommandEventArgs e)
{
if(e.CommandName.Equals("select"))
{
GridView gvr = (GridView)GridView1.NamingContainer.;

}



}

protected void GridView1_SelectedIndexChanged(object sender, EventArgs e)
{
try
{
GridView1.SelectedIndex = e.NewSelectedIndex;
foreach (GridViewRow gr in GridView1.Rows)
{
if (gr.RowIndex == GridView1.SelectedIndex)
{
recruiter.JobID = gr.Cells[1].Text;
recruiter.OrgName = gr.Cells[2].Text;
Response.Redirect("~/JobSeeker/SearchJobs/frmFullSelectedJobDetail.aspx?JobId=" + recruiter.JobID + "&OrgName=" + recruiter.OrgName);
}
}
}
catch (Exception)
{

throw;
}



}
}
}

hi, refer the following link,

http://www.codeproject.com/Questions/376141/Parser-error-Could-not-load-type
 
Share this answer
 
If you get an error message you don;t understand, start by Googling it: Parser Error Message: Could not load type[^]
The chances are someone has met it before.
The top few links have good suggestions, but the accepted solution here: Parser error: Could not load type[^] is probably the palce to start. And it's second on the Google list...
 
Share this answer
 
When the page loads, it goes to the markup first, then to the code. It knows which code to load based on the page directive in the markup...the colorized text from your post above that is at the top of your XHTML. If your CodeBehind has no "JobPortal" before the period, your "Inherits" can't have it either. Strip out the JobPortal from "iherits" and it should work
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900