[英]Microsoft.ServiceBus.dll issue with .Net full profile configuration
[英]ILMerge with Microsoft.Servicebus.dll for CRM plugin
對於所有人的信息,最后我沒有將servicebus dll與插件代碼合並。 我調用了Azure函數(通過使用WebClient的Webhook)。 Azure函數具有servicebus dll和代碼,而不是我的插件。 最終所有要做的插件就是調用此函數。
public static void FileCopy(string source, string dest, string webhookurl)
{
using (var client = new WebClient { Headers = { [HttpRequestHeader.ContentType] = "application/json" } })
{
var paramRecord = new Parameters(source, dest);
var serializer = new DataContractJsonSerializer(typeof (Parameters));
var memoryStream = new MemoryStream();
serializer.WriteObject(memoryStream, paramRecord);
// todo handle the removal of escaped strings better
var jsonObject = Encoding.Default.GetString(memoryStream.ToArray()).Replace(@"\", "");
string response = client.UploadString(webhookurl, jsonObject);
}
}
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.