private BarCodeType ZxingToBarcode (ZXing.BarcodeFormat format){ foreach(BarCodeType type in Enum.GetValues(typeof(BarCodeType))){ if(format.ToString().Equals(type.ToString())) return type; } return BarCodeType.DEFAULT; }