RadAsyncUpload - Required Custom Validation Only Fires After 1st Post

2 posts, 1 answers
  1. Jaish
    Jaish avatar
    12 posts
    Member since:
    Mar 2015

    Posted 10 Jun 2015 Link to this post

    Issue is that once my page loaded very 1st time and make a post, client side custom validator for AsyncUpload isn't fire eventhough server validator fires. Then again Posting 2nd time, client side validator started firing. I couldn't find what the difference after my 1st POST so that client validator has started working for 2nd POST onwards. Information about any points need to verify would be appreciated.

    <%@ Page Title="Create RFQ" Language="C#" AutoEventWireup="true" CodeBehind="CreateRFQ.aspx.cs" MaintainScrollPositionOnPostback="true" Inherits="QR.ESG.UI.RFQ.CreateRFQ" %>

    <%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %>
    <%@ Register Src="../UserControls/RFQControls/CollaborationCommitte.ascx" TagName="CollaborationCommitte" TagPrefix="ucCCM" %>
    <%@ Register Src="../UserControls/RFQControls/RFQStation.ascx" TagName="RFQStation" TagPrefix="ucStation" %>
    <%@ Register Src="../UserControls/RFQControls/InternalApprovalDocuments.ascx" TagName="InternalApprovalDocuments" TagPrefix="ucIADocs" %>
    <%@ Register Src="../UserControls/RFQControls/RFQAttachments.ascx" TagName="RFQAttachments" TagPrefix="ucRFQAtachtmt" %>
    <%@ Register Src="../UserControls/RFQControls/DateTimeControls.ascx" TagName="DateTimeControls" TagPrefix="ucDateTimeCtrls" %>
    <%@ Register Src="../UserControls/RFQControls/InvitedSuppliers.ascx" TagName="InvitedSuppliers" TagPrefix="ucInvSupplrs" %>
    <%@ Register Src="~/UserControls/RFQCateringControls/CateringMenuGrid.ascx" TagName="CateringMenuGrid" TagPrefix="ucCatMnuGrd" %>
    <%@ Register Src="../UserControls/RFQControls/RFQTemplate.ascx" TagName="RFQTemplate" TagPrefix="ucRFQTemplt" %>
    <%@ Register Src="~/UserControls/RequControls/HotelAccommodation.ascx" TagName="HotelAccommodation" TagPrefix="ucHotacAccom" %>
    <%@ Register Src="../UserControls/RFQControls/InternalApprovalDocuments.ascx" TagName="ContractTermsAndCondition" TagPrefix="ucContrTerms" %>
    <%@ Register Src="../UserControls/RFQControls/RFQInfo.ascx" TagName="RFQInfo" TagPrefix="ucRFQInfo" %>
    <%@ Register Src="../UserControls/PurchReqControls/ItemDetails.ascx" TagName="ItemDetails" TagPrefix="ucItemDetails" %>
    <%@ Register Src="~/UserControls/Template/CommercialAppendixBStaticTemplate.ascx" TagName="CommPkgTemplate" TagPrefix="ucCommPkg" %>
    <%@ Register Src="../UserControls/RequControls/ClarificationDetails.ascx" TagName="Clarification" TagPrefix="ucClarification" %>
    <%@ Register Src="../UserControls/RequControls/FlightOperatingAndRoomReqDisplay.ascx" TagName="FlightOperatingAndRoomReqDisplay" TagPrefix="ucFltOptDisplay" %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"/>
    <html>
    <head id="head2" runat="server" onkeypress="return pressenter(event)">
    <title>Create RFQ</title>
    <link href="../Styles/default.css" rel="stylesheet" type="text/css" />
    <link href="../Styles/accordian.css" rel="stylesheet" type="text/css" />
    <link href="../Styles/datepicker.css" rel="stylesheet" type="text/css" />
    <link href="../Styles/CommonPage.css" rel="stylesheet" type="text/css" />
    <link href="../Styles/Tooltip.css" rel="stylesheet" type="text/css" />
    <%-- <link rel="Stylesheet" href="../Scripts/AutoComplete/jquery-ui.min.css" />--%>
    <link rel="Stylesheet" href="../Styles/CommercialPkg.css" />
    <link rel="stylesheet" href="../Scripts/MultiSelectDDL/chosen.min.css" />
    <link href="../Styles/rfq.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="../Scripts/jquery.js"></script>
    <script type="text/javascript" src="../Scripts/jquery-ui-1.8.16.custom.min.js"></script>
    <script type="text/javascript" src="../Scripts/accordian.js"></script>
    <script type="text/javascript" src="../Scripts/menu.js"></script>
    <script type="text/javascript" src="../Scripts/general.js"></script>
    <script type="text/javascript" src="../Scripts/datepicker.js"></script>
    <script type="text/javascript" src="../Scripts/common.js"></script>
    <script type="text/javascript" src="../Scripts/tooltipscript.js"></script>
    <script type="text/javascript" src="../Scripts/Core.js"></script>
    <script type="text/javascript" src="../Scripts/jquery-latest.min.js"></script>
    <script type="text/javascript" src="../Scripts/AutoComplete/jquery-ui.min.js"></script>
    <link rel="Stylesheet" href="../Scripts/AutoComplete/jquery-ui.css" />
    <style type="text/css">
    *
    {
    margin: 0;
    padding: 0;
    }
    .width
    {
    border: 0px solid #b5b5b5;
    width: 200%;
    }
    .RadMenu_Default A.rmSelected, .RadMenu_Default A.rmLink, .RadMenu_Default A.rmFocused, .RadMenu_Default A.rmLink:hover, .RadMenu_Default .rmVertical .rmText
    {
    background-color: white !important;
    background: none !important;
    color: Black !important;
    font-size: 10 !important;
    }
    .textEntry
    {
    }
    .evalQHeader
    {
    height: 25px;
    font-weight: bold;
    color: Black;
    font-size: 12px;
    font-family: Arial;
    font: bold 14px;
    background: url(../images/acc-header.jpg) repeat-x;
    border: 1px solid #b5b5b5;
    border-collapse: collapse;
    text-align: center;
    }
    /* .evalPackage, .th, .td
    {
    width: 100% !important;
    border: 1px solid #b5b5b5;
    border-collapse: collapse;
    color: Gray !important;
    }*/
    .evalPackage, .td
    {
    width: 100% !important;
    border: 1px solid #b5b5b5;
    border-collapse: collapse;
    color: Gray !important;
    }
    .label
    {
    font-family: Arial;
    font-size: 11px;
    font-weight: bold;
    color: #5e5e5e;
    text-align: left;
    padding-right: 0px;
    }
    body
    {
    font: 11px/1.5 Arial,Verdana, Helvetica, sans-serif;
    background: #FFF;
    }
    #text
    {
    margin: 50px auto;
    width: 500px;
    }
    .RighAlighBudgetamount
    {
    text-align: right;
    }
    .hotspot
    {
    color: #900;
    padding-bottom: 1px;
    border-bottom: 1px dotted #900;
    }

    #tt
    {
    position: absolute;
    display: block;
    background: url(../images/tt_left.gif) top left no-repeat;
    }
    #tttop
    {
    display: block;
    height: 5px;
    margin-left: 5px;
    background: url(../images/tt_top.gif) top right no-repeat;
    overflow: hidden;
    }
    #ttcont
    {
    display: block;
    padding: 2px 12px 3px 7px;
    margin-left: 5px;
    background: #666;
    color: #FFF;
    }
    #ttbot
    {
    display: block;
    height: 5px;
    margin-left: 5px;
    background: url(../images/tt_bottom.gif) top right no-repeat;
    overflow: hidden;
    }
    .gridview1
    {
    white-space: normal;
    }
    .gridview1 TD
    {
    white-space: normal;
    }
    .RadPicker
    {
    width: 190px !important;
    }
    .radiobuttonlist
    {
    font-family: Arial;
    font-size: 12px;
    font-weight: bold;
    color: #5e5e5e;
    }
    .textcolRightAlignment
    {
    text-align: right !important;
    }

    .radiobuttonlist label
    {
    padding-top: 5px;
    padding-right: 10px;
    padding-left: 1px;
    margin: 0px 0px 0px 0px;
    white-space: nowrap;
    }
    div.RadPanelBar
    {
    width: 100% !important;
    height: 100% !important;
    line-height: 100% !important;
    border: 0px !important;
    margin-top: 1% !important;
    }
    .rpItem
    {
    overflow: visible !important;
    padding: 0 !important;
    }
    .gridview
    {
    font-family: Arial;
    font-size: 12px;
    white-space: nowrap;
    color: gray;
    background: #FFFFFF;
    border-top: 1px solid #969696;
    border-left: 1px solid #969696;
    width: 70%;
    margin: 0px 0px 0px 0px;
    }
    .RadWindow .rwPopupButton
    {
    margin-left: 80px !important;
    }
    .table
    {
    font-family: Arial;
    font-size: 12px;
    white-space: nowrap;
    color: gray;
    background: #FFFFFF;
    border-top: 1px solid #969696;
    border-left: 1px solid #969696;
    width: 30%;
    margin: 0px 0px 0px 0px;
    }
    .tableHeading
    {
    background: url(../images/header.jpg) repeat-x top;
    height: 24px;
    font-weight: bold;
    padding: 3px 0px 0px 3px;
    text-align: center !important;
    font-family: Arial !important;
    font-size: 12px !important;
    }
    .orderText
    {
    font: normal 12px Arial,Verdana;
    margin-top: 6px;
    }

    .ui-autocomplete
    {
    max-height: 100px;
    overflow-y: auto; /* prevent horizontal scrollbar */
    overflow-x: hidden;
    }
    * html .ui-autocomplete
    {
    height: 100px;
    }
    </style>
    <script type="text/javascript">
    var showpopup = 1;
    function PreviewCommercialPkg(RFQTemplateID, rfqID, MaintenanceYrs, splitItmIds) {
    if (showpopup == 1) {
    showpopup = 0;
    var maintYears = document.getElementById("txtMaintYears").value;
    window.radopen("CommercialPackage-GP.aspx?RFQTemplateID=" + RFQTemplateID + "&RFQID=" + rfqID + "&MaintenanceYrs=" + maintYears + "&splitItemIds=" + splitItmIds, "rwCommercialPkgPreviewDialog", 1000, 600);
    return false;
    }
    }
    //used to set the showpopup variable to 1. If the showpopup is 1, popup will be shown. else it will not be.
    //Desc: PreviewCommercialPkg is called by using add_load method from code-behind. This will be trigger by sync and async postbacks. To overcome tat, we are using the global variable.
    function setOpenPup() {
    showpopup = 1;
    }
    function ShowHistory(rfqID) {
    window.radopen("RFQWorkflow.aspx?RFQID=" + rfqID, "rwApprovalHistDialog");
    return false;
    }

    function ShowApprove(rfqID) {
    var oWindow = window.radopen("RFQApproval.aspx?RFQID=" + rfqID, "rwApproveDialog");
    oWindow.add_close(OnClientcloseApproval);
    return false;
    }

    function ShowExtend(rfqID) {
    var oWindow = window.radopen("RFQExtend.aspx?RFQID=" + rfqID, "rwExtendDialog");
    oWindow.add_close(OnClientclose);
    return false;
    }

    function ShowClose(rfqID) {
    var oWindow = window.radopen("RFQClose.aspx?RFQID=" + rfqID, "rwCloseDialog");
    oWindow.add_close(OnClientCloser);
    return false;
    }

    function ShowCancel(rfqID) {
    var oWindow = window.radopen("RFQCancel.aspx?RFQID=" + rfqID, "rwCancelDialog");
    oWindow.add_close(OnClientCloser);
    return false;
    }


    function ShowAction(rfqID, recmndUsr, ForwardedBy, isDelegateRequest, delegatorID) {
    var oWindow = window.radopen("/REQU/RequAction.aspx?RFQID=" + rfqID + "&RecmndUser=" + recmndUsr + "&ForwardedBy=" + ForwardedBy + "&IsDelgtdReq=" + isDelegateRequest + "&DelegatorID=" + delegatorID, "rwActionDialog", 730, 500);
    oWindow.add_close(OnClientcloseApproval);
    return false;
    }
    function ShowCoomercialEvaluation(RFI_ID, strMODE, BuyerRFQID, totrooms, servtype, UOM, C_Commited, O_Overlap, A_Additional, C_Contract, O_OprWeek) {

    var Commited = null;
    var Overlap = null;
    var Additional = null;
    var OprWeek = null;
    if (document.getElementById(C_Commited) != null && document.getElementById(C_Commited).value != null) {
    Commited = document.getElementById(C_Commited).value;
    }
    else {
    C_Commited = 0;
    }
    if (document.getElementById(O_Overlap) != null && document.getElementById(O_Overlap).value != null) {
    Overlap = document.getElementById(O_Overlap).value;
    }
    else {
    Overlap = 0;
    }

    if (document.getElementById(O_OprWeek) != null && document.getElementById(O_OprWeek).value != null) {
    OprWeek = document.getElementById(O_OprWeek).value;
    }
    else {
    OprWeek = 0;
    }
    var Contract = document.getElementById(C_Contract).value;
    if (RFI_ID > 0)
    //var url = "../RFQ/HOTAC/CommercialEvaluation.aspx?RFXID=" + RFI_ID + "&EvalTypeID=1&ModuleID=1&ReqTypeID=2&LoginType=Supplier&ViewMode=" + strMODE + "&suppID=" + suppID + "&responseID=" + QuoteID;
    var url = "../RFQ/HOTAC/CommercialEvaluation.aspx?RFXID=" + RFI_ID + "&EvalTypeID=1&ModuleID=1&ReqTypeID=2&LoginType=Supplier&ViewMode=" + strMODE + "&BuyerRFQ=" + BuyerRFQID + "&TotRooms=" + totrooms + "&ServType=" + servtype + "&UOM=" + UOM + "&Commited=" + Commited + "&Overlap=" + Overlap + "&Additional=" + Additional + "&Contract=" + Contract + "&OprWeek=" + OprWeek;
    else
    //var url = "../RFQ/HOTAC/CommercialEvaluation.aspx?RFXID=0&EvalTypeID=1&ModuleID=1&ReqTypeID=2&LoginType=Buyer&ViewMode=" + strMODE;
    var url = "../RFQ/HOTAC/CommercialEvaluation.aspx?RFXID=0&EvalTypeID=1&ModuleID=1&ReqTypeID=2&LoginType=Buyer&ViewMode=" + strMODE + "&BuyerRFQ=" + BuyerRFQID + "&TotRooms=" + totrooms + "&ServType=" + servtype + "&UOM=" + UOM + "&Commited=" + Commited + "&Overlap=" + Overlap + "&Additional=" + Additional + "&Contract=" + Contract + "&OprWeek=" + OprWeek;

    parent.OpenRadWindow(url, "Commercial Package", 1600, 850);

    }

    function OnClientCloser(sender, eventArgs) {
    var arg = eventArgs.get_argument();
    if (arg == 1) {
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGsuccess";
    document.getElementById("lblStatus").style.color = "green";
    document.getElementById("lblStatus").innerHTML = "RFQ Closed Successfully.";
    document.getElementById("img").src = "../Images/tick.png";
    document.getElementById("lnkclose").style.display = "none";
    document.getElementById("lnkcancel").style.display = "none";
    document.getElementById("lnkextend").style.display = "none";
    document.getElementById("lnkCreateCircular").style.display = "none";
    }
    else if (arg == 2) {
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("img");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "RFQ Closure failed.";
    }
    else if (arg == 0) {
    document.getElementById("lnkclose").style.display = "none";
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGsuccess";
    document.getElementById("lblStatus").style.color = "green";
    document.getElementById("lblStatus").innerHTML = "RFQ Cancelled Successfully.";
    document.getElementById("img").src = "../Images/tick.png";
    document.getElementById("lnkcancel").style.display = "none";
    document.getElementById("lnkextend").style.display = "none";

    }
    // else {
    // document.getElementById("errorbg").className = "ESGinfo";
    // document.getElementById("lblStatus").style.color = "#00529B";
    // document.getElementById("errorbg").style.display = "block";
    // document.getElementById("lblStatus").innerHTML = "RFQ Not Closed/Cancelled.";
    // document.getElementById("img").src = "../Images/error.png";
    // }
    }


    function OnClientclose(sender, eventArgs) {
    var arg = eventArgs.get_argument();
    if (arg) {

    if (sender._focusedPageElement.id == 'lnkclose') {
    document.getElementById("lnkclose").style.display = "none";
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGsuccess";
    document.getElementById("lblStatus").style.color = "green";
    document.getElementById("lnkCreateCircular").style.display = "none";
    document.getElementById("lblStatus").innerHTML = "RFQ Closed Successfully.";
    }
    else if (sender._focusedPageElement.id == 'lnkcancel') {
    document.getElementById("lnkcancel").style.display = "none";
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGsuccess";
    document.getElementById("lblStatus").style.color = "green";
    document.getElementById("lblStatus").innerHTML = "RFQ Cancelled Successfully.";
    }
    else if (sender._focusedPageElement.id == 'lnkextend') {
    document.getElementById("lnkextend").style.display = "none";
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGsuccess";
    document.getElementById("lblStatus").style.color = "green";
    document.getElementById("lblStatus").innerHTML = "RFQ Extended Successfully.";
    }
    else if (sender._focusedPageElement.id == 'lnkRevisionGrid') {
    document.getElementById("lnkRevisionGrid").style.display = "none";
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGsuccess";
    document.getElementById("lblStatus").style.color = "green";
    document.getElementById("lblStatus").innerHTML = "RFQ Initiated for Revision Successfully.";
    }
    }
    }
    function HideButton() {
    if (document.getElementById("lnkSubmit") != null)
    document.getElementById("lnkSubmit").style.display = "none";
    if (document.getElementById("lnkTopSubmit") != null)
    document.getElementById("lnkTopSubmit").style.display = "none";


    if (document.getElementById("lbtAction") != null)
    document.getElementById("lbtAction").style.display = "none";
    }
    function updateDates(opendate, closedate) {
    var tmarr = opendate.split('/');
    var timstamp = tmarr[2].substring(4).split(':');
    var dt = new Date(tmarr[2].substring(0, 4), tmarr[1] - 1, tmarr[0], timstamp[0], timstamp[1], timstamp[2]);
    RadOpenDate.set_selectedDate(dt);
    tmarr = closedate.split('/');
    timstamp = tmarr[2].substring(4).split(':');
    dt = new Date(tmarr[2].substring(0, 4), tmarr[1] - 1, tmarr[0], timstamp[0], timstamp[1], timstamp[2]);
    RadCloseDate.set_selectedDate(dt);
    }
    function OnClientcloseApproval(sender, eventArgs) {
    var arg = eventArgs.get_argument();
    var arg = eventArgs.get_argument();
    if (arg == 1) {
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGsuccess";
    document.getElementById("lblStatus").style.color = "green";
    document.getElementById("lblStatus").innerHTML = "RFQ Approved Successfully.";
    document.getElementById("img").src = "../Images/tick.png";
    HideButton();
    }
    else if (arg == 0) {
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGsuccess";
    document.getElementById("lblStatus").style.color = "green";
    document.getElementById("lblStatus").innerHTML = "RFQ Rejected.";
    document.getElementById("img").src = "../Images/tick.png";
    HideButton();
    }
    else if (arg == 2) {
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGinfo";
    document.getElementById("lblStatus").style.color = "#00529B";
    document.getElementById("img").src = "../Images/more_info.png";
    document.getElementById("lblStatus").innerHTML = "RFQ has been requested for further clarification.";
    HideButton();
    }
    else if (arg == 3) {
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGinfo";
    document.getElementById("lblStatus").style.color = "#00529B";
    document.getElementById("img").src = "../Images/more_info.png";
    document.getElementById("lblStatus").innerHTML = "RFQ has been reassigned to the buyer for further action.";
    HideButton();
    }
    else if (arg == 6) {
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGsuccess";
    document.getElementById("lblStatus").style.color = "green";
    document.getElementById("lblStatus").innerHTML = "Request Forwarded Successfully.";
    document.getElementById("img").src = "../Images/tick.png";
    HideButton();
    }
    else if (arg == 7) {
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGsuccess";
    document.getElementById("lblStatus").style.color = "green";
    document.getElementById("lblStatus").innerHTML = "RFQ Recommended successfully.";
    document.getElementById("img").src = "../Images/tick.png";
    HideButton();
    }
    else if (arg == 8) {
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGinfo";
    document.getElementById("lblStatus").style.color = "#00529B";
    document.getElementById("lblStatus").innerHTML = "Request Delegated Successfully.";
    document.getElementById("img").src = "../Images/more_info.png";
    HideButton();
    }
    else if (arg == 9) {
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGinfo";
    document.getElementById("lblStatus").style.color = "#00529B";
    document.getElementById("lblStatus").innerHTML = "Requested for more information.";
    document.getElementById("img").src = "../Images/more_info.png";
    HideButton();
    }
    else if (arg == 10) {
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGsuccess";
    document.getElementById("lblStatus").style.color = "green";
    document.getElementById("lblStatus").innerHTML = "Revised RFQ Approved and Published Successfully.";
    document.getElementById("img").src = "../Images/tick.png";
    HideButton();
    }
    else if (arg == 100) {
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGsuccess";
    document.getElementById("lblStatus").style.color = "green";
    document.getElementById("lblStatus").innerHTML = "RFQ Approved and Published Successfully.";
    document.getElementById("img").src = "../Images/tick.png";
    HideButton();
    }
    else if (arg == 110) {
    //location.reload();
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGsuccess";
    document.getElementById("lblStatus").style.color = "green";
    document.getElementById("lblStatus").innerHTML = "Auto Renewal RFQ Approved and Awarded to the Supplier Successfully.";
    document.getElementById("img").src = "../Images/tick.png";
    HideButton();
    }
    //ControlSection Date Validation++++++++++++++++++++++
    else if (arg == 101) {
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("img");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Open date and time should be greater than Today date and time.";
    }
    else if (arg == 102) {
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("img");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Award date and time should be greater than Closing date and time.";
    }
    else if (arg == 103) {
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("img");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Closing date and time should be greater than Opening date and time.";
    }
    // if (arg != null) {
    // document.getElementById("lbtAction").style.display = "none";
    // }
    }

    function ShowContractPopup(rfqID, rfqTypeID, penqID) {
    var currentWindow = window.radopen("/RFQ/RFQContractTermsCondn.aspx?RFQID=" + rfqID + "&IsBuyer=Y&Action=ATTADD&rfqTypeID=" + rfqTypeID + "&PENQID=" + penqID, null, 900, 450);
    currentWindow.set_showContentDuringLoad(false);
    currentWindow.set_modal(true);
    currentWindow.set_behaviors(Telerik.Web.UI.WindowBehaviors.Close + Telerik.Web.UI.WindowBehaviors.Maximize);
    currentWindow.set_reloadOnShow(true);
    currentWindow.set_visibleStatusbar(false);
    currentWindow.set_title('Contract Terms and Conditions Attachments');
    currentWindow.set_visibleTitlebar(true);
    return false;
    }

    function ShowSupplierQuestionnairePopup() {
    var url = "RFQ/SupplierQuestionnaire.aspx?openerID=RFQ&HasSubmitComments=&RFQID=&SupplierID=&rfqStatus=";
    parent.OpenRadMenugridWindow(url, "Supplier Questionnaire", 1200, 750); // Args : {URL, Title, Height, Width}
    //parent.addtab('Audit', url);
    return false;
    }

    // function ShowContractPopup(rfqID) {
    // window.radopen("/RFQ/RFQContractTermsCondn.aspx?RFQID=" + rfqID + "&IsBuyer=Y&Action=ATTADD", "radWinContract");
    // return false;
    // }

    $(document).ready(function () {

    var successMsgAvailable = unescape(window.location.search.replace(new RegExp("^(?:.*[&\\?]" + escape("ShowSubmitSuccessMsg").replace(/[\.\+\*]/g, "\\$&") + "(?:\\=([^&]*))?)?.*$", "i"), "$1"));
    if (successMsgAvailable == "true") {
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGsuccess";
    document.getElementById("lblStatus").style.color = "green";
    document.getElementById("img").src = "../Images/tick.png";
    document.getElementById("lblStatus").innerHTML = "RFQ saved successfully.";
    }

    if ($("#hdnIsADelegateRequest").val() == "True") {
    $('#divCommPkg :input').attr('disabled', true);
    $('#divCommPkg a#idatt').attr('style', 'display: none');
    $('#divCommPkg a.button').attr('style', 'display: none');
    $('#divCommPkg a.riUp').attr('style', 'display: none');
    $('#divCommPkg a.riDown').attr('style', 'display: none');
    $('#divCommPkg img').attr('style', 'display: none');
    $('#divCommPkg input[type = "image"]').attr('style', 'display: none');
    }
    });
    </script>
    </head>
    <body>
    <form id="Form1" runat="server" enctype="multipart/form-data">
    <telerik:RadScriptManager ID="ScriptManager" runat="server" />
    <telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
    <script type="text/javascript">
    function ChkDDL(id) {
    var combo = $find(id);
    if (combo.get_selectedItem() == null) {
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("<%=img.ClientID%>");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Please select Approver from list";
    return false;
    }
    return true;
    }
    //For New changes of Surrogate Bid
    function hideApprover(chkBox) {

    var Combotext = document.getElementById('<%=ucRFQInfoRFQ.rdoRFQType.ClientID%>');

    if (Combotext.value == "Catering RFQ") {

    if (chkBox.checked) {
    var grd = document.getElementById("<%=pnlCollaboration.ClientID%>");
    grd.style.display = 'none';
    }
    else {
    var grd = document.getElementById("<%=pnlCollaboration.ClientID%>");
    grd.style.display = '';
    }
    }

    }
    //
    function ShowSupplier() {
    var rfqType = $('#<%=hdnRFQType.ClientID %>').val();
    var hdnRFQId = $('#<%=hdnrfqID.ClientID %>').val();
    var hdPurEnqIds = $('#<%=hdPurEnqIds.ClientID %>').val();
    if (rfqType == 3 && hdnRFQId == 0) {//Esourcing-3
    window.radopen("ViewSearchSupplier.aspx?PurEnqIds=" + document.getElementById("hdPurEnqIds").value + "&RFQId=" + document.getElementById("hdnrfqID").value + "&RFQTypeId=" + document.getElementById("hdnRFQType").value, "UserListDialog");
    return false;
    }
    else {
    window.radopen("ViewSearchSupplier.aspx", "UserListDialog");
    return false;
    }

    }

    function ValidateControls() {
    try {

    var returnValue = Boolean(true);
    //start Commercial Package Appendix-B (General Procumrement RFQ)
    if ($("#<%=hdnRFQType.ClientID %>").val() == '3') {
    saveTemplate(); //Save
    // returnValue = validateItemDtls(); //validate item details base on Buyer and Supplier login
    }
    //end Commercial Package Appendix-B

    if (returnValue) {

    var Opendate = new Date(RadOpenDate.get_selectedDate()).toUTCString();
    var Closedate = new Date(RadCloseDate.get_selectedDate()).toUTCString();
    var Awarddate = new Date(RadAwardDate.get_selectedDate()).toUTCString();

    var Currdate1 = new Date();
    var Currdate = new Date();
    var Chkdate = new Date().format();
    Currdate = Currdate1.setMinutes(Currdate.getMinutes() + 30);


    if (Date.parse(Chkdate) >= Date.parse(Opendate)) {
    $("#errorbg").addClass("ESGerror");
    $("#errorbg").show();
    $("#errorbg").css("color", "Red");
    $("#img").show();
    $("#img").attr("src", "../Images/error.png");
    $("#lblStatus").text("Open date and time should be greater than Today date and time");
    return false;
    }


    if (Date.parse(Closedate) > Date.parse(Opendate)) {
    if (Date.parse(Awarddate) > Date.parse(Closedate)) {
    return true;
    }
    else {
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("<%=img.ClientID%>");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Award date and time should be greater than Closing date and time";
    return false;
    }
    }
    else {
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("<%=img.ClientID%>");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Closing date and time should be greater than Opening date and time";
    return false;
    }

    }
    } catch (e) {
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("<%=img.ClientID%>");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Please check the date and time given";
    return false;
    }

    return returnValue;
    }
    function ValidateControlsPublish() {
    try {
    var Opendate = new Date(RadOpenDate.get_selectedDate()).toUTCString();
    var Closedate = new Date(RadCloseDate.get_selectedDate()).toUTCString();
    var Awarddate = new Date(RadAwardDate.get_selectedDate()).toUTCString();

    var Currdate1 = new Date();
    var Currdate = new Date();
    var Chkdate = new Date().format();
    Currdate = Currdate1.setMinutes(Currdate.getMinutes() + 30);

    // if (Date.parse(Chkdate) >= Date.parse(Opendate)) {
    // //if (Date.parse(Prevdate) <= Date.parse(Chkdate)) {
    // document.getElementById('errorbg').className = 'ESGerror';
    // document.getElementById("errorbg").style.display = "block";
    // document.getElementById("lblStatus").style.color = "Red";
    // document.getElementById("img").style.visibility = "visible";
    // var img = document.getElementById("<%=img.ClientID%>");
    // img.src = "../Images/error.png";
    // document.getElementById("lblStatus").innerHTML = "Open date and time should be greater than Today date and time";
    // radPreviewDate.set_selectedDate(Currdate1);
    // return false;
    // }

    if (Date.parse(Closedate) > Date.parse(Opendate)) {
    if (Date.parse(Awarddate) > Date.parse(Closedate)) {
    return true;
    }
    else {
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("<%=img.ClientID%>");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Award date and time should be greater than Closing date and time";
    return false;
    }
    }
    else {
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("<%=img.ClientID%>");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Closing date and time should be greater than Opening date and time";
    return false;
    }
    }
    catch (e) {
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("<%=img.ClientID%>");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Please check the date and time given";
    return false;
    }
    }
    function NewKeyPress(sender, args) {
    var keyCharacter = args.get_keyCharacter();
    if (keyCharacter == sender.get_numberFormat().NegativeSign) {
    args.set_cancel(true);
    }
    }
    function NewKeyPressWeightage(sender, args) {
    var keyCharacter = args.get_keyCharacter();
    if (keyCharacter == sender.get_numberFormat().NegativeSign || keyCharacter == sender.get_numberFormat().DecimalSeparator) {
    args.set_cancel(true);
    }
    }
    function mealgridview(mealname, station, value, classval, mealitem, BDMCode) {
    var url = "RFQ/QMenuGrid.aspx?MealName=" + mealname + "&Station=" + station + "&Value=" + value + "&Class=" + classval + "&MealItem=" + mealitem + "&IsUpdateRFQ=N&IsRevised=false";
    parent.OpenRadMenugridWindow(url, classval + ' - ' + mealname + ' (' + BDMCode + ')', 1600, 750);
    return false;
    }

    function OpenViewFlightDetails() {
    if (document.getElementById('<%=ucStation.HdnStationId.ClientID%>').value != null) {
    if (document.getElementById("hdnrfqID").value != null)
    window.radopen("ViewFlightDetails.aspx?StationID=" + document.getElementById('<%=ucStation.HdnStationId.ClientID%>').value + "&rfqID=" + document.getElementById("hdnrfqID").value, "ViewFlightDetailsDialog");
    else
    window.radopen("ViewFlightDetails.aspx?StationID=" + document.getElementById('<%=ucStation.HdnStationId.ClientID%>').value + "&rfqID=", "ViewFlightDetailsDialog");
    return false;
    }
    }

    function OpenViewBudgetDetails() {
    if (document.getElementById('<%=ucStation.HdnStationId.ClientID%>').value != null) {
    if (document.getElementById("hdnrfqID").value != null)
    window.radopen("ViewBudgetDetails.aspx?StationID=" + document.getElementById('<%=ucStation.HdnStationId.ClientID%>').value + "&rfqID=" + document.getElementById("hdnrfqID").value, "rwViewBudgetDetailsDialog");
    else
    window.radopen("ViewBudgetDetails.aspx?StationID=" + document.getElementById('<%=ucStation.HdnStationId.ClientID%>').value + "&rfqID=", "rwViewBudgetDetailsDialog");
    return false;
    }
    }
    function OpenReturnMenuGrid() {
    //alert(document.getElementById('<%=ucInvSupplrs.RadWinMenuGridReturn.ClientID%>'));
    if (document.getElementById('<%=ucStation.HdnStationId.ClientID%>').value != null) {
    var oWindow = window.radopen("ReturnMenuGrid.aspx?StationID=" + document.getElementById('<%=ucStation.HdnStationId.ClientID%>').value, document.getElementById('<%=ucInvSupplrs.RadWinMenuGridReturn.ClientID%>'));
    oWindow.add_close(OnClientcloseRFQReturn);
    }
    else
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("<%=img.ClientID%>");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Please select a Catering Station";
    return false;
    }
    function OnClientcloseRFQReturn(sender, eventArgs) {
    var arg = eventArgs.get_argument();
    if (arg == 1) {
    radalert("<center>Station Menu Grid is returned successfully!</center>", "350", "150", "Return Menu Grid", callBackFn, null);
    }
    else
    radalert("<font color='Red'>Station Menu Grid is not returned!</font>", "350", "150", "Return Menu Grid", null, null);
    }
    function callBackFn(arg) {
    document.location.reload();
    }

    function ShowRFQStatusPage() {
    // var oWindow = window.radopen("RFQStatusPage.aspx", "rwRFQList");
    parent.OpenRadMenugridWindow("RFQ/RFQStatusPage.aspx", "RFQ List", 1600, 750);
    // oWindow.add_close(OnClientclose);
    return false;
    }

    function OnClientclose(sender, eventArgs) {
    var arg = eventArgs.get_argument();
    if (arg) {
    document.getElementById("hdpreserve").value = "1";
    if (sender._name == 'rwExtendDialog') {
    document.getElementById("lnkextend").style.display = "none";
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("errorbg").className = "ESGsuccess";
    document.getElementById("lblStatus").style.color = "green";
    document.getElementById("img").src = "../Images/tick.png";
    document.getElementById("lblStatus").innerHTML = "RFQ Extended Successfully.";
    }
    }
    }

    function ShowTechnicalEvaluation(RFQ_ID, ViewMode, categoryId, subcategoryId) {
    var rfqType = $('#<%=hdnRFQType.ClientID %>').val();
    if (rfqType == 3) {//Esourcing-3
    if (RFQ_ID > 0)
    var url = "../Evaluation/TechnicalEvaluation.aspx?RFXID=" + RFQ_ID + "&EvalTypeID=1&ModuleID=2&ReqTypeID=1&LoginType=Buyer&ViewMode=" + ViewMode + "&catId=" + categoryId + "&subcatId=" + subcategoryId;
    else
    var url = "../Evaluation/TechnicalEvaluation.aspx?RFXID=0&EvalTypeID=1&ModuleID=2&ReqTypeID=1&LoginType=Buyer&ViewMode=" + ViewMode + "&catId=" + categoryId + "&subcatId=" + subcategoryId;
    }
    else {
    if (RFQ_ID > 0)
    var url = "../Evaluation/TechnicalEvaluation.aspx?RFXID=" + RFQ_ID + "&EvalTypeID=1&ModuleID=1&ReqTypeID=1&LoginType=Buyer&ViewMode=" + ViewMode;
    else
    var url = "../Evaluation/TechnicalEvaluation.aspx?RFXID=0&EvalTypeID=1&ModuleID=1&ReqTypeID=1&LoginType=Buyer&ViewMode=" + ViewMode;
    }

    //parent.OpenRadWindow(url, "Technical Package", 1000, 700);

    var currentWindow = window.radopen(url, null, 1000, 700);
    currentWindow.set_showContentDuringLoad(false);
    currentWindow.set_modal(true);
    currentWindow.set_behaviors(Telerik.Web.UI.WindowBehaviors.Close + Telerik.Web.UI.WindowBehaviors.Maximize);
    currentWindow.set_reloadOnShow(true);
    currentWindow.set_visibleStatusbar(false);
    currentWindow.set_title('Technical Package');
    currentWindow.set_visibleTitlebar(true);
    return false;
    }
    //Added By:Sumit, For technical evaluation RFQ.
    function ShowTechnicalEvaluRFQ(RFQ_ID, ViewMode) {
    if (RFQ_ID > 0)
    var url = "../Evaluation/TechnicalEvaluation.aspx?RFXID=" + RFQ_ID + "&EvalTypeID=1&ModuleID=2&ReqTypeID=1&LoginType=Buyer&ViewMode=" + ViewMode;
    else
    var url = "../Evaluation/TechnicalEvaluation.aspx?RFXID=0&EvalTypeID=1&ModuleID=2&ReqTypeID=1&LoginType=Buyer&ViewMode=" + ViewMode;

    //parent.OpenRadWindow(url, "Technical Evaluation", 1000, 700);
    var currentWindow = window.radopen(url, null, 1000, 700);
    currentWindow.set_showContentDuringLoad(false);
    currentWindow.set_modal(true);
    currentWindow.set_behaviors(Telerik.Web.UI.WindowBehaviors.Close + Telerik.Web.UI.WindowBehaviors.Maximize);
    currentWindow.set_reloadOnShow(true);
    currentWindow.set_visibleStatusbar(false);
    currentWindow.set_title('Technical Package');
    currentWindow.set_visibleTitlebar(true);
    return false;
    }

    function sumWeightage() {
    var technicalWght = 0;
    var commercialWght = 0;
    var contractWght = 0;
    if (document.getElementById('txtTechtWeightage') != null && document.getElementById('txtTechtWeightage').value != null && !isNaN(parseFloat(document.getElementById('txtTechtWeightage').value)))
    technicalWght = parseFloat(document.getElementById('txtTechtWeightage').value);
    if (document.getElementById('txtCommWeightage') != null && document.getElementById('txtCommWeightage').value != null && !isNaN(parseFloat(document.getElementById('txtCommWeightage').value)))
    commercialWght = parseFloat(document.getElementById('txtCommWeightage').value);
    if (document.getElementById('txtContractWeightage') != null && document.getElementById('txtContractWeightage').value != null && !isNaN(parseFloat(document.getElementById('txtContractWeightage').value)))
    contractWght = parseFloat(document.getElementById('txtContractWeightage').value);

    var total = technicalWght + commercialWght + contractWght;

    total = Number(total);
    if (document.getElementById('txtWeightageTotal') != null)
    document.getElementById('txtWeightageTotal').value = total;
    }

    /*function ShowFlightDetails(ReqId, Station) {
    var url = "../RFQ/HOTAC/FlightPatternDisplay.aspx?ReqId=" + ReqId + "&Station=" + Station;
    parent.OpenRadWindow(url, "Flight Details", 1500, 800);
    }*/

    function ShowFlightDetails(ReqId, Station, RfqRevNo) {
    var url = "../RFQ/HOTAC/FlightPatternDisplay.aspx?ReqId=" + ReqId + "&Station=" + Station + "&RFQRevNo=" + RfqRevNo;
    parent.OpenRadWindow(url, "Flight Details", 1600, 800);
    }

    function OnRequestStart(target, arguments) {
    if (arguments.get_eventTarget().indexOf("lnkInternalDocAdd") > -1) {
    arguments.set_enableAjax(false);
    }
    else if (arguments.get_eventTarget().indexOf("lnkAddAttachment") > -1) {
    arguments.set_enableAjax(false);
    }
    else if (arguments.get_eventTarget().indexOf("grdInternalApproval") > -1) {
    arguments.set_enableAjax(false);
    }
    else if (arguments.get_eventTarget().indexOf("grdAttachment") > -1) {
    arguments.set_enableAjax(false);
    }
    else if (arguments.get_eventTarget().indexOf("lnkExportToExcel") > -1) {
    arguments.set_enableAjax(false);
    }
    else if (arguments.get_eventTarget().indexOf("ddlpro") > -1) {
    arguments.set_enableAjax(false);
    }
    else if (arguments.get_eventTarget().indexOf("btnweightage") > -1) {
    arguments.set_enableAjax(false);
    }
    else if (arguments.get_eventTarget().indexOf("lnkAddItem") > -1) {
    arguments.set_enableAjax(false);
    }
    else if (arguments.get_eventTarget().indexOf("btnlineattach") > -1) {
    arguments.set_enableAjax(false);
    }
    else if (arguments.get_eventTarget().indexOf("lnkAutoRenewalInternalDocAdd") > -1) {
    arguments.set_enableAjax(false);
    }
    else if (arguments.get_eventTarget().indexOf("grdAutoRenewalInternalApproval") > -1) {
    arguments.set_enableAjax(false);
    }
    }

    //<![CDATA[
    var radPreviewDate;
    var RadOpenDate;
    var RadCloseDate;
    var RadAwardDate;
    function validate1(sender, args) {
    var Prevdate = new Date(radPreviewDate.get_selectedDate()).format();
    var Currdate1 = new Date();
    var Currdate = new Date();
    var Chkdate = new Date().format();
    Currdate = Currdate1.setMinutes(Currdate.getMinutes() + 30);
    //Currdate = Currdate1.setDate(Currdate.getDate() + 1);

    args.IsValid = true;
    if (Date.parse(Chkdate) >= Date.parse(Prevdate)) {
    //if (Date.parse(Prevdate) <= Date.parse(Chkdate)) {
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("<%=img.ClientID%>");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Preview date and time should be greater than Today date and time";
    radPreviewDate.set_selectedDate(Currdate1);
    args.IsValid = false;
    }
    }
    function validate2(sender, args) {
    var Opendate = new Date(RadOpenDate.get_selectedDate()).format();
    var Prevdate = new Date(radPreviewDate.get_selectedDate()).format();
    var Currdate = new Date().format();
    args.IsValid = true;
    if (Date.parse(Prevdate) >= Date.parse(Opendate)) {
    //if (Date.parse(Opendate) <= Date.parse(Prevdate)){
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("<%=img.ClientID%>");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Opening date and time should be greater than Preview date and time";
    //RadOpenDate.set_selectedDate(radPreviewDate.get_selectedDate());
    args.IsValid = false;
    }
    }
    function validate3(sender, args) {
    var Closedate = new Date(RadCloseDate.get_selectedDate()).format();
    var Opendate = new Date(RadOpenDate.get_selectedDate()).format();
    var Prevdate = new Date(radPreviewDate.get_selectedDate()).format();
    args.IsValid = true;
    if (Date.parse(Prevdate) >= Date.parse(Opendate)) {
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("<%=img.ClientID%>");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Opening date and time should be greater than Preview date and time";
    args.IsValid = false;
    }
    var Currdate = new Date().format();
    if (Date.parse(Opendate) >= Date.parse(Closedate)) {
    //if (Date.parse(Closedate) <= Date.parse(Opendate)){
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("<%=img.ClientID%>");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Closing date and time should be greater than Opening date and time";
    //RadCloseDate.set_selectedDate(RadOpenDate.get_selectedDate());
    args.IsValid = false;
    }
    }
    function validate4(sender, args) {
    var Awarddate = new Date(RadAwardDate.get_selectedDate()).format();
    var Closedate = new Date(RadCloseDate.get_selectedDate()).format();
    var Opendate = new Date(RadOpenDate.get_selectedDate()).format();
    //var Prevdate = new Date(radPreviewDate.get_selectedDate()).format();
    var Currdate = new Date().format();
    args.IsValid = true;
    // if (Date.parse(Prevdate) >= Date.parse(Opendate)) {
    // document.getElementById('errorbg').className = 'ESGerror';
    // document.getElementById("errorbg").style.display = "block";
    // document.getElementById("lblStatus").style.color = "Red";
    // document.getElementById("img").style.visibility = "visible";
    // var img = document.getElementById("<%=img.ClientID%>");
    // img.src = "../Images/error.png";
    // document.getElementById("lblStatus").innerHTML = "Opening date and time should be greater than Preview date and time";
    // args.IsValid = false;
    // return;
    // }
    if (Date.parse(Opendate) >= Date.parse(Closedate)) {
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("<%=img.ClientID%>");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Closing date and time should be greater than Opening date and time";
    args.IsValid = false;
    return;
    }
    if (Date.parse(Closedate) >= Date.parse(Awarddate)) {
    //if (Date.parse(Awarddate) <= Date.parse(Closedate)) {
    document.getElementById('errorbg').className = 'ESGerror';
    document.getElementById("errorbg").style.display = "block";
    document.getElementById("lblStatus").style.color = "Red";
    document.getElementById("img").style.visibility = "visible";
    var img = document.getElementById("<%=img.ClientID%>");
    img.src = "../Images/error.png";
    document.getElementById("lblStatus").innerHTML = "Award date and time should be greater than Closing date and time";
    //RadAwardDate.set_selectedDate(RadCloseDate.get_selectedDate());
    args.IsValid = false;
    }
    }

    function onLoadRadDatePicker1(sender, args) {
    radPreviewDate = sender;
    }
    function onLoadRadDatePicker2(sender, args) {
    RadOpenDate = sender;
    }
    function onLoadRadDatePicker3(sender, args) {
    RadCloseDate = sender;
    }
    function onLoadRadDatePicker4(sender, args) {
    RadAwardDate = sender;
    }
    function refreshGrid() {
    $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("arg");
    }
    function OpenCreateCircularTab() {
    var rfqId = document.getElementById("hdnrfqID").value;
    parent.addtab('Circular Creation', '/RFQ/CreateCircular.aspx?RFQID=' + rfqId);
    }
    function numberWithCommas(x) {
    return x.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ",");
    }

    function OnBlurFreigher(sender, args) {

    var priceF = document.getElementById('<%= radFreigherP.ClientID %>').value;
    var taxF = document.getElementById('<%= radFreigherT.ClientID %>').value;
    var rateF = document.getElementById('<%= radFreigherR.ClientID %>');
    var rateC = null;
    document.getElementById('<%= radFreigherR.ClientID %>').value = null;
    var radFreigherTcmb = $find("radFreigherTcmb")._value;
    if (priceF == "" && taxF == "") {
    rateF.value = "";
    }
    else if (priceF == "") {
    rateC = parseFloat(taxF.replace(/,/g, ''));
    }
    else if (taxF == "") {
    rateC = parseFloat(priceF.replace(/,/g, ''));
    }
    else if (priceF != "" && taxF != "" && radFreigherTcmb == "Amount") {
    rateC = parseFloat(priceF.replace(/,/g, '')) + parseFloat(taxF.replace(/,/g, ''));
    }
    else if (priceF != "" && taxF != "" && radFreigherTcmb == "Percentage") {
    rateC = parseFloat(priceF.replace(/,/g, '')) + (parseFloat(priceF.replace(/,/g, '')) * parseFloat(taxF.replace(/,/g, '')) / 100);
    }
    rateF.value = numberWithCommas(rateC.toFixed(2));
    }

    //set the closing date.
    function setExtendendCloseDate(val) {
    try {
    var tmarr = val.split('/');
    var timstamp = tmarr[2].substring(4).split(':');
    var dt = new Date(tmarr[2].substring(0, 4), tmarr[1] - 1, tmarr[0], timstamp[0], timstamp[1], timstamp[2]);
    RadCloseDate.set_selectedDate(dt);
    } catch (e) {

    }
    }

    function OnBlurInsurance(sender, args) {
    var priceI = document.getElementById('<%= InsuranceP.ClientID %>').value;
    var taxI = document.getElementById('<%= InsurancT.ClientID %>').value;
    var rateI = document.getElementById('<%= InsuranceR.ClientID %>');
    var rateC = null;
    document.getElementById('<%= InsuranceR.ClientID %>').value = null;
    var InsurancTcmb = $find("InsurancTcmb")._value;
    if (priceI == "" && taxI == "") {
    rateI.value = "";
    }
    else if (priceI == "") {
    rateC = parseFloat(taxI.replace(/,/g, ''));
    }
    else if (taxI == "") {
    rateC = parseFloat(priceI.replace(/,/g, ''));
    }
    else if (priceI != "" && taxI != "" && InsurancTcmb == "Amount") {
    rateC = parseFloat(priceI.replace(/,/g, '')) + parseFloat(taxI.replace(/,/g, ''));
    }
    else if (priceI != "" && taxI != "" && InsurancTcmb == "Percentage") {
    rateC = parseFloat(priceI.replace(/,/g, '')) + (parseFloat(priceI.replace(/,/g, '')) * parseFloat(taxI.replace(/,/g, '')) / 100);
    }
    rateI.value = numberWithCommas(rateC.toFixed(2));
    }
    function OnBlurOther(sender, args) {
    var priceO = document.getElementById('<%= OthersP.ClientID %>').value;
    var taxO = document.getElementById('<%= OthersT.ClientID %>').value;
    var rateO = document.getElementById('<%= OthersR.ClientID %>');
    var rateC = null;
    document.getElementById('<%= OthersR.ClientID %>').value = null;
    var OthersTcmb = $find("OthersTcmb")._value;
    if (priceO == "" && taxO == "") {
    rateO.value = "";
    }
    else if (priceO == "") {
    rateC = parseFloat(taxO.replace(/,/g, ''));
    }
    else if (taxO.value == "") {
    rateC = parseFloat(priceO.replace(/,/g, ''));
    }
    else if (priceO != "" && taxO != "" && OthersTcmb == "Amount") {
    rateC = parseFloat(priceO.replace(/,/g, '')) + parseFloat(taxO.replace(/,/g, ''));
    }
    else if (priceO != "" && taxO != "" && OthersTcmb == "Percentage") {
    rateC = parseFloat(priceO.replace(/,/g, '')) + (parseFloat(priceO.replace(/,/g, '')) * parseFloat(taxO.replace(/,/g, '')) / 100);
    }
    rateO.value = numberWithCommas(rateC.toFixed(2));
    }

    function radFreigherTcmb_SelectedIndexChanged(sender, args) {
    var radFreigherTcmb = $find("radFreigherTcmb")._value;
    var taxV = $find("radFreigherT");
    $find("radFreigherT").clear();
    $find("radFreigherR").clear();
    if (radFreigherTcmb == "Amount") {
    $find("radFreigherT").enable();
    $find("radFreigherT")._textBoxElement.readOnly = false;
    }
    else if (radFreigherTcmb == "Percentage") {
    $find("radFreigherT").enable();
    $find("radFreigherT")._textBoxElement.readOnly = false;
    }
    else {
    $find("radFreigherT").disable();
    $find("radFreigherT")._textBoxElement.readOnly = true;
    }
    }
    function InsurancTcmb_SelectedIndexChanged(sender, args) {
    var InsurancTcmb = $find("InsurancTcmb")._value;
    var taxV = $find("InsurancT");
    $find("InsurancT").clear();
    $find("InsuranceR").clear();
    if (InsurancTcmb == "Amount") {
    $find("InsurancT").enable();
    $find("InsurancT")._textBoxElement.readOnly = false;
    }
    else if (InsurancTcmb == "Percentage") {
    $find("InsurancT").enable();
    $find("InsurancT")._textBoxElement.readOnly = false;
    }
    else {
    $find("InsurancT").disable();
    $find("InsurancT")._textBoxElement.readOnly = true;
    }
    }
    function OthersTcmb_SelectedIndexChanged(sender, args) {
    var OthersTcmb = $find("OthersTcmb")._value;
    var taxV = $find("OthersT");
    $find("OthersT").clear();
    $find("OthersR").clear();
    if (OthersTcmb == "Amount") {
    $find("OthersT").enable();
    $find("OthersT")._textBoxElement.readOnly = false;
    }
    else if (OthersTcmb == "Percentage") {
    $find("OthersT").enable();
    $find("OthersT")._textBoxElement.readOnly = false;
    }
    else {
    $find("OthersT").disable();
    $find("OthersT")._textBoxElement.readOnly = true;
    }
    }

    function cboAttachmentTypeChange(sender, eventArgs) {
    var item = eventArgs.get_item();
    if ("Commercial Appendix B" == item.get_text()) {
    var Combotext = document.getElementById('<%=ucRFQAtachmnt.txtAttachmentTitle.ClientID%>');
    Combotext.value = 'Appendix B Document';
    Combotext.disabled = true;

    }
    else {
    var Combotext = document.getElementById('<%=ucRFQAtachmnt.txtAttachmentTitle.ClientID%>');
    Combotext.value = '';
    Combotext.disabled = false;

    }

    }
    </script>
    <%-- <style type="text/css">
    .orderText
    {
    font: normal 12px Arial,Verdana;
    margin-top: 6px;
    }
    </style>--%>
    </telerik:RadCodeBlock>
    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" OnAjaxRequest="RadAjaxManager1_AjaxRequest">
    <ajaxsettings>
    <telerik:AjaxSetting AjaxControlID="lnkSaveAsDraft">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="MainTopPanal" LoadingPanelID="RadAjaxLoadingPanelRFQ" />
    </UpdatedControls>
    </telerik:AjaxSetting>
    <%-- <telerik:AjaxSetting AjaxControlID="lnkExportToExcel">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="MainTopPanal" LoadingPanelID="RadAjaxLoadingPanelRFQ" />
    </UpdatedControls>
    </telerik:AjaxSetting>--%>
    <telerik:AjaxSetting AjaxControlID="lnkSubmit">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="MainTopPanal" LoadingPanelID="RadAjaxLoadingPanelRFQ" />
    </UpdatedControls>
    </telerik:AjaxSetting>
    <telerik:AjaxSetting AjaxControlID="lnkTopSubmit">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="MainTopPanal" LoadingPanelID="RadAjaxLoadingPanelRFQ" />
    </UpdatedControls>
    </telerik:AjaxSetting>
    <telerik:AjaxSetting AjaxControlID="radlineitem">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="radOrganization" />
    <telerik:AjaxUpdatedControl ControlID="radlinecategory" />
    <telerik:AjaxUpdatedControl ControlID="radlineunitmeasure" />
    </UpdatedControls>
    </telerik:AjaxSetting>
    <telerik:AjaxSetting AjaxControlID="dllLineType">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="radlineitem" />
    <telerik:AjaxUpdatedControl ControlID="radOrganization" />
    <telerik:AjaxUpdatedControl ControlID="radlinecategory" />
    <telerik:AjaxUpdatedControl ControlID="radlineunitmeasure" />
    </UpdatedControls>
    </telerik:AjaxSetting>
    <telerik:AjaxSetting AjaxControlID="RadAjaxManager1">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="grdSupplier" />
    </UpdatedControls>
    </telerik:AjaxSetting>
    <telerik:AjaxSetting AjaxControlID="ddlRFINum">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="grdSupplier" />
    </UpdatedControls>
    </telerik:AjaxSetting>
    <telerik:AjaxSetting AjaxControlID="ddlpro">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="ddlpro" />
    <telerik:AjaxUpdatedControl ControlID="ddlcategory" />
    <telerik:AjaxUpdatedControl ControlID="grdApprovers" />
    </UpdatedControls>
    </telerik:AjaxSetting>
    <telerik:AjaxSetting AjaxControlID="dllBidType">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="cboAttachmentType" />
    </UpdatedControls>
    </telerik:AjaxSetting>
    <telerik:AjaxSetting AjaxControlID="cboAttachmentType">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="dllBidType" />
    </UpdatedControls>
    </telerik:AjaxSetting>
    <%--<telerik:AjaxSetting AjaxControlID="txttargetprice">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="chklinetargetprice" />
    </UpdatedControls>
    </telerik:AjaxSetting>--%>
    <telerik:AjaxSetting AjaxControlID="menuGridInfoTabs">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="menuGridDetailsMultiPageView" />
    </UpdatedControls>
    </telerik:AjaxSetting>
    <telerik:AjaxSetting AjaxControlID="menuGridInfoTabs">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="menuGridInfoTabs" />
    </UpdatedControls>
    </telerik:AjaxSetting>
    <telerik:AjaxSetting AjaxControlID="radStationsRFQ">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="divCatringpnl" />
    </UpdatedControls>
    </telerik:AjaxSetting>
    <telerik:AjaxSetting AjaxControlID="ddlRFINum">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="cboRequestedDept" />
    <telerik:AjaxUpdatedControl ControlID="cboSponsoringDept" />
    </UpdatedControls>
    </telerik:AjaxSetting>
    <telerik:AjaxSetting AjaxControlID="ddlReqnum">
    <UpdatedControls>
    <telerik:AjaxUpdatedControl ControlID="cboRequestedDept" />
    <telerik:AjaxUpdatedControl ControlID="cboSponsoringDept" />
    </UpdatedControls>
    </telerik:AjaxSetting>
    </ajaxsettings>
    </telerik:RadAjaxManager>
    <div class="fieldContainer" style="padding-top: 20px;">
    <telerik:RadAjaxPanel ID="MainTopPanal" runat="server" ClientEvents-OnRequestStart="OnRequestStart" LoadingPanelID="RadAjaxLoadingPanelRFQ">
    <asp:HiddenField ID="hdnTemplateID" runat="server" ClientIDMode="Static" />
    <asp:HiddenField ID="hdnOperatingUnit" runat="server" ClientIDMode="Static" />
    <asp:HiddenField ID="hdnRFQType" runat="server" ClientIDMode="Static" />
    <asp:HiddenField ID="hdnAppendixTypeID" runat="server" ClientIDMode="Static" />
    <asp:HiddenField ID="HiddenField1" runat="server" />
    <asp:HiddenField runat="server" ID="hdnRefNo" />
    <asp:HiddenField runat="server" ID="HiddenField2" />
    <asp:HiddenField runat="server" ID="hdRevision" />
    <asp:HiddenField runat="server" ID="hdpreserve" />
    <asp:HiddenField ID="hdnramdomid" runat="server" />
    <asp:HiddenField runat="server" ID="currdate" />
    <asp:HiddenField runat="server" ID="hdnrfqID" />
    <asp:HiddenField runat="server" ID="rfqAutoRenewalSource" />
    <asp:HiddenField runat="server" ID="hdnParentRFQRenewal" />
    <asp:HiddenField ID="hdnIsADelegateRequest" runat="server" Value="False" />
    <asp:HiddenField ID="hdnIsUserExistsInCollaborationCommittee" runat="server" Value="false" />
    <asp:HiddenField runat="server" ID="hdPurEnqIds" />
    <asp:Panel ID="errorbg" runat="server" Style="display: block">
    <div class="left">
    <asp:Image ID="img" runat="server" ImageUrl="" Height="20px" />
    </div>
    <div class="right">
    <asp:Label ID="lblStatus" runat="server" ForeColor="Red" />
    </div>
    </asp:Panel>
    <div style="padding-top: 2px; float: right; display: none">
    <asp:LinkButton ID="lnkTopSaveAsDraft" runat="server" CssClass="button" Visible="false" ValidationGroup="SaveAsDraftInfo" OnClick="lnkSaveAsDraft_Click" OnClientClick="javascript:return ValidateControls();">
    <span>Save as Draft</span></asp:LinkButton>
    <asp:LinkButton ID="lnkTopSubmit" runat="server" CssClass="button" Visible="false" ValidationGroup="SubmitInfo" OnClick="lnkSubmit_Click" OnClientClick="javascript:return ValidateControls();">
    <span id="spanSubmit" runat="server">Submit</span></asp:LinkButton>
    <asp:HiddenField ID="HiddenField3" runat="server" />
    </div>
    <table width="100%" border="0">
    <tr>
    <td style="width: 35%">
    </td>
    <td align="right" style="width: 65%">
    <div style="float: right;">
    <asp:LinkButton ID="lnkclose" runat="server" CssClass="button" Visible="false"><span>Close RFQ</span></asp:LinkButton>
    <asp:LinkButton ID="lnkextend" runat="server" CssClass="button" Visible="false"><span>Extend RFQ</span></asp:LinkButton>
    <asp:LinkButton ID="lnkcancel" runat="server" CssClass="button" Visible="false"><span>Cancel RFQ</span></asp:LinkButton>
    <asp:LinkButton ID="lnkPublish" runat="server" CssClass="button" OnClick="lnkPublish_Click" OnClientClick="javascript:return ValidateControlsPublish();" Visible="false"><span>Publish RFQ</span></asp:LinkButton>
    <asp:LinkButton CssClass="button" runat="server" ID="lbtnApprove" Visible="false" OnClick="lbtnApprove_Click"><span>Approve</span></asp:LinkButton>
    <asp:LinkButton CssClass="button" runat="server" ID="lbtAction" Visible="false"><span>Action</span></asp:LinkButton>
    <asp:LinkButton CssClass="button" runat="server" ID="lbtnEdit" OnClick="lbtnEdit_Click" Visible="false"><span>Edit</span></asp:LinkButton>
    <asp:LinkButton CssClass="button" runat="server" ID="lbtnviewlog" Visible="false"><span>View Approval Log</span></asp:LinkButton>
    <asp:LinkButton CssClass="button" runat="server" ID="lnkRevisionGrid" Visible="false"><span>Initiate Revision Grid</span></asp:LinkButton>
    <asp:LinkButton CssClass="button" runat="server" ID="lnkRevision" OnClick="lnkRevision_Click" Visible="false"><span>Initiate Revision</span></asp:LinkButton>
    <asp:LinkButton ID="lnkCreateCircular" CssClass="buttonstyle" runat="server" Visible="false" OnClientClick="OpenCreateCircularTab()"><span>Create Circular</span></asp:LinkButton>
    <%-- <asp:LinkButton ID="lnkPrint" CssClass="buttonstyle" runat="server" Visible="true"
    OnClick="lnkPrint_click"><span>Export</span></asp:LinkButton>--%>
    </div>
    </td>
    </tr>
    </table>
    <div class="technology Childdiv">
    <span class="childspaneditbox">RFQ Form</span> <span class="childspaneditbox">&nbsp;&nbsp;
    <asp:CheckBox ID="EditFormCheckBox" runat="server" Text="&nbsp;Edit Form" Checked="false" AutoPostBack="true" OnCheckedChanged="EditFormCheckBox_CheckedChanged" Visible="false" ClientIDMode="Static" />&nbsp;&nbsp;<img src="~/Images/tooltip.jpg" alt="ToolTip" style="vertical-align: middle;" onmouseout="tooltip.hide();" runat="server" id="EditFormImage" visible="false" />
    </span>
    </div>
    <div class="technology Childdiv" id="divgrfq" runat="server">
    <img src="../Images/minus.gif" id="RFQDetailsImage" alt="Expand/Collapse" onclick="javascript:toggle('RFQDetailsImage','toggleTextGR');" title="Expand/Collapse" style="vertical-align: text-top;" runat="server" />
    <b>RFQ Details </b>
    </div>
    <div class="thelanguage" id="toggleTextGR" style="display: block" runat="server">
    <center>
    <ucRFQInfo:RFQInfo ID="ucRFQInfoRFQ" runat="server" />
    <%--Added By:Sumit,For General RFQ--%>
    </center>
    </div>
    <asp:Panel ID="divGenTemplate" runat="server" Visible="false">
    <div class="technology Childdiv" runat="server" id="RFQTemplateDiv">
    <img src="../Images/minus.gif" id="RFQTemplateImage" alt="Expand/Collapse" onclick="javascript:toggle('RFQTemplateImage','RFQTemplateChildDiv');" title="Expand/Collapse" style="vertical-align: text-top;" runat="server" />
    <b>RFQ Template Detail</b></div>
    <div class="thelanguage" id="RFQTemplateChildDiv" style="display: block" runat="server">
    <center>
    <ucRFQTemplt:RFQTemplate ID="ucRFQTemplt" runat="server" />
    </center>
    </div>
    </asp:Panel>
    <div runat="server" id="div_main" visible="false">
    <!--General Procurement Start -->
    <div id="divitemGenRFQ" runat="server" visible="false">
    <%-- Added By:Sumit = Item Control for General RFQ--%>
    <div class="technology Childdiv">
    <img src="../Images/minus.gif" id="imgitemGn" alt="Expand/Collapse" onclick="javascript:toggle('imgitemGn','divCommPkg');" title="Expand/Collapse" style="vertical-align: text-top;" runat="server" />
    <b>Item & Cost Details</b>
    </div>
    <div class="thelanguage" id="divCommPkg" style="display: block; overflow: hidden" runat="server">
    <%--<telerik:RadAjaxPanel ID="rapCommPkg" runat="server">--%>
    <div style="margin-bottom: 10px; margin-left: 82%;">
    <asp:LinkButton ID="lbtnPreview" runat="server" CssClass="button" Style="display: none" OnClick="OpenSupplierView" OnClientClick="setOpenPup()">
    <span id="spanPrev" runat="server" title="Supplier View">Supplier View</span></asp:LinkButton></div>
    <ucCommPkg:CommPkgTemplate ID="ucCommPkgAppendixB" runat="server" />
    <%-- </telerik:RadAjaxPanel>--%>
    </div>
    <div class="thelanguage" id="divItemGN" runat="server" visible="false" style="display: none; overflow: hidden" clientidmode="Static">
    <ucItemDetails:ItemDetails ID="ucItemDetails" runat="server" Visible="false" />
    <div runat="server" id="divadditionalcost" style="display: none;" clientidmode="Static">
    <center>
    <table class="evalPackage" width="65%" runat="server" id="tblAdditionalCost">
    <tr>
    <td colspan="4" align="left" class="evalQHeader">
    <label class="label" style="color: Black;">
    Additional Cost</label>
    </td>
    </tr>
    <tr>
    <td align="center" style="width: 15%;" class="evalQHeader">
    <label class="label" style="color: Black;">
    Type</label>
    </td>
    <td align="center" style="width: 15%" class="evalQHeader">
    <label class="label" style="color: Black;">
    Price</label>
    </td>
    <td align="center" style="width: 20%" class="evalQHeader">
    <label class="label" style="color: Black;">
    Taxes</label>
    </td>
    <td align="center" style="width: 15%" class="evalQHeader">
    <label class="label" style="color: Black;">
    Net Rate</label>
    </td>
    </tr>
    <tr>
    <td>
    <label class="label">
    Freighter</label>
    </td>
    <td style="height: 26px;">
    <telerik:RadNumericTextBox ID="radFreigherP" Width="140px" runat="server" CssClass="textEntry" MaxLength="10" MinValue="1" ReadOnly="true" Enabled="false">
    <numberformat decimaldigits="2" />
    <clientevents onblur="OnBlurFreigher" />
    </telerik:RadNumericTextBox>
    </td>
    <td>
    <telerik:RadComboBox ID="radFreigherTcmb" runat="server" Width="35%" OnClientSelectedIndexChanged="radFreigherTcmb_SelectedIndexChanged" EmptyMessage="-Select-">
    <items>
    <telerik:RadComboBoxItem runat="server" Text="-Select-" Value="Select" />
    <telerik:RadComboBoxItem runat="server" Text="Amount" Value="Amount" />
    <telerik:RadComboBoxItem runat="server" Text="Percentage" Value="Percentage" />
    </items>
    </telerik:RadComboBox>
    <telerik:RadNumericTextBox ID="radFreigherT" Width="80px" runat="server" CssClass="textEntry" MaxLength="10" MinValue="1" Enabled="false">
    <numberformat decimaldigits="2" />
    <clientevents onblur="OnBlurFreigher" />
    </telerik:RadNumericTextBox>
    </td>
    <td>
    <telerik:RadNumericTextBox ID="radFreigherR" Width="140px" runat="server" CssClass="textEntry" ReadOnly="true" Enabled="false" MaxLength="255" MinValue="1">
    <numberformat decimaldigits="2" />
    </telerik:RadNumericTextBox>
    </td>
    </tr>
    <tr style="background: #E8E8E8;">
    <td>
    <label class="label">
    Insurance</label>
    </td>
    <td style="height: 26px;">
    <telerik:RadNumericTextBox ID="InsuranceP" Width="140px" runat="server" CssClass="textEntry" MaxLength="10" MinValue="1" ReadOnly="true" Enabled="false">
    <numberformat decimaldigits="2" />
    <clientevents onblur="OnBlurInsurance" />
    </telerik:RadNumericTextBox>
    </td>
    <td>
    <telerik:RadComboBox ID="InsurancTcmb" runat="server" Width="35%" OnClientSelectedIndexChanged="InsurancTcmb_SelectedIndexChanged" EmptyMessage="-Select-">
    <items>
    <telerik:RadComboBoxItem runat="server" Text="-Select-" Value="Select" />
    <telerik:RadComboBoxItem runat="server" Text="Amount" Value="Amount" />
    <telerik:RadComboBoxItem runat="server" Text="Percentage" Value="Percentage" />
    </items>
    </telerik:RadComboBox>
    <telerik:RadNumericTextBox ID="InsurancT" Width="80px" runat="server" CssClass="textEntry" MaxLength="10" MinValue="1" Enabled="false">
    <numberformat decimaldigits="2" />
    <clientevents onblur="OnBlurInsurance" />
    </telerik:RadNumericTextBox>
    </td>
    <td>
    <telerik:RadNumericTextBox ID="InsuranceR" Width="140px" runat="server" CssClass="textEntry" ReadOnly="true" Enabled="false" MaxLength="255" MinValue="1">
    <numberformat decimaldigits="2" />
    </telerik:RadNumericTextBox>
    </td>
    </tr>
    <tr>
    <td>
    <label class="label">
    Others</label>
    </td>
    <td style="height: 26px;">
    <telerik:RadNumericTextBox ID="OthersP" Width="140px" runat="server" CssClass="textEntry" MaxLength="10" MinValue="1" ReadOnly="true" Enabled="false">
    <numberformat decimaldigits="2" />
    <clientevents onblur="OnBlurOther" />
    </telerik:RadNumericTextBox>
    </td>
    <td>
    <telerik:RadComboBox ID="OthersTcmb" runat="server" Width="35%" OnClientSelectedIndexChanged="OthersTcmb_SelectedIndexChanged" EmptyMessage="-Select-">
    <items>
    <telerik:RadComboBoxItem runat="server" Text="-Select-" Value="Select" />
    <telerik:RadComboBoxItem runat="server" Text="Amount" Value="Amount" />
    <telerik:RadComboBoxItem runat="server" Text="Percentage" Value="Percentage" />
    </items>
    </telerik:RadComboBox>
    <telerik:RadNumericTextBox ID="OthersT" Width="80px" runat="server" CssClass="textEntry" MaxLength="10" MinValue="1" Enabled="false">
    <numberformat decimaldigits="2" />
    <clientevents onblur="OnBlurOther" />
    </telerik:RadNumericTextBox>
    </td>
    <td>
    <telerik:RadNumericTextBox ID="OthersR" Width="140px" runat="server" CssClass="textEntry" ReadOnly="true" Enabled="false" MaxLength="255" MinValue="1">
    <numberformat decimaldigits="2" />
    </telerik:RadNumericTextBox>
    </td>
    </tr>
    </table>
    </center>
    </div>
    </div>
    </div>
    <!--General Procurement End -->
    <!--HOTAC Accommodation -->
    <div id="divDisplayHotacBlock" runat="server" visible="false">
    <div class="technology Childdiv">
    <img src="../Images/minus.gif" id="imgHotacAccom" alt="Expand/Collapse" onclick="javascript:toggle('imgHotacAccom','divHotacAccom');" title="Expand/Collapse" style="vertical-align: text-top;" runat="server" />
    <b>Requirement Details</b>
    </div>
    <div class="thelanguage" id="divHotacAccom" style="display: block;" runat="server">
    <ucHotacAccom:HotelAccommodation ID="ucHotacAccom" runat="server" />
    </div>
    <asp:Panel ID="divFltOptCrewPattern" runat="server" Visible="false">
    <!--Flight crew pattern implementation -->
    <div class="technology Childdiv" id="div5" runat="server">
    <img src="../Images/minus.gif" id="imgFltPtrnEC" alt="Expand/Collapse" onclick="javascript:toggle('imgFltPtrnEC','dvFltPtrnDisplay');" title="Expand/Collapse" style="vertical-align: text-top;" runat="server" />
    <b>Flight Details</b></div>
    <div class="thelanguage" id="dvFltPtrnDisplay" style="display: block;" runat="server">
    <ucFltOptDisplay:FlightOperatingAndRoomReqDisplay ID="ucFltOptDisplay" runat="server" />
    </div>
    </asp:Panel>
    <%--Flight Pattern--%>
    <asp:Panel ID="divFltOptPattern" runat="server" Visible="false">
    <!--Flight Information -->
    <div class="technology Childdiv" id="div1" runat="server">
    <img src="../Images/minus.gif" id="displayText12" alt="Expand/Collapse" onclick="javascript:toggle('displayText12','toggleText12');" title="Expand/Collapse" style="vertical-align: text-top;" runat="server" />
    <b>Flight Details</b></div>
    <div class="thelanguage" id="toggleText12" style="display: block;" runat="server">
    <%-- <ucFltOptDisplay:FlightOperatingAndRoomReqDisplay ID="ucFltOptDisplay" runat="server" />--%>
    <%-- <asp:Label ID="lblFltInfo" runat="server" Font-Bold="true" ForeColor="Blue" Text="To view the details of flight pattern (scheduled and overlapped room requirements), please click below." />--%>
    <label style="color: Blue; font-size: small; width: 100%; visibility: visible;">
    <b><i>To view the details of flight pattern (scheduled and overlapped room requirements), please click below.</i></b>
    </label>
    <center>
    <table style="width: 85%; padding-top: 10px;">
    <tr>
    <td style="width: 30%;">
    <asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional">
    <Triggers>
    <asp:AsyncPostBackTrigger ControlID="lnkFltDisplay" EventName="Click" />
    </Triggers>
    <ContentTemplate>
    <asp:LinkButton ID="lnkFltDisplay" runat="server" Font-Size="Small" Font-Bold="true" Text="Flight Pattern Details"></asp:LinkButton>
    </ContentTemplate>
    </asp:UpdatePanel>
    </td>
    <td>
    </td>
    </tr>
    </table>
    </center>
    </div>
    </asp:Panel>
    </div>
    <%--Catering Menu Grid Station--%>
    <asp:Panel ID="pnlCateringStation" runat="server" Visible="false">
    <div class="technology Childdiv" id="div2">
    <img src="../Images/minus.gif" id="Img1" alt="Expand/Collapse" onclick="javascript:toggle('Img1','Div3');" title="Expand/Collapse" style="vertical-align: text-top;" runat="server" />
    <b>Station</b></div>
    <div class="thelanguage" id="Div3" style="display: block" runat="server">
    <center>
    <ucStation:RFQStation ID="ucStation" runat="server" />
    </center>
    </div>
    <ucCatMnuGrd:CateringMenuGrid ID="ucCatMnuGrd" runat="server" />
    </asp:Panel>
    <%--Evaluation Packages--%>
    <asp:Panel ID="divEvalDocs" runat="server" Visible="false">
    <div class="technology Childdiv">
    <img src="../Images/minus.gif" id="imgHotacTechEval" alt="Expand/Collapse" onclick="javascript:toggle('imgHotacTechEval','divHotacTechEval');" title="Expand/Collapse" style="vertical-align: text-top;" runat="server" />
    <b>RFQ Documents</b>
    </div>
    <div class="thelanguage" id="divHotacTechEval" style="display: block;" runat="server">
    <center>
    <table id="tableAutoRenewalPackage" runat="server" visible="false">
    <tr>
    <td>
    <span class="errStar">* </span>
    <label class="labelform">
    <b>Do you need price confirmation from Supplier : </b>
    </label>
    </td>
    <td>
    <telerik:RadComboBox ID="ddlPriceConfirmation" runat="server" Width="250px" CssClass="textEntry" AutoPostBack="true" EnableLoadOnDemand="true" onmouseover="tooltip.show('Please attach price confirmation document in case of NO');" onmouseout="tooltip.hide();" EmptyMessage="Select" AllowCustomText="false" EnableVirtualScrolling="true" OnSelectedIndexChanged="ddlPriceConfirmation_SelectedIndexChanged">
    <items>
    <telerik:RadComboBoxItem Value="Y" Text="Yes" />
    <telerik:RadComboBoxItem Value="N" Text="No" />
    </items>
    </telerik:RadComboBox>
    </td>
    </tr>
    </table>
    <div style="width: 60% !important;" id="tableEvalPackage" runat="server">
    <div style="text-align: left; vertical-align: bottom;" id="dvValidationMsgTech" runat="server">
    <label style="color: Blue; font-size: small; width: 100%; visibility: visible;">
    <b><i>Please enter the weightage percentage against each package and overall total should be 100%.</i></b>
    </label>
    </div>
    <asp:UpdatePanel ID="radAJAXPnlEval" runat="server" UpdateMode="Conditional">
    <Triggers>
    <asp:AsyncPostBackTrigger ControlID="lnkTechnicalEvaluation" EventName="Click" />
    <asp:AsyncPostBackTrigger ControlID="lnkCommercialEvaluation" EventName="Click" />
    <asp:AsyncPostBackTrigger ControlID="lnkContrctTermsCond" EventName="Click" />
    </Triggers>
    <ContentTemplate>
    <table class="evalPackage">
    <tr>
    <td colspan="2">
    </td>
    </tr>
    <tr style="height: 25px;">
    <td style="width: 75%;" class="evalQHeader">
    RFQ Documents
    </td>
    <td style="width: 25%;" class="evalQHeader">
    Weightage (%)
    </td>
    </tr>
    <tr style="height: 25px;" id="trRFQTechDoc" runat="server">
    <td>
    <span id="lblTechnicalEvaluation" runat="server" class="errStar">* </span>
    <asp:LinkButton ID="lnkTechnicalEvaluation" runat="server" Font-Size="Small" ForeColor="#630040">Technical Package</asp:LinkButton>
    </td>
    <td>
    <telerik:RadNumericTextBox ShowSpinButtons="false" Width="100%" IncrementSettings-InterceptArrowKeys="false" IncrementSettings-InterceptMouseWheel="false" runat="server" ID="txtTechtWeightage" MaxValue="100" NumberFormat-DecimalDigits="0" ReadOnlyStyle-BorderWidth="0" ReadOnlyStyle-BackColor="Transparent" ReadOnlyStyle-HorizontalAlign="Center" EnabledStyle-HorizontalAlign="Center" onblur="sumWeightage();" />
    </td>
    </tr>
    <tr style="height: 25px; background: #E8E8E8;" id="trRFQContractTerms" runat="server">
    <td>
    <span id="lblContrctTermsCond" runat="server" class="errStar">* </span>
    <asp:LinkButton ID="lnkContrctTermsCond" runat="server" Font-Size="Small" ForeColor="#630040">Contract Terms & Conditions</asp:LinkButton>
    </td>
    <td>
    <telerik:RadNumericTextBox ShowSpinButtons="false" Width="100%" IncrementSettings-InterceptArrowKeys="false" IncrementSettings-InterceptMouseWheel="false" runat="server" ID="txtContractWeightage" MaxValue="100" NumberFormat-DecimalDigits="0" ReadOnlyStyle-BorderWidth="0" ReadOnlyStyle-BackColor="Transparent" ReadOnlyStyle-HorizontalAlign="Center" EnabledStyle-HorizontalAlign="Center" onblur="sumWeightage();" />
    </td>
    </tr>
    <tr style="height: 25px;">
    <td>
    <span id="lblCommercialEvaluationMandat" runat="server" class="errStar">* </span>
    <asp:Label ID="lblCommercialEval" Visible="false" runat="server" Font-Size="Small" ForeColor="#630040">Commercial Evaluation</asp:Label>
    <asp:LinkButton ID="lnkCommercialEvaluation" runat="server" Font-Size="Small" ForeColor="#630040">Commercial Package</asp:LinkButton>
    </td>
    <td>
    <telerik:RadNumericTextBox ShowSpinButtons="false" Width="100%" IncrementSettings-InterceptArrowKeys="false" IncrementSettings-InterceptMouseWheel="false" runat="server" ID="txtCommWeightage" MaxValue="100" NumberFormat-DecimalDigits="0" ReadOnlyStyle-BorderWidth="0" ReadOnlyStyle-BackColor="Transparent" ReadOnlyStyle-HorizontalAlign="Center" EnabledStyle-HorizontalAlign="Center" onblur="sumWeightage();" />
    </td>
    </tr>
    <tr style="background: #E8E8E8; height: 25px;">
    <td style="float: right; vertical-align: bottom; padding-bottom: -2px;">
    <label>
    <span id="Span4" runat="server" style="font-weight: bold; font-size: small; padding-right: 2px;">Total :</span>
    </label>
    </td>
    <td>
    <telerik:RadNumericTextBox ShowSpinButtons="false" Width="100%" IncrementSettings-InterceptArrowKeys="false" IncrementSettings-InterceptMouseWheel="false" runat="server" ID="txtWeightageTotal" ReadOnly="true" NumberFormat-DecimalDigits="0" ReadOnlyStyle-BorderWidth="0" ReadOnlyStyle-BackColor="Transparent" ReadOnlyStyle-HorizontalAlign="Center" Enabled="false" EnabledStyle-HorizontalAlign="Center" EnabledStyle-Font-Bold="true" />
    </td>
    </tr>
    </table>
    </ContentTemplate>
    </asp:UpdatePanel>
    </div>
    <table id="tableAutoRenewalAttach" runat="server" visible="false" cellpadding="4" cellspacing="5" border="0" width="95%">
    <tr id="trAutoRenewalAttchmntTitle" runat="server">
    <td align="right" style="vertical-align: middle; width: 12%;" runat="server" id="tdAutoRenewalTitle">
    <span class="errStar">* </span>
    <label class="Labeltext" id="lblTitle" runat="server">
    <b>Title : </b>
    </label>
    </td>
    <td align="left" style="vertical-align: middle; width: 20%;" runat="server" id="tdAutoRenewalInternalDoc">
    <telerik:RadTextBox ID="txtAutoRenewalInternalDocTitle" Width="250px" runat="server" CssClass="textEntry" MaxLength="100" />
    <br />
    <asp:RequiredFieldValidator ID="reqAutoRenewalAttachmentTitle" runat="server" ControlToValidate="txtAutoRenewalInternalDocTitle" Display="Dynamic" CssClass="error" ValidationGroup="InternalAutoRenewalAttachementInfo" ErrorMessage="Please enter title">
    </asp:RequiredFieldValidator>
    </td>
    <td style="width: 3%;">
    </td>
    <td align="right" style="vertical-align: middle; width: 10%;" runat="server" id="tdAutoRenewalFilePath">
    <span class="errStar">* </span>
    <label class="Labeltext">
    <b>File Path : </b>
    </label>
    </td>
    <td align="left" style="vertical-align: middle; width: 20%;" runat="server" id="tdAutoRenewalFileUpload">
    <telerik:RadAsyncUpload runat="server" ID="fileAutoRenewalInternalDoc" OnFileUploaded="RadAsyncUpload_FileUploaded" MultipleFileSelection="Disabled" AllowedFileExtensions=".jpg,.gif,.xls,.doc,.pdf,.ppt,.png,.jpeg,.docx,.xlsx,.pptx,.txt" Localization-Select="Browse..." MaxFileSize="20000000" OnClientValidationFailed="OnClientValidationFailed" OnClientFileSelected="clientFileSelected" ClientIDMode="Static">
    </telerik:RadAsyncUpload>
    <asp:CustomValidator ID="RequiredValidator" runat="server" Display="Dynamic" ValidationGroup="InternalAutoRenewalAttachementInfo" ErrorMessage="Please Upload File" CssClass="error" OnServerValidate="Validate_FileRequired" ClientValidationFunction="validateUploadForRequired">
    </asp:CustomValidator>
    <asp:CustomValidator ID="CustomValidator1" runat="server" Display="Dynamic" ValidationGroup="InternalAutoRenewalAttachementInfo" ErrorMessage="File size should not be greater than 20MB" CssClass="error" OnServerValidate="Validate_FileSize">
    </asp:CustomValidator>
    <asp:CustomValidator ID="CustomValidator2" runat="server" Display="Dynamic" ValidationGroup="InternalAutoRenewalAttachementInfo" ErrorMessage="File name should not be exceed 100 characters" CssClass="error" OnServerValidate="Validate_FileNameLength">
    </asp:CustomValidator>
    <asp:CustomValidator ID="ContentTypeValidator" runat="server" Display="Dynamic" ValidationGroup="InternalAutoRenewalAttachementInfo" ErrorMessage="Only accept JPG,GIF,DOC,XLS,PDF,PPT,PNG,TXT files format" CssClass="error" OnServerValidate="Validate_FileContentType">
    </asp:CustomValidator>
    </td>
    </tr>
    <tr id="trAutoRenewalAttchmntDesc" runat="server">
    <td align="right" style="vertical-align: middle;" runat="server" id="tdAutoRenewalDescription">
    <span class="errStar">* </span>
    <label class="Labeltext">
    <span class="errStar"></span><b>Description : </b>
    </label>
    </td>
    <td align="left" style="vertical-align: middle;" runat="server" id="tdAutoRenewalInternalDocDescription">
    <telerik:RadTextBox ID="txtAutoRenewalInternalDocDescription" Height="40" Width="250px" TextMode="MultiLine" runat="server" CssClass="textEntry" MaxLength="250" />
    <br />
    </td>
    <td>
    </td>
    <td>
    </td>
    <td align="right" style="vertical-align: top; padding-left: 16%" runat="server" id="tdAutoRenewalInternalDocAdd">
    <asp:LinkButton ID="lnkAutoRenewalInternalDocAdd" runat="server" CssClass="button" OnClick="lnkAutoRenewalInternalDocAdd_Click" ValidationGroup="InternalAutoRenewalAttachementInfo">
    <span>Add</span></asp:LinkButton>
    </td>
    </tr>
    <tr>
    <td colspan="5">
    <center>
    <asp:GridView ID="grdAutoRenewalInternalApproval" Width="91%" CssClass="gridview1" runat="server" AllowSorting="true" AutoGenerateColumns="false" ShowHeaderWhenEmpty="true" OnRowDeleting="grdAutoRenewalInternalApproval_OnRowDeleting" RowStyle-CssClass="alterwhite" AlternatingRowStyle-CssClass="altergrey" HeaderStyle-CssClass="tableHeadingCenter br" OnRowDataBound="grdAutoRenewalInternalApproval_RowDataBound">
    <Columns>
    <asp:BoundField HeaderText="Title" ItemStyle-Width="15%" DataField="AttachTitle" ItemStyle-CssClass="breakWord120" />
    <asp:BoundField HeaderText="Description" ItemStyle-Width="45%" DataField="AttachDescription" ItemStyle-CssClass="breakWord120" />
    <asp:TemplateField HeaderText="Attachment Type" ItemStyle-Width="15%" ItemStyle-CssClass="hiddencol" HeaderStyle-CssClass="hiddencol">
    <ItemTemplate>
    <asp:HiddenField ID="hidAutoRenewalFrwdAttachmentType" runat="server" Value='<%# Eval("AttachType") %>' />
    <asp:Label ID="lblAutoRenewalFwrdAttachmentType" runat="server" Text=""></asp:Label>
    </ItemTemplate>
    </asp:TemplateField>
    <asp:TemplateField HeaderText="File Name" ItemStyle-Width="20%">
    <ItemTemplate>
    <asp:LinkButton ID="btnAutoRenewalviewattach" runat="server" ToolTip="View File" CommandName="ViewAttach" OnClick="btnAutoRenewalviewattach_Click" Text='<%#Eval("FileName") %>' Style="color: Blue;" Font-Underline="true" ForeColor="Blue" CommandArgument='<%#Eval("AttachFilePath") + "//" + Eval("VirtualPath")%>'>
    <asp:Label runat="server" ID="lblattachpath" Text='<%#Eval("AttachFilePath") %>'></asp:Label>
    </asp:LinkButton>
    </ItemTemplate>
    </asp:TemplateField>
    <asp:TemplateField HeaderText="Delete" ItemStyle-Width="5%">
    <ItemTemplate>
    <center>
    <asp:ImageButton ID="btnAutoRenewalDelete" runat="server" ImageUrl="~/Images/delete.png" ToolTip="Delete" CommandName="Delete" OnClientClick="return confirm('Do you really want to delete?');" /></center>
    </ItemTemplate>
    </asp:TemplateField>
    </Columns>
    <EmptyDataRowStyle CssClass="sup_site" />
    <EmptyDataTemplate>
    <center>
    <asp:Image ID="NoDataImage" ImageUrl="~/Images/delete.png" AlternateText="No Image" runat="server" />
    No records found.</center>
    </EmptyDataTemplate>
    </asp:GridView>
    </center>
    </td>
    </tr>
    </table>
    </center>
    </div>
    </asp:Panel>
    <%--Contract Terms and Condition--%>
    <asp:Panel ID="pnlContract" runat="server" Visible="false">
    <div class="technology Childdiv">
    <img src="../Images/minus.gif" id="img3" alt="Expand/Collapse" onclick="javascript:toggle('imgHotacTechEval','divHotacTechEval');" title="Expand/Collapse" style="vertical-align: text-top;" runat="server" />
    <b>Contract terms and condition</b>
    </div>
    <div class="thelanguage" id="div4" style="display: block;" runat="server">
    <center>
    <div style="width: 60% !important;">
    <%--<div style="text-align: left; vertical-align: bottom;" id="dvValidationMsgTech" runat="server">
    <label style="color: Blue; font-size: small; width: 100%; visibility: visible;">
    <b><i>Please enter the Contract terms and condition.</i></b>
    </label>
    </div>--%>
    <asp:UpdatePanel ID="UpdatePanel2" runat="server" UpdateMode="Conditional">
    <Triggers>
    <asp:AsyncPostBackTrigger ControlID="lnkContrctTermsCond" EventName="Click" />
    </Triggers>
    <ContentTemplate>
    <table class="evalPackage">
    <tr style="height: 25px;">
    <td>
    <%--<span class="errStar">* </span>--%>
    <asp:LinkButton ID="lnkCatContrctTermsCond" runat="server" Font-Size="Small" ForeColor="#630040">Contract Terms & Conditions</asp:LinkButton>
    </td>
    </tr>
    <tr style="height: 25px;">
    <td>
    <%--<span class="errStar">* </span>--%>
    <a href="javascript:void" onclick="javascript:return ShowSupplierQuestionnairePopup();" style="font-size: small; color: #630040;">Supplier Questionnaire</a>
    </td>
    </tr>
    </table>
    </ContentTemplate>
    </asp:UpdatePanel>
    </div>
    </center>
    </div>
    </asp:Panel>
    <%--Collaboration Committee--%>
    <asp:Panel ID="pnlCollaboration" runat="server" Visible="true">
    <div class="technology Childdiv">
    <img src="../Images/minus.gif" id="displayText1" alt="Expand/Collapse" onclick="javascript:toggle('displayText1','toggleText1');" title="Expand/Collapse" style="vertical-align: text-top;" runat="server" />
    <b>Collaboration Committee</b></div>
    <div class="thelanguage" id="toggleText1" style="display: block;" runat="server">
    <ucCCM:CollaborationCommitte ID="ucCCMTY" runat="server" />
    </div>
    </asp:Panel>
    <%--Internal Approval Documents--%>
    <asp:Panel ID="pnlInternalApprovalDoc" runat="server" Visible="true">
    <div class="technology Childdiv">
    <img src="../Images/minus.gif" id="InternalAppDocImage" alt="Expand/Collapse" onclick="javascript:toggle('InternalAppDocImage','toggleText5');" title="Expand/Collapse" style="vertical-align: text-top;" runat="server" />
    <b>Internal Approval Documents</b></div>
    <div class="thelanguage" id="toggleText5" style="display: block" runat="server">
    <center>
    <div style="text-align: left; vertical-align: bottom;" id="lblInternalApprovalDoc" runat="server">
    <label style="color: Blue; font-size: small; width: 100%; visibility: visible;">
    <b><i>Attachments for internal approvers only.</i></b>
    </label>
    </div>
    <ucIADocs:InternalApprovalDocuments ID="ucIADocs" runat="server" />
    </center>
    </div>
    </asp:Panel>
    <%--Attachments--%>
    <asp:Panel ID="pnlAttachments" runat="server" Visible="true">
    <div class="technology Childdiv" id="dvAtta" runat="server">
    <img src="../Images/minus.gif" id="AttachmentsImage" alt="Expand/Collapse" onclick="javascript:toggle('AttachmentsImage','AttachmentsDiv');" title="Expand/Collapse" style="vertical-align: text-top;" runat="server" />
    <b>
    <asp:Label ID="lblAttachmntHeader" Text="Attachments" runat="server" ToolTip="External attachments can be viewed by Suppliers" />
    </b>
    </div>
    <div class="thelanguage" id="AttachmentsDiv" style="display: block" runat="server">
    <center>
    <div style="text-align: left; vertical-align: bottom;" id="lblappendixB" runat="server" visible="false">
    <label style="color: Blue; font-size: small; width: 100%; visibility: visible;">
    <b><i>Please ensure to attach pricing template appendix B which will be mandatory for supplier to complete.</i></b>
    </label>
    </div>
    <ucRFQAtachtmt:RFQAttachments ID="ucRFQAtachmnt" runat="server" />
    </center>
    </div>
    </asp:Panel>
    <%--Controls--%>
    <asp:Panel ID="pnlControls" runat="server" Visible="true">
    <div class="technology Childdiv">
    <img src="../Images/plus.gif" id="ControlsImage" alt="Expand/Collapse" onclick="javascript:toggle('ControlsImage','ControlsDiv');" title="Expand/Collapse" style="vertical-align: text-top;" runat="server" />
    <b>Controls</b></div>
    <div class="thelanguage" id="ControlsDiv" style="display: none" runat="server">
    <center>
    <ucDateTimeCtrls:DateTimeControls ID="ucDTCtrls" runat="server" />
    </center>
    </div>
    </asp:Panel>
    <%--Invited Suppliers--%>
    <asp:Panel ID="pnlInvitedSuppliers" runat="server" Visible="true">
    <div class="technology Childdiv">
    <img src="../Images/plus.gif" id="InvitedSuppliersImage" alt="Expand/Collapse" onclick="javascript:toggle('InvitedSuppliersImage','InvitedSuppliersDiv');" title="Expand/Collapse" style="vertical-align: text-top;" runat="server" />
    <b>Invited Suppliers</b></div>
    <div class="thelanguage" id="InvitedSuppliersDiv" style="display: none" runat="server">
    <center>
    <ucInvSupplrs:InvitedSuppliers ID="ucInvSupplrs" runat="server" />
    </center>
    </div>
    </asp:Panel>
    <%-- Clarification Block --%>
    <asp:Panel ID="pnlClarification" runat="server" Visible="false">
    <div class="technology Childdiv" id="divcalrification" runat="server">
    <img src="../Images/minus.gif" id="ClarificationImage" alt="Expand/Collapse" onclick="javascript:toggle('ClarificationImage','ClarificationDiv');" title="Expand/Collapse" style="vertical-align: text-top;" runat="server" />
    <b>Clarification</b>
    </div>
    <div class="thelanguage" id="ClarificationDiv" style="display: block" runat="server">
    <ucClarification:Clarification ID="ucClarification" runat="server" />
    </div>
    </asp:Panel>
    </div>
    <div style="padding-top: 15px; float: right;">
    <asp:LinkButton ID="lnkSaveAsDraft" runat="server" CssClass="button" ValidationGroup="SaveAsDraftInfo" OnClick="lnkSaveAsDraft_Click" OnClientClick="javascript:return ValidateControls();" Visible="false"> <span>Save as Draft</span></asp:LinkButton>
    <asp:LinkButton ID="lnkSubmit" runat="server" CssClass="button" ValidationGroup="SubmitInfo" OnClick="lnkSubmit_Click" OnClientClick="javascript:return ValidateControls();" Visible="false">
    <span id="txtSubmit" runat="server">Submit</span></asp:LinkButton>
    <asp:LinkButton ID="lnkclear" runat="server" CssClass="button" OnClick="lnkclear_Click" Visible="false"> <span>Cancel</span></asp:LinkButton>
    <asp:HiddenField ID="hdnRfqTypeName" runat="server" />
    </div>
    </telerik:RadAjaxPanel>
    <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanelRFQ" runat="server" Transparency="20" BackColor="#E0E0E0">
    <center>
    <table style="margin-top: 320px;">
    <tr>
    <td>
    <asp:Image ID="Image1" runat="server" BackColor="Transparent" Height="10" Width="150" ImageUrl="../Images/loading.gif" AlternateText="loading"></asp:Image>
    </td>
    </tr>
    <tr>
    <td>
    <asp:Label ID="lblSavingStatus" Text="Processing..." runat="server"></asp:Label>
    </td>
    </tr>
    </table>
    </center>
    </telerik:RadAjaxLoadingPanel>
    <telerik:RadWindowManager ID="RadWindowManager1" runat="server" EnableShadow="true">
    <windows>
    <telerik:RadWindow ID="radWinContract" runat="server" Title="Contract Terms and Conditions Attachments"
    IconUrl="~/a.jpg" Height="450px" Width="900px" Left="10px" ReloadOnShow="true"
    Behaviors="Close" ShowContentDuringLoad="false" Modal="true" VisibleStatusbar="false" />
    <telerik:RadWindow ID="UserListDialog" runat="server" Title="Search Suppliers" IconUrl="~/a.jpg"
    Height="1150px" Width="1245px" Left="10px" ReloadOnShow="true" Behaviors="Close"
    OnClientClose="refreshGrid" ShowContentDuringLoad="false" Modal="true" VisibleStatusbar="false" />
    <telerik:RadWindow ID="ViewFlightDetailsDialog" runat="server" Title="Flight Details"
    IconUrl="~/a.jpg" Height="550px" Width="1245px" Left="10px" ReloadOnShow="true"
    Behaviors="Close" ShowContentDuringLoad="false" Modal="true" VisibleStatusbar="false" />
    <telerik:RadWindow ID="rwViewBudgetDetailsDialog" runat="server" Title="Budget Details"
    IconUrl="~/a.jpg" Height="450px" Width="800px" Left="10px" ReloadOnShow="true"
    Behaviors="Close" ShowContentDuringLoad="false" Modal="true" VisibleStatusbar="false" />
    <telerik:RadWindow ID="rwCommercialPkgPreviewDialog" runat="server" Title="Commercial Package"
    IconUrl="~/a.jpg" Left="150px" ReloadOnShow="true" Behaviors="Close" ShowContentDuringLoad="false"
    Modal="true" VisibleStatusbar="false" />
    </windows>
    </telerik:RadWindowManager>
    </div>
    </form>
    </body>
    </html>

  2. Answer
    Hristo Valyavicharski
    Admin
    Hristo Valyavicharski avatar
    975 posts

    Posted 15 Jun 2015 Link to this post

    Hi Jaish,

    Try to set the EnableCustomValidation property of the AsyncUpload to true.
    RadAsyncUpload Server side Validation
    Does it help?

    Regards,
    Hristo Valyavicharski
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top