Adding a simple Silverlight application to SharePoint Online


Hi,

Say we have created a simple Silverlight 4 application that shows current date time.

Now we want to deploy it on the SharePoint Live. For this we can follow these simple steps:-

  1. Open the SharePoint site and click Site Actions |View All Site Content

  1. Click on Documents

  1. Select Upload Document

  1. Select and Upload the HelloWorld.XAP file. After uploading the document copy the url of the file. (e.g. http://my.sharepoint.com/TeamSite/Documents/HelloWorld.xap)

  1. Create a new web part page or open an existing web part page on the site. Click on “Add a Web Part” and select a “Silverlight Web Part” .

  1. Click on configure and specify the URL of the XAP file uploaded and select Apply.

  1. The page with the web part.

Hope it helps.

querySelector and querySelectorAll – Selectors API


Hi,

Apart from our usual document.getElementsById and document.getElementsByTagName method to select element from the DOM we can now make use of document.querySelector and document.querySelectorAll .

With them we can use the same selectors that we use in CSS to select elements for styling.

A simple example

<html>
<head>
    <title>Selectors API</title>
    <script>
        window.onload = function () {

            // select div element with id myDivId
            var myDiv = document.querySelector("#myDivId");

            // select p element with text "Paragraph 1"
            var paragraph1 = myDiv.querySelector("span>p");

            // select p element having class as p1Class
            var paragraph2 = document.querySelector("p.p2Class");

            // select all p element
            var allParagraph = document.querySelectorAll("div>span>span>p");
        }

    </script>
</head>
<body>
    <div id="myDivId" class='divClass'>
        <span><span class='spanClass'>
            <p>
                Paragraph 1</p>
            <p id="p2" class="p2Class">
                Paragraph 2</p>
        </span></span>
    </div>
</body>
</html>

More details

http://msdn.microsoft.com/en-us/ie/cc307217.aspx

http://msdn.microsoft.com/en-us/library/cc288326(v=vs.85).aspx

Browser supported

http://caniuse.com/queryselector

Making cross domain call using JSONP (JSON with padding)


Hi,

Just created a simple html page that uses JSONP to make cross domain call to twitter’s API.

Source Code:-

<!DOCTYPE html>
<html>
<head>
    <title>JSONP Example</title>
    <script>

        function getTweets(tweets) {

            var tweetDiv = document.getElementById("tweet");

            for (var i = 0; i < tweets.results.length; i++) {
                var tweet = tweets.results[i];

                // create div element for each result
                var div = document.createElement("div");
                div.innerHTML = "<img src= " + tweet.profile_image_url + "></img> ";
                div.innerHTML += tweet.from_user + " : <b><i>" + tweet.text + "</b></i>";

                // append it to tweet div
                tweetDiv.appendChild(div);
            }
        }
    </script>
</head>
<body>
<div id="tweet">
</div>
<!--Specifying search term and callback function-->
<script src="http://search.twitter.com/search.json?q=Sachin%20Tendulkar&rpp=10&callback=getTweets"></script>
</body>
</html>

Bye

Used HTML 5 Geolocation API with Bing Map.


Just created a simple html page that shows my location using the new Geolocation API.

Source Code:-

<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8" />
    <title>Geolocation HTML5</title>
    <script src="http://dev.virtualearth.net/mapcontrol/mapcontrol.ashx?v=6.2"></script>
    <script>

        window.onload = getMyLocation;

        function getMyLocation() {

        // Check if the browser supports the Geolocation API
            if (navigator.geolocation) {

                // we can specify how the geolocation computes its value
                var postionOptions = { enableHighAccuracy: true, timeout: 5000, maximumAge: 0 };

                // call getCurrentPosition method of the API
                // getCurrentPosition(successHander, errorHandler, positionOptions)
                navigator.geolocation.getCurrentPosition(displayLocation, displayError, postionOptions);
            }
            else {
                alert("No geolocation support in the browser");
            }
        }

        function displayLocation(position) {

            // load map if location is found
            map = new VEMap('myMap');
            map.LoadMap(null, 4, VEMapStyle.Hybrid);

            // get the latitude and longitude
            var latitude = position.coords.latitude;
            var longitude = position.coords.longitude;

            // place the pushpin
            PlacePushPin(latitude, longitude);

            // get location div and show the latitude longitude and the accuracy
            var divLocation = document.getElementById('location');
            divLocation.innerHTML = "I am at Latitude :" + latitude + ", Longitude : " + longitude;
            divLocation.innerHTML += " with " + position.coords.accuracy + " meters accuracy";
        }

        // place the pushpin in the map for the location found

        function PlacePushPin(lat, lon) {
            latlong = new VELatLong(lat, lon);
            myPushPin = new VEShape(VEShapeType.Pushpin, latlong);
            map.AddShape(myPushPin);
            map.SetCenterAndZoom(latlong, 15);
        }

        // error handler
        function displayError(error) {

            var errorTypes = {
                0: "Unknown Error",
                1: "Permission denied by user",
                2: "Position is not available",
                3: "Request timed out"
            };

            var errorMessage = errorTypes[error.code];

            if (error.code == 0 || error.code == 2) {
                errorMessage = errorMessage + " " + error.message;
            }

            var divLocation = document.getElementById('location');
            divLocation.innerHTML = errorMessage;
        }
    </script>
</head>
<body>
    <div id="location"></div>
    <div id='myMap' style='position: relative; width: 600px; height: 250px;'>
    </div>
</body>
</html>

Bye.

Cleared MB2-867 CRM 2011 Installation and Configuration Exam


Hi,

Yesterday i cleared the installation and configuration exam of CRM 2011. There were 74 questions in it and 140 minutes to answer them.

Most of the questions were on system requirements while installing Microsoft Dynamics CRM 2011, Outlook, Email Router.

If we remember the below points we can easily answer around 40 questions correctly.

Microsoft Dynamics CRM Server 2011 E-Mail Router

can be installed on computers running

  • Windows 7 32-bit, 64-bit editions.  (32 bit version of router on Windows 7 32-bit)
  • Windows Server 2008 or later 64-bit editions.

can work with following e-mail systems

  • Microsoft Exchange 2003, 2007, 2010, Online.
  • SMTP servers for outgoing.
  • POP3 complaint server for incoming.

Microsoft Dynamics CRM for Outlook is supported on

  • Window 7 RTM (32-bit and 64-bit)
  • Windows Vista SP1 (32-bit and 64-bit) SP1
  • Windows XP Professional SP3, Professional x64 SP2, Tablet PC SP3 Edition.

Supported version of Microsoft Office Outlook

  • Office 2010 RTM
  • Office 2007 SP2
  • Office 2003 SP3

IE Version Supported for Microsoft Dynamic CRM for Outlook

  • IE 7, 8, 9.

Microsoft Dynamics CRM 2011 Server can be installed on following Windows Server  (only 64-bit versions)

  • Windows Server 2008 Standard, Enterprise, Datacenter – SP2
  • Windows Web Server 2008 – SP2
  • Windows Small Business Server Premium, Standard – RTM.

Supported SQL Server Editions (only 64-bit)

SQL Server 2008 Standard, Enterprise, Datacenter, Developer all SP1.

  • Microsoft Dynamics Reporting Extensions setup must be run on a computer that has SQL Server 2008 Reporting Services installed.
  • Microsoft Dynamics CRM Report Authoring Extension must be installed on the computer where SQL Server   is installed.
  • Understand how Claim Based Authentication and IFD are configured for Microsoft Dynamics CRM 2011.

Read about permission required while installing CRM 2011.

Minimum permissions required for Microsoft Dynamics CRM Setup, services, and components.

 To remember the above points  i also created a small mind map as well.



Hope it helps.


Error “A Microsoft Dynamic CRM service has been disabled or has not yet started” while configuring Microsoft Dynamics CRM for Outlook.


Got this issue while configuring Microsoft Dynamics CRM for Outlook for CRM Online.

It was because of the following service being disabled.

Enabling the service resolved the issue.

Hope it helps.