Hi Thomas, Your initial code runs just fine in a non-UI thread and I think it belongs just there; I use it myself in a IStartup. It's a one-off action, you don't need to run it every time the view is initialized. Just use it in the IStartup and it'll be fine.
-Panagiotis On Mon, Oct 22, 2012 at 4:05 PM, thomas dolley <[email protected]>wrote: > Hi Jody, > > Thank you for your answer. > > Here is the result of my test > > > If I call local.acquire(MapGraphicService.SERVICE_URL, null); in the > createPartControl of the view I have got the error ( > > java.io.IOException: Unable to connect to any service supporting > mapgraphic:/localhost/mapgraphic > at > net.refractions.udig.catalog.internal.CatalogImpl.acquire(CatalogImpl.java:290) > ) > > If I put the code in an eclipse RCP action or handler and trigger the > action or handler then I've got the error too > > > If I put the code local.acquire(MapGraphicService.SERVICE_URL, null); in > an IStartup class then I have no error. > > > And, I can have an error with > local.acquire(MapGraphicService.SERVICE_URL, null); and be able to get the > ScaleBar. > > > To conclude I'm really confused an I don't really know what to do or to > test. > > At first my need was to be sure that Mapgraphicservice are available in my > view which was not always the case (see > http://lists.refractions.net/pipermail/udig-devel/2012-September/022485.html > ). > > > > Best regards > > > > > Le 18/10/2012 15:15, Jody Garnett a écrit : > > I am confused, I made a quick test case to confirm your issue - and it > passes? > > -- > Jody Garnett > > > > _______________________________________________ > User-friendly Desktop Internet GIS > (uDig)http://udig.refractions.nethttp://lists.refractions.net/mailman/listinfo/udig-devel > > > > -- > Thomas > > > _______________________________________________ > User-friendly Desktop Internet GIS (uDig) > http://udig.refractions.net > http://lists.refractions.net/mailman/listinfo/udig-devel > >
_______________________________________________ User-friendly Desktop Internet GIS (uDig) http://udig.refractions.net http://lists.refractions.net/mailman/listinfo/udig-devel
