الخميس، 26 سبتمبر 2013

The permissions granted to user 'domain\username' are insufficient for performing this operation. (rsAccessDenied)

To Solve this problem do the following:
1- Run IE as Administrator.
2- Open Reporting Service configuration Manager.
3- Click Report Manager URL and open this URLs.
4- Click Folder Setting.
5- Add New Role Assignment with Selecting all roles.
 Now this message will not appeare again.

الأربعاء، 25 سبتمبر 2013

How to call a Dialog in CRM 2011 using Javascript

1- Find the ID of Dialog by Opening the Dialog and press F11 to get the URL. In the URL we could find out the ID of the Dialog.

http://server:5555/Org/sfa/workflow/edit.aspx?id=%7b91871DE4-8D25-4E3C-8772-2FE8605A5637%7d

2- write the following script to open Dialog:
function OpenDialog()
{
var dialogId = "%7b91871DE4-8D25-4E3C-8772-2FE8605A5637%7d";
 var returnValue = showModalDialog("/" + Xrm.Page.context.getOrgUniqueName() + "/cs/dialog/rundialog.aspx?DialogId=" + dialogId + "&EntityName=lead&ObjectId=" + Xrm.Page.data.entity.getId());

//Optional:To save and close entity form as soon as the dialog is closed.
Xrm.Page.data.entity.save("saveandclose");
}

الاثنين، 23 سبتمبر 2013

SQL Server Error: The instance name must be the same as computer name

To solve this proble goto this url:
http://mscrmuk.blogspot.com/2008/10/sql-server-instance-name-must-be-same.html
.......................................................................................................................................................
****************************************************************************
To check if this is the issue, use SQL Management Studio (or Query Analyzer for SQL 2000) to execute the following query:
sp_helpserver
This will return output like the following:
Name,network_name,status,id,collation_name,connect_timeout,query_timeout
ORGNAME,ORIGNAME,rpc,rpc out,use remote collation,0,null,0,0


If the value in the name column does not match the current computer name, then you have to use the following SQL stored procedures to fix the problem. Note that sp_helpserver normally returns one record, but can return more records if you have configured linked servers. If this is the case, it is the row with id=0 that matters.


To change the information you have to first remove the incorrect record, then add the correct one, with the following queries:
sp_dropserver ‘ORIGNAME’ -- where ORIGNAME is the name returned by sp_helpserver
sp_addserver ‘CURRENTNAME’, ‘LOCAL’ – where CURRENTNAME is the current computer name
Restart you computer.

CRM 2011:Web service request SetDataSourceCredentials to Report Server http://ServerName/ReportServer failed with SoapException

This error occur when you try to open report in CRM,to solve this problem do the following:
  1. Give the NetworkService the role Owner and CRMReaderRole in MSCRM_Config Database and your Organization Database.


- Open Reporting Service Configuration Manager and add the current user to Role assignment
- Remove the execution account.





الأربعاء، 18 سبتمبر 2013

CRM 2011: Adding a view to the sitemap

1- Export the Sitemap
2- Add a SubArea to the Sitemap
<SubArea Id="new_Companies" Url="/_root/homepage.aspx?etn=account&viewid=xxxxx-xxxxx-xxxxx">
  <Titles>
    <Title LCID="1033" Title="Companies" />
    <Title LCID="1025" Title="الشركات" />
  </Titles>
</SubArea>
3- Import the new Sitemap

How to Get View Id?

To Get the ID of the view you wish to display, follow these steps:
a- Navigate the the entity you wish to view.
b- Change the view to match the view in question.
c- From the Ribbon, select Copy a Link:
Open Notepad and paste the contents of the clipboard into the document.  you will see something like this:
http://ServerName:5555/TestOrg/main.aspx?etc=1&extraqs=%3fpagemode%3diframe%26sitemappath%3dSFA%257cSFA%257cnav_accts&pagetype=entitylist&viewid=%7b2C598CB7-2E3F-DE11-8035-0050569A36D3%7d&viewtype=1039
d- Copy the text from viewid through the end of the line.
e- Combine that text with the URL shown in Add Subarea to the Sitemap section.


الجمعة، 13 سبتمبر 2013

CRM 2011:Set First Characters of String To UpperCase

function SetCapitalLetters(ControlName) { 
    Xrm.Page.getAttribute(ControlName).addOnChange(function () {
    var newVal = '';  
        var CtrVal = Xrm.Page.getAttribute(ControlName).getValue();
        var CtrValues = CtrVal.split(" ");
        for (var i = 0; i < CtrValues.length; i++) {
            if (newVal == '')
                newVal = CtrValues[i].substr(0, 1).toUpperCase() + CtrValues[i].substr(1, CtrValues[i].length).toLowerCase();
            else
                newVal += ' ' + CtrValues[i].substr(0, 1).toUpperCase() + CtrValues[i].substr(1, CtrValues[i].length).toLowerCase();
        }
        SetValueAttribute(ControlName,newVal);
    });
}

الأحد، 8 سبتمبر 2013

CRM 2011: Access Is Denied (you don't have enough privileges to access Microsoft Dynamics CRM object or perform request....)

SecLib::AccessCheckEx failed. Returned hr = -2147187962, ObjectID: xxxxxxxxxxxx, OwnerId: xxxxxx,  OwnerIdType: 8 and CallingUser: xxxxxxx. ObjectTypeCode: 8, objectBusinessUnitId: xxxxxxxxxx, AccessRights: AppendToAccess Detail:
1- write the following command to SQL server
  Select Name,LogicalName From MetadataSchema.Entity Where ObjectTypeCode=8

2- Go to CRM Security role and select the user role and from the Business Management Tab give the "append" and "append to" for entity user to oirganization.