Estou tentando colocar as informações dos veículos no CTe, porém ocorre a seguinte rejeição:
Grupo de informações do veiculo deve ser informado para carga lotação.
Abaixo o código fonte e em anexo o XML. Se alguém conseguir me ajudar fico agradecido.
if (lotacao.ItemIndex = 1) then
infCTeNorm.Rodo.Lota := ltNao
else
infCTeNorm.Rodo.Lota := ltSim;
if (lotacao.ItemIndex = 0) then
begin
if (RzDBButtonEdit1.text <> '') AND (RzDBButtonEdit1.text <> '000000')
then
begin
with infCTeNorm.Rodo.veic.add do
begin
cInt := RzDBButtonEdit1.text;
UF := frmmodulo.qrconhecimento.fieldbyname('uf1').asstring;
RENAVAM := frmmodulo.qrconhecimento.fieldbyname
('renavam1').asstring;
placa := frmmodulo.qrconhecimento.fieldbyname('placa1').asstring;
tara := frmmodulo.qrconhecimento.fieldbyname('tara1').asinteger;
capKg := frmmodulo.qrconhecimento.fieldbyname('kg1').asinteger;
capM3 := frmmodulo.qrconhecimento.fieldbyname('m31').asinteger;
tpProp := StrToTpPropriedade(ok,
frmmodulo.qrconhecimento.fieldbyname('tp_proprietario1')
.asstring);
if (ok = false) then
showmessage('Erro tp_proprietario');
tpVeic := StrToTpVeiculo(ok,
frmmodulo.qrconhecimento.fieldbyname('tp_veiculo1').asstring);
if (ok = false) then
showmessage('Erro tp_veiculo');
tpRod := StrToTpRodado(ok,
frmmodulo.qrconhecimento.fieldbyname('tp_rodado1').asstring);
if (ok = false) then
showmessage('Erro tp_rodado');
tpCar := StrToTpCarroceria(ok,
frmmodulo.qrconhecimento.fieldbyname('tp_carroceria1')
.asstring);
if (ok = false) then
showmessage('Erro tp_carroceria');
Prop.CNPJCPF := '05929787964';
Prop.rntrc := '12345678';
Prop.xNome := 'Nome do prop';
Prop.IE := '';
Prop.UF := 'SC';
end;
42150119167716000106570010000000371469789566-cte.xml