Thank you for the reply.   Yes embarasingly I missed the { }.  I fixed and 
works.  One more question: When will com.google.gwt.i18n.Constants be 
usable in a ui.xml file ??  AFAICT, only TextResources are available !  Am 
I missing something?

thanks, Jon

On Sunday, August 26, 2012 10:51:08 AM UTC-7, jopaki wrote:
>
> I get this error when trying to parse/compile my uiBinder 
> LoginPanel.ui.xml:
>
> Rebinding com.tll.client.ui.LoginPanel.LoginPanel2UiBinder
>    Invoking generator com.google.gwt.uibinder.rebind.UiBinderGenerator
>       [ERROR] Attribute 'from' does not have a computed value Element 
> <ui:text from='res.constants.loginTitle'> (:45)
> [ERROR] Deferred binding failed for 
> 'com.tll.client.ui.LoginPanel.LoginPanel2UiBinder'; expect subsequent 
> failures
>
> *LoginPanel.ui.xml*
> <!DOCTYPE ui:UiBinder SYSTEM "http://dl.google.com/gwt/DTD/xhtml.ent";>
> <ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder" 
> xmlns:g="urn:import:com.google.gwt.user.client.ui">
>   <ui:with field='res' type='com.tll.client.ui.Resources' />
>   <g:HTMLPanel styleName="loginPanel">
>     <form ui:field="form" action="post" 
> target="{res.constants.formLoginTarget}">
>       <div ui:field="title" styleName="title">
>         <ui:text from="res.constants.loginTitle" />
>       </div>
>       <div ui:field="statusMsg" styleName="statusMsg"></div>
>       <table>
>         <tr>
>           <td>
>             <label ui:field="lblUsername" 
> for="{tbUsername.getElement.getId}">
>               <ui:text from="{res.constants.labelUsername}" />
>             </label>
>           </td>
> ...
>
> *LoginPanel.java*
> public class LoginPanel extends Composite implements ClickHandler, 
> SubmitHandler {
>
> private static LoginPanel2UiBinder uiBinder = 
> GWT.create(LoginPanel2UiBinder.class);
>
> interface LoginPanel2UiBinder extends UiBinder<Widget, LoginPanel> {
> }
>
> static enum Mode {
> LOGIN,
> FORGOT_PASSWORD,
> }
>
> Mode mode = Mode.LOGIN; // default
>
> @UiField DivElement title;
> @UiField DivElement statusMsg;
>
> @UiField LabelElement lblUsername;
> @UiField TextBox tbUsername;
> @UiField LabelElement lblPassword;
> @UiField PasswordTextBox tbPassword;
> @UiField Anchor lnkTgl; // toggles btwn view modes
> @UiField Button btnSubmit;
> @UiField FormElement form;
>
> /**
>  * Because this class has a default constructor, it can be used as a binder
>  * template. In other words, it can be used in other *.ui.xml files as
>  * follows: <ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder"
>  * xmlns:g="urn:import:**user's package**">
>  * <g:**UserClassName**>Hello!</g:**UserClassName> </ui:UiBinder> Note that
>  * depending on the widget that is used, it may be necessary to implement
>  * HasHTML instead of HasText.
>  */
> public LoginPanel() {
> }
> ...
>
>
> I can't for the life of me figure this out!  Pls help!
>
> -Jon
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-web-toolkit/-/ZLNRXJwX_VgJ.
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