function checkRegData(form)
{
	if (form.membertype[0].checked==true)
	{
    TrimSpace1(form.depart1,"NCase");
    if (form.depart1.value == "")
    {
      alert("請輸入您的科系!");
      form.depart1.focus();
      return false;
    }
	}else if (form.membertype[1].checked==true)
	{
    TrimSpace1(form.unit2,"NCase");
    if (form.unit2.value == "")
    {
      alert("請輸入您的服務單位!");
      form.unit2.focus();
      return false;
    }
    TrimSpace1(form.depart2,"NCase");
    if (form.depart2.value == "")
    {
      alert("請輸入您的科系!");
      form.depart2.focus();
      return false;
    }
	}
  TrimSpace1(form.position,"NCase");
  if (form.position.value == "")
  {
    alert("請輸入您的職稱!");
    form.position.focus();
    return false;
  }
  TrimSpace1(form.realname,"NCase");
  if (form.realname.value == "")
  {
    alert("請輸入您的中文姓名!");
    form.realname.focus();
    return false;
  }
  TrimSpace1(form.telphone,"NCase");
  if (form.telphone.value == "")
  {
    alert("請輸入您的聯絡電話!");
    form.telphone.focus();
    return false;
  }
  TrimSpace1(form.email,"NCase");
  if (form.email.value == "")
  {
    alert("請輸入您的E-Mail!");
    form.email.focus();
    return false;
  }
  if (form.email.value != "")
  {
    if (checkEmailAddress(form.email)==false) {
      alert("請檢查E-Mail的格式！");
      form.email.focus();
      return false;
    }
  }
  TrimSpace1(form.address,"NCase");
  if (form.address.value == "")
  {
    alert("請輸入您的聯絡地址!");
    form.address.focus();
    return false;
  }
  TrimSpace1(form.content,"NCase");
  if (form.content.value == "")
  {
    alert("請輸入您的留言內容!");
    form.content.focus();
    return false;
  }
  return true;
}