try this:

static native String exportMethods() /*-{

$wnd.navigateToPage = function() {
  // ...implemented with JavaScript
  $wnd.alert("yeah yeah yeah");
};

 }-*/;

2010/8/30 myapplicationquestions <[email protected]>

> Hi All,
>
> I have a huge HTML (existing project) and i am trying to incorporte
> some GWT components. I have created a simple method called
> navigateToPage which is written as
>
> static native String navigateToPage() /*-{
>
>   // ...implemented with JavaScript
>   $wnd.alert("yeah yeah yeah");
>
>  }-*/;
>
> from existing html i am trying to call this as
>
> <td><a href="javascript:navigateToPage();">OK TEST IT</a></td>
>
> This gives me an error saying navigateToPage() is undefined. I assume
> this is because of GWT script being compiled. Is there anyway to get
> around this? I cannot modify the page to be wholly GWT.
>
> Please let me know if anyone has faced this issue.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected]<google-web-toolkit%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>


-- 
Guit: Elegant, beautiful, modular and *production ready* gwt applications.

http://code.google.com/p/guit/

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.

Reply via email to