1
我想利用這個管理ADB包裝:https://madb.codeplex.com/ 我安裝了安裝,包裝Managed.Adb.x64C#Madbee託管的Android調試橋
我得到一個例外,我不知道如何與它
處理我Consolenapp看起來
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Managed.Adb;
using System.IO;
namespace ADBManaged
{
class Program
{
static void Main(string[] args)
{
AndroidDebugBridge bridge = AndroidDebugBridge.CreateBridge(@"D:\ADB\ADB.exe", true);
bridge.Start();
GetDevices();
}
private static void GetDevices()
{
foreach (var device in AdbHelper.Instance.GetDevices(AndroidDebugBridge.SocketAddress))
{
System.Console.WriteLine("{0}\t{1}", device.SerialNumber, device.State);
}
}
}
}
異常
其他信息:無法加載文件或sembly'MoreLinq, 版本= 1.1.17511.0,Culture = neutral,PublicKeyToken = 384d532d7e88985d' 或其依賴項之一。找到的程序集的清單定義確實與編程參考不匹配,即 。 (從HRESULT異常:0x80131040)
我檢查了引用和MoreLinq安裝,但似乎與不同的版本v2.0.50727。
我應該降級還是應該怎麼做?
問題解決:我不得不通過Nuget PackageManager手動更新MorelInq – Shazter
仍然收到一些異常在Managed.Adb.dll中發生了類型'System.IO.FileNotFoundException'的第一次機會異常我不知道真正的原因,但似乎仍然有效 – Shazter