Monday, November 26, 2007

Report "Quick campaign" Microsoft Crm 3.0

One thing hard to get is "Quick campaign" report in Microsoft CRM 3.0, and after this litle example, you can work out and try to make a report like Campaign.

select fbo.subject, fap.activitytypecodename, *
from [companyname]_MSCRM.dbo.filteredbulkoperation fbo,
[companyname]_MSCRM.dbo.filteredactivitypointer fap
where fbo.operationtypecodename='Quick Campaign'
and fbo.activityid=fap.regardingobjectid

Wednesday, November 14, 2007

Microsoft CRM in full screen mode

A easy way to look you crm web page like a real aplication, you will like

1º create a shortcut and put the line

"C:\Program Files\Internet Explorer\iexplore.exe" -K http://[server]:5555/loader.aspx

Puf will show a full page.

Saturday, November 10, 2007

Mobile Phone Sharepoint 3.0

To access in sharepoint 3.0 in a mobile phone you need in the url page add "/M" -> for Mobile Phone, example:
"http://[sharepoint site]/M"

This will send you to a ligth access to sharepoint list, the list views can be only acces if you give mobile phone access to views, will not apear by default, on views properties you need to give access.
After this you can have access in mobile phone.

Create Network Folder ms-dos command prompt in active directory

When you have a server and you want use active directory do give some rules and shared permission to some folder, in that rules you can create network folder on you windows explorer to easy acces to folder, here a litle example:

net use drivepath: \\FolderPath\Folder

net use z: \\\Documents

create a map.bat or other file
1. AD in the Organizational Unit of the group you wish to add an unmap folder
2. edit gPolicy then put it in the
3. User COnfiguration
- Windows Setting
- Scripts
-add the Map.bat
4. log off login the user to test it or you can use this lines
net use \\[server name ex: server.companyname.local]\ipc$ /user:[Username] [Password]
to connect

Wednesday, November 07, 2007

Close Selected Letters Microsoft CRM 3.0

one thing that ask me when i was develomp in CRM is close the selected letters i selected in grid, to do this you have to add in isv.config.xml file and add this line

<entity name="activitypointer">
<button title="Close Letter" javascript="doIsvAction('crmGrid', 'closeLetter.htm', 0, '');" winmode="1" winparams="" passparams="1" icon="/_imgs/ico/16_L_remove.gif" tooltip="Close Selected Letters">

After this you can create a html page that call the following javascript and will close the select letters you select in the grid.

var selected = true;
var unselected = true;
function ShowGuids()
if(confirm('Deseja apagar a(s) Carta(s) selecionada(s)?')== true)
if(window.opener == null)

var content = "<table>";
var allRows = window.opener.document.getElementsByTagName("tr");

for(i=0; i<allRows.length; i++)

if (allRows[i].otype=="4207" && allRows[i].className == "gridSelectOn")

var activityid = allRows[i].oid;

var serverUrl = "/mscrmservices/2006";

var xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");

//alert(serverUrl+ "/crmservice.asmx");"POST", serverUrl + "/crmservice.asmx", false);

xmlhttp.setRequestHeader("Content-Type", "text/xml; charset=utf-8")

xmlhttp.setRequestHeader("SOAPAction", "")

xmlhttp.send("<?xml version='1.0' encoding='utf-8'?>"+"\n\n"+"<soap:Envelope"+

' xmlns:soap=""'+

' xmlns:xsi=""'+

' xmlns:xsd="">'+

' <soap:Body>' +

' <Request xsi:type="SetStateLetterRequest"'+

' xmlns=""> '+

' <EntityId>' + activityid + '</EntityId>'+

' <LetterState>Completed</LetterState>'+

' <LetterStatus>4</LetterStatus>'+

' </Request>'+

' </soap:Body>'+

' </soap:Envelope>')

var result = xmlhttp.responseXML.xml;
if (result.indexOf('faultcode') < 0) {'/CRMReports/viewer/drillopen.aspx?ID=' + activityid + '&OTC=4201');

} else {



content += "<tr>";
content += "<td>" + allRows[i].oid + "</td>";
content += "<td>" + allRows[i].otype + "</td>";
content += allRows[i].innerHTML;
content += "</tr>";

content += "</table>";

document.getElementById("area").innerHTML = content;

function ShowSelected()
selected = !selected;

function ShowUnselected()
unselected = !unselected;


How to send SMTP email using Telnet

This is an old method of sending email using Telnet. I've posted it here mostly for a remider to me on exactly how to do this, but thought I would share it with others who may not know of this. This can be useful when testing if a server can successfully send email. For example, I use this to confirm if a SharePoint server can successfully send emails for alerts and notifications.

The items in bold are what you should type.

Start a Telnet session from a command line by entering:
Telnet 25

220 Microsoft ESMTP MAIL Service, Version: 6.0.3790.2499 ready at Thu, 29 Jun 2006 15:59:02 -0600

250 Hello []
mail from:

250 2.1.0 OK
rcpt to:

250 2.1.5

354 Start mail input; end with .
This is a test.
. (enter a dot/period to end the data)

250 2.6.0 Queued mail for delivery

Connection to host lost.