Useful CRM Tips

Useful CRM Tips...

Thursday, October 06, 2011

Display a popup on crm form

/* Code to Display A Popup from CRM FORM */

var divid = document.getElementById("NewDiv");
if (divid == null) {
    var NewDivs = document.createElement('div'); NewDivs.id = "NewDiv"; NewDivs.innerHTML = "<div id='divCompanyInfo' align='center' style='width: 85%; height:auto;display:none; position: absolute; top:15%; left:10%; z-index: 10000;'>"
+ "<table border='0' bgcolor='#55729c' cellspacing='0' cellpadding='1' width='100%'>"
+ "<tr>"
+ "<td width='100%'>"
   + "<table border='0' cellpadding='0' cellspacing='0' width='100%'>"
        + "<tr>"
            + "<td style='cursor: pointer; font-size: 12px; font-weight: bold; background-color: #a4c0e7;' width='100%'>"
                + "<ilayer onselectstart='return false' width='100%'>"
       + "<layer width='100%'>"
    + "<div color='black' style='padding-left:10px;  height:25px; padding-top:5px;' face='Verdana'><div id = 'titleDiv'><div style='float:left; width:80%'>Address</div><div id= 'closediv' style='float:right; position:relative; right:3px; top:-3px; font-weight:bold; font-size:13px; background-color:#ffffff; padding:1px 3px 1px 3px; border:#666666 solid 1px; color:#666666;' >X</div></div></div></layer>"
   + "</ilayer>"
            + "</td>"
        + "</tr>"
        + "<tr>"
            + "<td bgcolor='#FFFFFF' colspan='2' width='100%'>"
                + "<div>"
                    + "<iframe id='frame_ViewComp' runat='server' frameborder='0' src='' style='width:100%;'></iframe>"
                + "</div>"
            + "</td>"
        + "</tr>"
        + "<tr>"
        + "<td>"
        + "<div style='background-color: #a4c0e7; height: 31px; text-align: right; border-top: #5771a2 silid 5px; padding: 5px 10px 0px 10px;'>"
            + "<div>"
            + "<asp:Button runat='server' ID='btncls' CssClass='crmbuttonLarge' style='float:left;' Width='120px' Text='Run Actions ' OnClientClick = 'CallIframe(); return false;' /></div>"
            + "<div id='footercloseDiv' style='width: 100px;'>"
            + "</div>"
        + "</div>"
        + "</td>"
        + "</tr>"
    + "</table>"
+ "</td>"
+ "</tr>"
+ "</table>"
+ "</div>";

    document.getElementById("tab0").appendChild(NewDivs);
    document.getElementById("closediv").onclick = function () { document.getElementById('divCompanyInfo').style.display = 'none'; };
}

3 comments:

  1. We all are familiar with Popup Window which are great way to show alert, Pop Up Display
    , Trade Show Displays
    , trade show booth flooring
    , Trade Show Flooring
    , modal windows, dialog or take inputs.

    Trade Show Flooring

    Pop Up Display

    Trade Show Displays

    ReplyDelete
  2. Good blog! You have described in a nice way.
    Thanks for sharing this information.
    online printing

    ReplyDelete