XMLPort Tags

uri84uri84 Member Posts: 30
edited 2014-07-14 in NAV Three Tier
Hi,

I want to ask if someone knows how to do this...

I have an XMLPort and i want to do, that if the value of one tag is empty , the xml skip this tag.

This is because navision when exports an empty tag in xml do:

" <BIC /> " this is correct but i need that nav do <BIC></BIC> like HTML, so... the other option that i thought is skip the tag if value is empty..

The property MinOcurrs will do this?

Thanks!

Comments

  • uri84uri84 Member Posts: 30
    somebody knows if i can do this?
  • Wisa123Wisa123 Member Posts: 308
    This problem was mentioned a few times here on the boards. I also did a little bit of reasearch about this.
    NAV doesnt care about empty Tags, because its still wellformed XML.

    I just ended up writing myself a little Codeunit to do searching and deleting of empty tags, using the file and ( yeah :( ) simple text analysis per text functions.
    I havent seen a better solution yet, sadly.
    Austrian NAV/BC Dev
  • AlkroAlkro Member Posts: 115
    Wisa123 wrote:
    This problem was mentioned a few times here on the boards. I also did a little bit of reasearch about this.
    NAV doesnt care about empty Tags, because its still wellformed XML.

    I just ended up writing myself a little Codeunit to do searching and deleting of empty tags, using the file and ( yeah :( ) simple text analysis per text functions.
    I havent seen a better solution yet, sadly.
    Hi Wisa!

    Could you paste the code?

    Thanks!
Sign In or Register to comment.