Quantcast
Channel: CRM Development forum
Viewing all articles
Browse latest Browse all 8223

Post Custom Message to Azure Service Bus Queue

$
0
0

Hi,

I need to post a custom brokered message to Azure Service bus queue on create of a contact

My DTO looks like 

Plublic Class Contact

{

public string name {get;set;}

public string lastname {get;set;}

}

I tried using the below code

var messagingFactory = MessagingFactory.CreateFromConnectionString("XXXXXXXXXXXXXXXXXXX");
            var queueClient = messagingFactory.CreateQueueClient("crmoutbound");
            var message = new BrokeredMessage(new Contact() { Status = "test status", Reason = "test reason" });
            queueClient.Send(message);

but since it is online even if i ILmerge its giving me security exception.

Is there any other alternative?

Thanks in advance


Viewing all articles
Browse latest Browse all 8223

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>