Archive for the 'Uncategorized' Category

Dynamics CRM Email Routing – LogonIdentityExWithUI problem fix

This post is for self (so that I don’t forget) and for people who are frustrated (like me) while configuring Email Router for CRM 2013 Online.

We are doing a proof of concept for CRM and it required email integration. We thought how hard it is going to configure email router for CRM 2013 since we were using office 365???? We were so wrong!!! It is hard as hell to configure it. Following are the steps:

Pre-Steps before even installing Email Router:

1. Go to Settings -> Users. Select an User -> Go to Administration section -> Click on Mail (Would take you to mail box) -> Now select both Incoming and outgoing to use Server Synchronization or Email Router and Click Approve Email  (This has to be done for every user)

2. Go to Settings -> Business Management -> Queues and do the above step for every element in the queue

Now install the Email Router. Configure the incoming and outgoing emails. In the deployment almost all the sites will tell you to use https://dev.crm.dynamics.com/<orguniquename&gt; and it will never work. Use the following:

https://disco.crm.dynamics.com/<orguniquename&gt;

Hope this helps someone who is facing LogonIdentityExWithUI problem when you give Load Data.

Happy Programming!!!

Cheers,

Raja

Back to Blogging :-)

Its been a while since I did a blog post. Not that I didn’t want to but just that I got extremely busy with my work and didn’t have time to spend on tech blog (usual blogger excuse). I am going to try and get back to writing tech blogs again. In the past few years I have had the opportunity to meet some great people and learn so much from them. I would be blogging about a lot of very interesting things which I found it from tech world and certain gotcha’s and lessons learnt. 

I think I have taken enough time to bore you with my recent past. Stay tuned for some interesting posts in the future.

Cheers,

Raja

Programming Poetry = FAIL

programming and poetry should never ever ever be combined. this does, however, explain jsonp in 26 words.

i have a new friend named jason p.
he likes to consume with me
we call cross-domain
but have to refrain
from POSTing requests
that’s insane

Sigh…

working a new project. no documentation at all. i did find one comment in the code so far which i have shared below.

/* This is terrible logic, but we didn’t know about this until the last minute so there wasn’t time to add to DB */

Bryan

Getting the controlname which caused postback

I am working on a site in which I use a lot of JQuery but there are some pages which I had to use Server Controls and there was a need to get which control caused the postback.  After a bit of searching I found this nice method which did the trick.


private string  getPostBackControlName()
{
 Control control = null;
 //first we will check the "__EVENTTARGET" because if post back made by       the controls
 //which used "_doPostBack" function also available in Request.Form collection.
 string ctrlname = Page.Request.Params["__EVENTTARGET"];
 if (ctrlname != null && ctrlname != String.Empty)
 {
 control = Page.FindControl(ctrlname);
 }
 // if __EVENTTARGET is null, the control is a button type and we need to
 // iterate over the form collection to find it
 else
 {
 string ctrlStr = String.Empty;
 Control c = null;
 foreach (string ctl in Page.Request.Form)
 {
 //handle ImageButton they having an additional "quasi-property" in their Id which identifies
 //mouse x and y coordinates
 if (ctl.EndsWith(".x") || ctl.EndsWith(".y"))
 {
 ctrlStr = ctl.Substring(0, ctl.Length - 2);
 c = Page.FindControl(ctrlStr);
 }
 else
 {
 c = Page.FindControl(ctl);
 }
 if (c is System.Web.UI.WebControls.Button ||
 c is System.Web.UI.WebControls.ImageButton)
 {
 control = c;
 break;
 }
 }
 }
 return control.ID;
}

Happy Programming!!!

Cheers,

Raja

How to add keyboard navigation for Jquery UI Tabs

We make use of Jquery UI a lot and their widgets are just awesome. One feature which was missing in Jquery (correct me if I am wrong) UI tabs was the option to use arrow keys or any key for tab navigation. So wrote this small script to make it happen. This concept can be modified in any manner so that we can give “Google Reader” like keyboard shortcut features in our web page.


$('body').keyup(function(e) {

 var direction = null;

 // handle cursor keys
 if (e.keyCode == 37) {
 // slide left
 direction = 'prev';
 } else if (e.keyCode == 39) {
 // slide right
 direction = 'next';
 }
 if (direction != null) {
 var totaltabs = $('#tabs').tabs('length'); //gettting the total # of tabs
 var selected = $('#tabs').tabs('option', 'selected');//getting the currently selected tab
if (direction == 'next') {
 if (selected <= totaltabs - 1)
 $('#tabs').tabs('select',selected + 1)
 }
 else
 {
 if (selected != 0)
 $('#tabs').tabs('select',selected - 1)
 }
 }
});

Hope this helps.

Happy Programming!!!

Cheers,

Raja

Reports Usage in SSRS

We are using SSRS for all of our reports and we have a dedicated SQL Server just for this purpose. We wanted to see how many reports are being used on a consistent manner so that we can fine tune those reports for performance. Sometime back Ron wrote a simple query that would do this trick. Just found it in my archives and thought of sharing it with you.


SELECT
 c.[name],
 COUNT(*)
FROM
 dbo.ExecutionLog el inner join dbo.Catalog c on
 el.reportid = c.itemid
WHERE
 el.timestart between '20090901' and '20091231'
GROUP BY
 c.[name]

Hope this helps.

Happy Programming!!!

Cheers,

Raja