tips & tricks


Calendario
dicembre 2024
lmmgvsd
2526272829301
2345678
9101112131415
16171819202122
23242526272829
303112345

Richiamare funzioni lato server da Jscript

 

function AutoFillActivity()

{

    var mb_cityidname = document.all.crmForm.mb_cityid.DataValue;

    var MycityId = mb_cityidname[0].id;

    var submitUrl = CUSTOM_WEB_URL + "/Common/XMLRetrieveActivityInformation.aspx?cityid=" + MycityId;

    var oXml = GetXmlDocument(submitUrl);

 

    if (GetValue(oXml, "IsSucceed") == "False")

    {   alert(GetValue(oXml, "ErrorMessage")); return;   }

    else

    {

        var ActivityId = GetValue(oXml, "mb_activitysiteid");

        if ( ActivityId != null && ActivityId != "NULL")

        {

            var ActivityName = GetValue(oXml, "mb_activitysiteidname");

            var lookupData = new Array();

            var lookupItem2 = new Object();

            lookupItem2.id = ActivityId;

            lookupItem2.typename = 'mb_activitysite';

            lookupItem2.name = ActivityName;

            lookupData[0] = lookupItem2;

            crmForm.all.mb_activitysiteid.DataValue = lookupData;

        }

        else

        {    crmForm.all.mb_activitysiteid.DataValue = null;    }

 

    }

 

}

 

Categoria: CRM 4.0
giovedì, 17 lug 2008 Ore. 17.43
Archivio Posts
Anno 2020

Anno 2018

Anno 2015

Anno 2013

Anno 2011

Anno 2010

Anno 2009

Anno 2008
Statistiche
  • Views Home Page: 15.090
  • Views Posts: 58.339
  • Views Gallerie: 2.837
  • n° Posts: 117
  • n° Commenti: 1
Copyright © 2002-2007 - Blogs 2.0
dotNetHell.it | Home Page Blogs
ASP.NET 2.0 Windows 2003