<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="eventHandle1.aspx.cs" Inherits="view.flow.eventHandle1" %>

<html><head>
  <meta http-equiv="X-UA-Compatible"content="IE=EmulateIE7"/>
  <meta http-equiv="Content-Type" content='text/html; charset=utf-8' />
  <title>workflow events</title>
  <link href='../skin/view.css' type='text/css' rel='stylesheet'>
  <script language=javascript>document.write("<script type='text/javaScript' src='../common/view"+location.search.substring(1)+".js'><\/script>");</script>
  <script type='text/javascript' src='../common/view.js'></script>
</head>

<body scroll=no>
<div style='margin:0px 10px;'>
<div>function onActionAfter(nActionId=1,sName)</div><textarea style='width:460px;height:380px;line-height:1.5;' id=oOnAction onkeypress='if(event.keyCode==34) return false;'></textarea>
</div>
<script language=javaScript>
    workflowActionsShow('okCancel');
    document.getElementById('oOnAction').value = dialogArguments.value.replace(new RegExp('<br>', 'g'), '\r\n');
    function onActionBefore(nActionId, sName, bPostForm) {
        if (nActionId > 0) {
            dialogArguments.value = document.getElementById('oOnAction').value.replace(/(^\s*)|(\s*$)/g, "").replace(new RegExp('\r\n', 'g'), '<br>');
        }
        self.close();
        return 0; //prevent from submitting
    }
</script>
</body>
</html>