Hi,i am newbie for sharepoint.
our aim is to save end user career details and resume in to the customlist.
we saved the career details. but we cannot able to attach the reusme to the custom list attachment.
we generated entity class for custom list.
we have manager class and business validation class.
from user control we pass the EntityClass Item and its value to validation class.
from there it calls busniess layer to save the details in to column.
where as for resume we cannot attach the documents to list attachment.
please help me. [email removed]
from the entity class i don't see any column value for attachment.
from user control on click event for save.
-------------------------------------------------
public bool SaveApplications()
{
FertilApplicantsValidation = new FertilApplicantsValidation();
FertilVacancyApplicationsItem item = new FertilVacancyApplicationsItem();
item.ApplicantName = txtName.Text.ToString().Trim();
item.ApplicantEmail = txtEmail.Text.ToString().Trim();
item.ApplicantContactNumber = txtContact.Text.ToString().Trim();
item.ApplicationDate = DateTime.Now;
item.VaccantidId.Add(int.Parse(VaccantID));
FertilApplicantsValidation = new FertilApplicantsValidation();
return FertilApplicantsValidation.SaveFertilApplicnats(URL, item);
}
-----------------------
from Validation class
public bool SaveFertilApplicnats(string webUrl, FertilVacancyApplicationsItem item)
{
bool isSave = false;
try
{
using (FertilVacancyManager manager = new FertilVacancyManager(webUrl))
{
isSave = manager.saveFertilApplicantsData(item);
}
}
catch (Exception ex)
{
Logger.Instance.Error("FertilVacancyValidation_getFertilApplicantsData", ex);
}
return isSave;
}
----------------
from Manager class:
public bool saveFertilApplicantsData(FertilVacancyApplicationsItem item)
{
try
{
using (ContextSwitch cSwitch = new ContextSwitch())
{
m_ApplicantsdataContext = cSwitch.GetFertilApplicantsDataContext(m_webUrl);
m_ApplicantsdataContext.FertilVacancyApplications.InsertOnSubmit(item);
m_ApplicantsdataContext.SubmitChanges();
}
}
catch (Exception ex)
{
Logger.Instance.Error("VacancyManager_getFertilApplicantsData", ex);
return false;
}
return true;
}