PROFESSIONAL NEWSGROUPS
WINDEV
,
WEBDEV
and
WINDEV Mobile
Home
|
Recent messages
|
Connect
|
Sign out
|
English
Home
→
WINDEV 25
→
DICAS 2079 - WINDEV_XML_22_LER_DUPLICATAS_NOTAS
DICAS 2079 - WINDEV_XML_22_LER_DUPLICATAS_NOTAS
Started by amarildo, Apr., 19 2019 8:21 PM - No answer
Connect yourself…
amarildo
#1
Registered member
535 messages
Popularité : +14 (14 votes)
Posted on April, 19 2019 - 8:21 PM
BOM DIA,SEJA BEM VINDOS A MAIS UMA VIDEO AULA. ESSA AULA ESTA SENDO GRAVADA NO DIA 19 04 2019. DICA 2079 . VOU MOSTRAR COMO MOSTRAR AS DUPLICATAS DE UM XML NFE.
BON MATIN, BIENVENUE À PLUS DE VIDÉO AULA. CETTE CLASSE EST ENREGISTRÉE LE JOUR 19 04 2019. CONSEIL 2079. Je vais montrer comment montrer les doublons d'un XML NFE.
Buenos días, es bienvenido a otro vídeo AULA. ESTA CLASE ESTA SENDO GRABADA EN EL DÍA 19 04 2019. SUGERENCIA 2079. VUELO MOSTRAR COMO MOSTRAR LAS DOSIFICACIONES DE UN XML NFE.
BON MATIN, BIENVENUE À PLUS DE VIDÉO AULA. CETTE CLASSE EST ENREGISTRÉE LE JOUR 19 04 2019. CONSEIL 2079. Je vais montrer comment montrer les doublons d'un XML NFE.
DICAS 2079 - WINDEV_XML_22_LER_DUPLICATAS_NOTAS
// lendo xml
// DICAS 2079 - WINDEV_XML_22_LER_DUPLICATAS_NOTAS
E
DT_XML
=
fLoadText
(
E
DT_procura_xml
)
// estou lendo o conteudo do xml, que encontramos
XMLDocument
(
"xml_notas"
,
E
DT_XML
)
E
DT_RESULTADO
=
"NATUREZA OPERACAO:"
+
XMLRead
(
"xml_notas"
,
"/nfeProc/NFe/infNFe/ide/natOp"
)
+
CR
E
DT_RESULTADO
+
=
"Emitente:"
+
XMLRead
(
"xml_notas"
,
"/nfeProc/NFe/infNFe/emit/xNome"
)
+
CR
E
DT_RESULTADO
+
=
"Destinatario:"
+
XMLRead
(
"xml_notas"
,
"/nfeProc/NFe/infNFe/dest/xNome"
)
+
CR
E
DT_RESULTADO
+
=
"Total Nota:"
+
XMLRead
(
"xml_notas"
,
"/nfeProc/NFe/infNFe/total/ICMSTot/vNF"
)
+
CR
// ler itens
xml_nfe
is
a
xmlDocument
xml_nfe
=
XMLOpen
(
E
DT_XML
,
fromString
)
det
is xmlNode
// vamos agora percorrer os itens / det
FOR
E
ACH det OF xml_nfe.nfeProc.NFe.infNFe ON det
TableAddLine
(
TABLE_
itens
)
// adicionando iten na tabela
n
N_OCORRENCIA
is int
=
TABLE_
itens
..
Occurrence
// VOU TER O NUMERO ATUAL DA LINHA DA TABELA
TABLE_
itens.COL_01_cProd
[
n
N_OCORRENCIA
]
=
det.prod.cProd
TABLE_
itens.COL_02_xProd
[
n
N_OCORRENCIA
]
=
det.prod.xProd
TABLE_
itens.COL_03_NCM
[
n
N_OCORRENCIA
]
=
det.prod.NCM
TABLE_
itens.COL_04_qCom
[
n
N_OCORRENCIA
]
=
det.prod.qCom
TABLE_
itens.COL_05_vUnCom
[
n
N_OCORRENCIA
]
=
det.prod.vUnCom
TABLE_
itens.COL_06_vProd
[
n
N_OCORRENCIA
]
=
det.prod.vProd
END
// DUPLICATA
XMLFind
(
"xml_notas"
,
Null
,
XMLContinue
+
XMLChildItem
)
TableDeleteAll
(
TABLE_
DUPLICATA
)
nome_tag
is string
=
""
s
Numero_duplicata
is string
=
""
s
Data_vencimento
is string
=
""
s
Valor_duplicata
is string
=
""
WHILE
XMLFound
(
"xml_notas"
)
SWITCH
XMLElementType
(
"xml_notas"
)
CASE
XMLTag
:
nome_tag
=
XMLElementName
(
"xml_notas"
)
SWITCH
nome_tag
CASE
"nDup"
s
Numero_duplicata
=
(
XMLData
(
"xml_notas"
)
)
CASE
"dVenc"
s
Data_vencimento
=
(
XMLData
(
"xml_notas"
)
)
CASE
"vDup"
s
Valor_duplicata
=
(
XMLData
(
"xml_notas"
)
)
OTHER
CASE
END
IF
s
Valor_duplicata
<
>
""
THEN
TableAddLine
(
TABLE_
DUPLICATA
,
s
Numero_duplicata
,
s
Data_vencimento
,
s
Valor_duplicata
)
s
Numero_duplicata
=
""
s
Data_vencimento
=
""
s
Valor_duplicata
=
""
END
END
XMLNext
(
"xml_notas"
)
END
001
2019-02-12
20.26
002
2019-03-14
20.23
ErpMatos - TgsSistemas
skype:amarildo.matos.informatica
email: amarildo.matos@gmail.com
whats: 51984197742
Youtube: Amarildo Matos
http://www.amarildomatos.com.br
www.windev.com
https://www.pcsoft.fr/webinaires.htm…
https://forum.pcsoft.fr/fr-FR/pcsoft.br.windev/page/1.awp
https://www.windev.com/windev/WD-Express.htm
https://www.windev.com/windevmobile/WM-Express.htm
https://groups.google.com/forum/…
http://windevdesenvolvimento.blogspot.com.br/2017/07/menu-blog.html
https://windevdesenvolvimento.blogspot.com/2019/04/dicas-2079-windevxml22lerduplicatasnotas.html
https://groups.google.com/forum/…
https://doc.windev.com/en-US/…
Report
0
0
→ Go back to WINDEV 25
WINDEV 25
Français
English
Español
Portuguesa
Close this window
Search type
Only topics
All the messages
Search period
Any time
Past hour
Past 24 hours
Past week
Past month
Past year
Cancel
Preview of your message
Adding an image
Import an image from a URL
Send an image from a file of your disk
Drop a file or click "Browse..."
or
Cancel
0%
WLanguage
SQL
XML, HTML
JAVA, Javascript
Text