Thank you for the answer but I already knew about it. My problem is to load sqlmap.config when referenced by dao.config, as well as the providers.config when referenced by dao.config.
Actually my question should be: How can I specify the path to use for resolving the relative paths of the files referenced by dao.config (e.g.: sqlmap.config, providers.config, properties.config). Or How can I specify to resolve such paths relative to the path of dao.config instead of relative to the application working directory. However thank you very much for your kind answer, Matteo ________________________________ Da: Dave Curylo [mailto:dacur...@gmail.com] Per conto di Dave Curylo Inviato: mercoledì 17 marzo 2010 12.49 A: user-cs@ibatis.apache.org Oggetto: Re: How to specify a different path for providers.config To specify an alternative path for sqlmap.config, you can use a similar method as you did for the dao.config, calling DomSqlMapBuilder.ConfigureAndWatch. There is sample code for that here: http://ibatis.apache.org/docs/dotnet/datamapper/ch04s04.html I'm not sure about providers.config; I've only done this with sqlmap.config. I suspect there is another similar API. On Mar 17, 2010, at 7:26 AM, Tontini Matteo wrote: Hello, I've got a .net assembly invoked as a com component from unmanaged code. I'm trying to explicitly specify the path to the Ibatis config file (dao.config) Via DomDaoManagerBuilder.ConfigureAndWatch("pathToDaoConfig", handler) Even if the dao.config file is found, Ibatis cannot find all the other configuration files (providers.config, sqlmap.config) if they are set as relative paths. Debugging Ibatis source code I found that, actually, all the secondary files are searched relative to the working directory of the appdomain (_applicationbase) instead of relative to the main dao.config. Am I right? How can I specify an alternative path for all the configuration files? Thank you very much for your efforts Matteo Tontini Questo messaggio e riservato; il suo contenuto non rappresenta in nessun caso un impegno da parte di AXA Assicurazioni, ad eccezione di quanto previsto in accordi conclusi per iscritto tra voi ed AXA Assicurazioni. Qualsiasi pubblicazione, utilizzo o diffusione, anche parziale di questo messaggio, deve essere preventivamente autorizzata. Nel caso in cui non foste destinatari del presente messaggio,vogliate cortesemente avvertire immediatamente il mittente. Ce message est confidentiel; son contenu ne represente en aucun cas un engagement de la part de AXA Assicurazioni sous reserve de tout accord conclu par ecrit entre vous et AXA Assicurazioni. Toute publication, utilisation ou diffusion, meme partielle, doit etre autorisee prealablement. Si vous n' etes pas destinataire de ce message, merci d'en avertir immediatement l'expediteur. This message is confidential; its contents do not constitute a commitment by AXA Assicurazioni, except where provided for in a written agreement between you and AXA Assicurazioni. Any unauthorised disclosure, use or dissemination, either whole or partial, is prohibited. If you are not the intended recipient of the message, please notify the sender immediately. Questo messaggio e riservato; il suo contenuto non rappresenta in nessun caso un impegno da parte di AXA Assicurazioni, ad eccezione di quanto previsto in accordi conclusi per iscritto tra voi ed AXA Assicurazioni. Qualsiasi pubblicazione, utilizzo o diffusione, anche parziale di questo messaggio, deve essere preventivamente autorizzata. Nel caso in cui non foste destinatari del presente messaggio,vogliate cortesemente avvertire immediatamente il mittente. Ce message est confidentiel; son contenu ne represente en aucun cas un engagement de la part de AXA Assicurazioni sous reserve de tout accord conclu par ecrit entre vous et AXA Assicurazioni. Toute publication, utilisation ou diffusion, meme partielle, doit etre autorisee prealablement. Si vous n' etes pas destinataire de ce message, merci d'en avertir immediatement l'expediteur. This message is confidential; its contents do not constitute a commitment by AXA Assicurazioni, except where provided for in a written agreement between you and AXA Assicurazioni. Any unauthorised disclosure, use or dissemination, either whole or partial, is prohibited. If you are not the intended recipient of the message, please notify the sender immediately.