Tuesday, February 21, 2012

How to Use DeleteRequest to Delete an Entity in Microsoft Dynamics CRM 2011 with VB.NET

This illustration shows how to use DeleteRequest to delete an entity in Microsoft Dynamics CRM 2011 with VB.NET

Ok, here is what the code looks like!

In VB.NET

Dim req As New DeleteRequest()
req.Target = New EntityReference("account", New Guid("72876387-9E5C-E111-B314-1CC1DEF1353B"))
Dim resp As DeleteResponse = DirectCast(service.Execute(req), DeleteResponse)


Thats all there is to it!
-

No comments:

Post a Comment