Rank: Newbie
Groups: Registered
Joined: 5/7/2015(UTC) Posts: 7  Location: TOURS
|
hello, I defined a global ressource 'folder' with a collection of xml files ; some of my files are refered in the other with an URI. For use elements of my refered files (here 'title'), i try to do xpath in a label ou button control, like this : Quote:for $x in doc(concat( "sources" , @sc:refUri ) )/sc:item/em:module/em:moduleM return $x/sp:title My global resource folder is 'sources' in folder 'ISTC_Famas' My MTD file is in /ISTC_Famas My default file is 'carnet_FA.xml' in /sources ie : in my default file I refere : Quote:<sp:module sc:refUri="/FA_Fusil_Assaut/module_E/module_E.xml"/> using the XPATH, the error is : Quote:Cannot retrieve resource 'file:///C:/Users/X%20MAQUET/Documents/Altova/MobileTogetherDesigner1/MobileTogetherDesignerExamples/ISTC_Famas/sources/FA_Fusil_Assaut/module_E/module_E.xml'
|
|
|
|
Rank: Administration
Groups: Registered, Administrators Joined: 7/21/2014(UTC) Posts: 494
Was thanked: 87 time(s) in 87 post(s)
|
In MobileTogether the doc() function is intentionally disabled. This is because XPath in most cases runs on clients, whereas files are located somewhere on server and need to be transferred to client.
In order to load files, you need to add them as Page Sources which you can then use in XPath statement. Note - you can reduce network traffic by defining Page Sources as Server only, if this fits in your task.
Altova MobileTogether Experts
|
|
|
|
Rank: Newbie
Groups: Registered
Joined: 5/7/2015(UTC) Posts: 7  Location: TOURS
|
Thanks.
So, how can I add my files by URI, in a page source ? using XSD and XPATH ?
Example: <carnet> <module refUri='/module_A/module_A.xml'/> <module refUri='/module_B/module_B.xml'/> <module refUri='/module_C/module_C.xml'/> </carnet>
I have a page for carnet and module. I need to load all my files on the client, because the users are most of time out of network.
|
|
|
|
Rank: Administration
Groups: Registered, Administrators Joined: 7/21/2014(UTC) Posts: 494
Was thanked: 87 time(s) in 87 post(s)
|
Currently loading via XPath only works for HTTP sources, so if you have a chance to make your files available via HTTP - you can do it already now.
Load from File doesn't have an option to select files via XPath yet - this is on our to do for future releases.
|
|
|
|
Rank: Administration
Groups: Registered, Administrators Joined: 7/21/2014(UTC) Posts: 494
Was thanked: 87 time(s) in 87 post(s)
|
One thing which came to my mind - you could use Altova MapForce to preprocess your input files in all those cases where MobileTogether is not sufficient. MobileTogether natively supports FlowForce sources
|
|
|
|
Rank: Newbie
Groups: Registered
Joined: 5/7/2015(UTC) Posts: 7  Location: TOURS
|
I done it : it's all right now. Just have a question about images in global ressource...another post...
|
|
|
|
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.