Hello,
I want to export the records . A Xml file must be created for every record. But it doesnt work. I created a function on the XML file(GelAllFilters). Firs I call this function after that I export xml file.. Do you have any suggestion about this ?
Thank you
XLabel.RESET;
XLabel.SETRANGE(Resend,TRUE);
IF XLabel.FINDSET THEN
REPEAT
Xfile.CREATE(Filename);
Xfile.CREATEOUTSTREAM(FXOutStream);
XMLSale.GetAllFilters(XLabel."Lot No.",XLabel."Vendor No.",XLabel."Sales Order No.");
XMLSale.EXPORT(); //XMLPORT.EXPORT(60036,XOutStream,FlorecomLabel);
Xfile.CLOSE;
Mail.NewMessage(mailadd,'',
'' + ' ' + 'Subject Info' + ' ' + FORMAT(FileNo),
'',Filename,FALSE);
UNTIL.......
0
Answers
Independent Consultant/Developer
blog: https://dynamicsuser.net/nav/b/ara3n
I sent some parameters to filter.. Like this;
LotNo := CLotNo;
VendorNo := CVendorNo;
SalesOrder := CSalesOrder;
After that I give some filter with these parameters on the table as you see below
X Label - Export::OnPreXMLItem()
XLabel.SETRANGE("Lot No.",LotNo);
XLabel.SETRANGE("Vendor No.",VendorNo);
XLabel.SETRANGE("Sales Order No.",SalesOrder);
Thank you
you were missing
XMLSale.SETDESTINATION( FXOutStream);
I'm curios by this line
X Label - Export::OnPreXMLItem()
in xml you cannot have spaces in the xmltags. Your has a space in tag.
Also XLabel is a global variable? or is it declared as data source?
Btw it works for me.
Independent Consultant/Developer
blog: https://dynamicsuser.net/nav/b/ara3n
First thank you for your answers
TagName DataSource SourceType TagType
PutRequestDetails <X Label Message>(X Label Message) Table Element
GetAllFilters(CLotNo : Code[20];CVendorNo : Code[20];CSalesOrder : Code[20])
LotNo(global variable) := CLotNo;
VendorNo(global variable) := CVendorNo;
SalesOrder (global variable) := CSalesOrder;
PutRequestDetails - Export::OnPreXMLItem()
"X Label Message".SETRANGE("Lot No.",LotNo);
"X Label Message".SETRANGE("Vendor No.",VendorNo);
"X Label Message".SETRANGE("Sales Order No.",SalesOrder);
I think they are clear...
I added destination but it didnt work
Thank you
Take a look at the example and compare to your objects. The fob contains two objects in 50005 report and 50005 xmlport.
\
http://sites.google.com/site/ara3nfiles ... edirects=0
Independent Consultant/Developer
blog: https://dynamicsuser.net/nav/b/ara3n
This is the problem ; I used CLEARAL on preXMLProt . I didnt notice this
I deleted it.It works correctly..
Thank you for your help
viewtopic.php?f=23&t=22279&p=166992#p166992
Independent Consultant/Developer
blog: https://dynamicsuser.net/nav/b/ara3n
Is there any way to apply table filter for Multiple dataitem (table) as we do in report/dataport ?
Example :
I have one XMLport with 3 dataitem with no links
Table1
Table2
Table3
I want to apply filters for each of this tables when calling a XMLport.
in those function copy the filters to the local table 1, table 3 and table 3.
Independent Consultant/Developer
blog: https://dynamicsuser.net/nav/b/ara3n
Thanks for the solution, worked well for me.