From 464ef0777b06864b31355388d8a232a2601954a6 Mon Sep 17 00:00:00 2001 From: cris Date: Mon, 13 Dec 2010 12:13:26 +0000 Subject: [PATCH] Patch level : 10 personalizzazione SRM Files correlati : Ricompilazione Demo : [ ] Commento : corretta tabella clineti/articoli/fornitori: posso inserire un solo fornitore git-svn-id: svn://10.65.10.50/branches/R_10_00@21286 c028cbd2-c16b-5b4b-a496-9718f37d4682 --- ps/pd0610100.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/ps/pd0610100.cpp b/ps/pd0610100.cpp index 54720dd70..7d06d7806 100755 --- a/ps/pd0610100.cpp +++ b/ps/pd0610100.cpp @@ -89,8 +89,14 @@ void TTabmod_caf_msk::registra() } else { - const long forn1 = atol(row.get(sheet.cid2index(S_FORN1))); - const long forn2 = atol(row.get(sheet.cid2index(S_FORN2))); + long forn1 = 0; + long forn2 = 0; + const char* s1 = row.get(sheet.cid2index(S_FORN1)); + if (s1 != NULL) + forn1 = atol(s1); + const char* s2 = row.get(sheet.cid2index(S_FORN2)); + if (s2 != NULL) + forn2 = atol(s2); caf.put("CODTAB", codtab); caf.put("I0", forn1); caf.put("I1", forn2);