#----------------------------------------------------------
#Function for the event procedure
#----------------------------------------------------------
def dialogep(object)
  if object.getStatus() != Mpfc::WS_DIALOG_OK
    object.setVisible(Mpfc::False);
    return;
  end
  
  $str = $newvifi_003.getProperty("labelString");
  if $str.getCharPtr() == ""
    $msg = Mpfc::WSGIappMessageDialog();
    $msg.setProperty("defaultPosition",Mpfc::True);
    $msg.setProperty("width",500);
    $msg.setProperty("labelString",
           "Please input some string to the input field.");
    $msg.popup();
    return;
  end
  $val = $newradi_006.getProperty("value");
  if $val == 0
    $msg = WSGIappMessageDialog();
    $msg.setProperty("defaultPosition",True);
    $msg.setProperty("width",500);
    $msg.setProperty("labelString","Please select a item of the radio group.");
    $msg.popup();
    return;
  end
  object.setVisible(Mpfc::False);
end
