Hi Joakim, If I understand what you're trying to do correctly, it sounds like what you want to do is add a GWT component to an existing application built with handwritten JavaScript. Is that right?
If so, you should be able to accomplish that by taking the following steps: 1) Create an element on the existing application host page that your GWT component can bind itself to. For example, you could create a <div> like so: <div id="myGwtComponent" /> 2) Code up your GWT component. In the component's onModuleLoad() method, instead of attaching the main widget to the page using RootPanel.get().add(mainPanel);, which will attach the component to the body of the page, use RootPanel.get("myGwtComponent").add(mainPanel). This instructs the GWT startup script to attach the component to an existing element with the given id. 3) For any interactions you want to have between your GWT component and the existing application, write interop methods using JSNI (see link below). JavaScript Native Interface (JSNI): http://code.google.com/docreader/#p=google-web-toolkit-doc-1-5&s=google-web-toolkit-doc-1-5&t=DevGuideJavaScriptNativeInterface 4) Finally, as is the usual case, add the <script> tag in your existing application host page referencing the GWT bootstrap script (<module>.nocache.js file). Hope that helps, -Sumit Chandel On Fri, Mar 6, 2009 at 3:19 AM, Joakim Sjöberg < joakim.sjob...@artificial-solutions.com> wrote: > Hello > > > > Can anyone help me out with this? > > > > I am going to do a small demo with GWT that is going to work something like > this: > > > > I will have panels that is on o “template” page, this panels will be empty > and only refer to a JavaScript > that contains panels and information etc. Is this possible? Is there any > solution made like this? > > > > > > *Joakim Sjöberg* > > *Technical Consultant* > > Artificial Solutions Scandinavia AB > > > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post to this group, send email to Google-Web-Toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/Google-Web-Toolkit?hl=en -~----------~----~----~----~------~----~------~--~---