diff --git a/MTC_Adapter/SCMA/AdapterPLC/Generic.cs b/MTC_Adapter/SCMA/AdapterPLC/Generic.cs index 0fe1695..457806d 100644 --- a/MTC_Adapter/SCMA/AdapterPLC/Generic.cs +++ b/MTC_Adapter/SCMA/AdapterPLC/Generic.cs @@ -4626,7 +4626,7 @@ namespace SCMA.AdapterPLC // gestisco in modalità "lazy" qualsiasi variabile (dividendo x opportuno fattore conversione...) try { - analogVal = tabDatiAnag[idxTab] / utils.CRI("fattDecVA"); + analogVal = (double)tabDatiAnag[idxTab] / (double)utils.CRI("fattDecVA"); } catch (Exception exc) { @@ -4664,7 +4664,7 @@ namespace SCMA.AdapterPLC // gestisco in modalità "lazy" qualsiasi variabile (dividendo x opportuno fattore conversione...) try { - analogVal = tabDatiAnag[idxTab] / utils.CRI("fattDecVA"); + analogVal = (double) tabDatiAnag[idxTab] / (double) utils.CRI("fattDecVA"); } catch (Exception exc) {