Great code I have not tried yet but I am certain I will need it by ANDRIY A33IK BUTENKO
|
||||||
|
Great code I have not tried yet but I am certain I will need it by ANDRIY A33IK BUTENKO This is a great piece of code I put together by merging two sets of code. Basically the following creates an IFRAME and formats the IFRAME in a professional manner.
// Builds a string for the source attribute of an IFrame
// Credit is given to Michael Hohne and Andrew Zimmer for the following code. For additional information, please
// refer to his stunnware site: http://www.stunnware.com/crm2/topic.aspx?id=JS27
//for formatting the IFRAME: http://blogs.inetium.com/blogs/azimmer/archive/2010/01/14/crm-displaying-related-entity-in-iframe-slightly-improved.aspx
function GetFrameSource(tabSet, roleOrd) {
if (crmForm.ObjectId != null) {
var roleOrdParamMissing = (typeof(roleOrd) == "undefined") || (roleOrd == null);
var oId = crmForm.ObjectId;
var oType = crmForm.ObjectTypeCode;
var security = crmFormSubmit.crmFormSubmitSecurity.value;
var url = "areas.aspx?oId=" + oId + "&oType=" + oType + "&security=" + security + "&tabSet=" + tabSet;
if (!roleOrdParamMissing) {
url += "&roleOrd=" + roleOrd;
}
return url;
}
else {
return "about:blank";
}
}
// Waits for the content window of the IFrame to be ready
function FixStylingInFrameSource(iframeID) {
// Check the content window's ready state
if (document.getElementById(iframeID).contentWindow.document.readyState
!= "complete") {
// Re-run this function in 10 ticks
window.setTimeout(function() { FixStylingInFrameSource(iframeID) }, 10);
}
// Content window is ready
else {
// Change the background color
document.getElementById(iframeID).contentWindow.document.body.style.backgroundColor = "#eef0f6";
// Remove the left border
document.getElementById(iframeID).contentWindow.document.body.all(0).style.borderLeftStyle = "none";
// Remove padding
document.getElementById(iframeID).contentWindow.document.body.all(0).all(0).all(0).all(0).style.padding = "0px";
// Make the cell the full width of the IFRAME
document.getElementById(iframeID).contentWindow.document.body.all(0).style.width = "102%"
// Show the IFrame
document.getElementById(iframeID).style.display = "block";
}
}
crmForm.all.IFRAME_organizaton_programs.src = GetFrameSource("new_account_organizationswithprograms");
if(crmForm.FormType != 1)
{
FixStylingInFrameSource('IFRAME_organizaton_programs');
}
Found a couple of solutions posted in the MS forums on this post, I had the best luck with the following: To start update new_OpportunityID and new_ContactID with your fields, this example concatenates the Opportunity ID and Contact ID lookup fields. var lookupItemOppID = new Array; lookupItemOppID = crmForm.all.new_OpportunityID.DataValue; var vOpportunityID= (lookupItemOppID[0] != null) ? lookupItemOppID[0].name : ""; var lookupItemConID = new Array; lookupItemConID = crmForm.all.new_ContactID.DataValue; var vContactID= (lookupItemConID[0] != null) ? lookupItemConID[0].name : ""; CrmForm.all.new_name.DataValue = vOpportunityID + " - " + vContactID; This will concatenate two normal fields crmForm.new_fullname.DataValue = crmForm.new_firstname.DataValue + " " + crmForm.new_lastname.DataValue; This will concatenate a lookup field and a normal text field if(crmForm.all.new_abreviationid.DataValue!=null) var nameval=crmForm.all.new_abreviationid.DataValue[0].name; crmForm.all.new_uasi.DataValue=nameval+","+crmForm.all.new_name.DataValue; Then once you have the field completed you will want to force the change to the database. This will be necessary when a user changes one of the values that creates the concatentated field. It will show the change on the form, however it will not force the change to the database. //force the result to the database crmForm.all.DesiredField.ForceSubmit = true Great article on creating a CRM 4.0 test/training organization from your production organizationhttp://www.wipfli.com/BlogPost_MCRM_Blog_8_12_09.aspx Security and Authentication in Microsoft Dynamics CRM: Connectivity and Firewall Port Requirements in On-Premise Deployments This is a great white paper that has come into use for an enterprise solution I am working with on a client site. This document covers Connectivity and Firewall Port Requirements in On-Premise Deployments for Dynamics CRM 4.0.
Made the mistake of leaving the “CRM for Outlook” button my web form before turning users loose into a UAT preparation enviornment. Here is an article on removing the link from the Microsoft Support Site @ http://support.microsoft.com/kb/2004601 This is interesting. Looks like others have been searcing perhaps?
Always a good one to remember. crmForm.new_fullname.DataValue = crmForm.new_firstname.DataValue + " " + crmForm.new_lastname.DataValue Received this note from MS on pre-pided CRM Volume License Keys! In my case I had already copied all instalaltion media over to the new hardware from an old product download. Then I went searcing for my license key to find out its pre-pidded in the Volume Licensing .iso file still on the MS site. To get to the license key you have to break/open the .iso file. I used WinCDemu loaded on another machine to mount the .iso then browsed the results. Here is the txt frm Microsoft directly.
Great article on compatibility between II6 and II7 b y ActiveXperts. http://www.activexperts.com/support/activmonitor/online/ii6metabase/
Just had a strange issue on a development server where I was not able to add a new custom entity? After a little research I found the following two articles on this topic. It seems that an old rollup was the cause, in my case a simple IISRESET did the trick however here are the two dated links. |
||||||
|
Copyright © 2012 Bradley M. Law - All Rights Reserved |
||||||