Is this a bug in Wicket?

2009-03-05 Thread rjilani

Hi: Gurus, I am trying to render a form and looks like wicket is not
rendering the form elements in right sequence, here is my markup that is
having the issues

 tr
tdSearch feed by name:/td
tdinput type=text wicket:id=feedName//td
/tr

tr

tdinput  type=radio / Match all
conditions/td
tdinput  type=radio / Match any
conditions/td
tdinput  type=radio / Match all news /td

/tr


here is the java code 

  add(new TextField(feedName, new Model()));

add(new RadioChoice(conditionChoice, new
Model(),conditionChoices ).setSuffix());

when I run the code I see the radio button choices before the text field;
any suggestions?

Thanks,
RJ.
-- 
View this message in context: 
http://www.nabble.com/Is-this-a-bug-in-Wicket--tp22356116p22356116.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Is this a bug in Wicket?

2009-03-05 Thread rjilani

Mattler thanks for the tip, It did work like a charm, but I am bit confuse
about this behavior.

Regards,
RJ.


rmattler wrote:
 
 Don't put the input  type=radio /  in a td.
 
 Should be:
 
 
 
tr
 tdSearch feed by name:/td
 tdinput type=text wicket:id=feedName//td
 /tr
 
 tr
  td
   
 input  type=radio / Match all
 conditions
 input  type=radio / Match any
 conditions
 input  type=radio / Match all news

 
 /td
 /tr
 
 
 
 
 rjilani wrote:
 
 Hi: Gurus, I am trying to render a form and looks like wicket is not
 rendering the form elements in right sequence, here is my markup that is
 having the issues
 
  tr
 tdSearch feed by name:/td
 tdinput type=text
 wicket:id=feedName//td
 /tr
 
 tr
 
 tdinput  type=radio / Match all
 conditions/td
 tdinput  type=radio / Match any
 conditions/td
 tdinput  type=radio / Match all news /td
 
 /tr
 
 
 here is the java code 
 
   add(new TextField(feedName, new Model()));
 
 add(new RadioChoice(conditionChoice, new
 Model(),conditionChoices ).setSuffix());
 
 when I run the code I see the radio button choices before the text field;
 any suggestions?
 
 Thanks,
 RJ.
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Is-this-a-bug-in-Wicket--tp22356116p22356811.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



No get method defined for class error

2009-02-20 Thread rjilani

Hi: guys I am getting No get method defined for class RegisteredUser
expression: countryList when I try to execute this code

registeredUser = new RegisteredUser();
Address address = new Address();
registeredUser.setAddress(address);
model = new CompoundPropertyModel(registeredUser);
setModel(model);
add(new TextField(firstName, model.bind(firstName)));
add(new TextField(lastName, model.bind(lastName)));
add(new TextField(userName, model.bind(userName)));
add(new TextField(emailAddress, model.bind(email)));
add(new PasswordTextField(password, model.bind(password)));


DropDownChoice countryList = new DropDownChoice(countryList,
model.bind(address.country));
countryList.setChoices(new AbstractReadOnlyModel() {

public Object getObject() {
List list = null;
try {

}
});

I don't understand why the errors happens at DropDownChoice even though the
model object has a complex property address that in turn has a property
called country. I am not sure what I am missing here

Thanks,
RJ


-- 
View this message in context: 
http://www.nabble.com/No-get-method-defined-for-class-error-tp22130142p22130142.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: sepearte stylesheet refrences for page and panel

2009-02-19 Thread rjilani

Hi: Jeremy sorry for the late reply, HeaderContributor is now working, the
reason it was not working before because I didn't pay attention that I had
to use add(HeaderContributor.forCss(RegisteredUserPanel.class,
register.css) ) in my code instead of just
HeaderContributor.forCss(RegisteredUserPanel.class,
register.css) 


Jeremy Thomerson-5 wrote:
 
 HeaderContributor is definitely the standard way of doing this
 (StyleSheetReference is only used once in all of Wicket code).  I would
 suggest figuring out how to get the HeaderContributor working.  Open a new
 thread on what's not working, and paste your code (where you add the HC in
 java and your HTML for your base page template that all your other pages
 extend from, if you have one, or any page that you added the HC to).
 
 If you don't figure out why HeaderContributor isn't working, it is likely
 that other Wicket extensions and components will not work because they
 will
 not be able to contribute their JS or CSS to the head.
 
 -- 
 Jeremy Thomerson
 http://www.wickettraining.com
 
 On Wed, Feb 18, 2009 at 4:05 PM, rjilani jil...@lifebiosystems.com
 wrote:
 

 Thanks Jeremy for your suggestions. You were right the wicket link for
 style
 sheet was not in wicket:panel tag and putting the link under panel tag
 resolved the issue.

 One other observation though and it worked too, I put both the style
 sheet
 linked at the page level and added both the refrences in the constructor
 of
 the page and vola it worked. E.g

 link wicket:id=stylesheet/
 link wicket:id=stylesheetPanel/

 add(new StyleSheetReference(stylesheet, PBNASLogin.class,
 login.css));
 in page constructor

 add(new StyleSheetReference(stylesheetPanel, RegisteredUserPanel.class,
 register.css)); //in page constructor too

 BTW even though HeaderContributor.forCss looks the most elegant solution,
 it
 never worked for me.

 Regards,
 RJ.



 Jeremy Thomerson-5 wrote:
 
  Your error didn't include WHICH components failed to render.  Here are
 a
  couple suggestions:
 
  1 - in your panel, is the link tag inside the wicket:panel tag -
 this
  would be my first guess as to your problem.
  2 - why not just use
 HeaderContributor.forCss(RegisteredUserPanel.class,
  register.css) in your panel (and the same in your page) - these will
 add
  the link for you, and in the head, where it should be.  You don't have
 to
  put a component in the page then.
 
  --
  Jeremy Thomerson
  http://www.wickettraining.com
 
 
  On Wed, Feb 18, 2009 at 3:31 PM, rjilani jil...@lifebiosystems.com
  wrote:
 
 
  Hi: Gurus, I am attaching two separate style sheets one for a page and
  one
  for the panel.
 
  I am attaching the style sheets in my Java code  like this
 
   add(new StyleSheetReference(stylesheet, PBNASLogin.class,
  login.css));
  //in page constructor
 
   add(new StyleSheetReference(stylesheetPanel,
  RegisteredUserPanel.class,
  register.css)); //in panel constructor
 
  here is the html mark up for page and panel respectively
 
  link wicket:id=stylesheet/
  link wicket:id=stylesheetPanel/
 
  but when I run the code I got the following wicket error
 
  The component(s) below failed to render. A common problem is that you
  have
  added a component in code but forgot to reference it in the markup
 (thus
  the
  component will never be rendered)
 
  My question is that is it possible to add 2 separate style sheets in a
  parent child markup, if yes, what is the root cause of the above
 error.
 
  Thanks,
  RJ.
  --
  View this message in context:
 
 http://www.nabble.com/sepearte-stylesheet-refrences-for-page-and-panel-tp22088667p22088667.html
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
  -
  To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 
 

 --
 View this message in context:
 http://www.nabble.com/sepearte-stylesheet-refrences-for-page-and-panel-tp22088667p22089319.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org


 
 

-- 
View this message in context: 
http://www.nabble.com/sepearte-stylesheet-refrences-for-page-and-panel-tp22088667p22103261.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket newbie - Quickstart help required

2009-02-19 Thread rjilani

Would you please make sure what version of Java are you using. Annotaions are
only supported from version 1.5 and forward.

Regards,
RJ.


nicgould wrote:
 
 Hi there,
 
 I set up a wicket 1.3.5 project using the quickstart instructions from
 wicket.apache.org. I successfully got the test page up and running using
 Jetty.
 
 I tried adding a basic form with a textbox to the page using code taken
 from Wicket in Action. However when recompiling I got the following error
 from Maven:
 
 [INFO] Compilation failure
  
 /home/nic/myproject/src/main/java/com/mycompany/HomePage.java:[29,4]
 annotations are not supported in -source 1.3
 (use -source 5 or higher to enable annotations)
   @override
 
 This is my first foray into Wicket so apologies if this is an obvious
 error - I searched the list first but couldn't find anything that looked
 like the same issue. I'd be grateful for any assistance anyone can offer.
 
 I am using Wicket 1.3.5, Java 1.6 on Linux and Maven 2.0.9 and my Homepage
 constructor now looks like this:
 
 public HomePage(final PageParameters parameters) {
 
 // Add the simplest type of label
 add(new Label(message, If you see this message wicket is
 properly configured and running));
   
   //Member lookup form
   Form memform = new Form(memform){
 @override
 protected void onSubmit(){
   System.out.println(Form onSubmit is called);
 }
   };
   add(memform);
   form.add(new TextField(memname, new Model()));
   form.add(new Button(membutton, new Model(Go)){
 @override
 public void onSubmit(){
   System.out.println(Mem button clicked);
 }
   });
 
 // TODO Add your page's components here
 }
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Wicket-newbie---Quickstart-help-required-tp22102144p22103741.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Making an invisible panel visible via AjaxLink

2009-02-19 Thread rjilani

Hi: Gurus I am trying to make an invisible panel visible via Ajax link, but
got stuck at a point where I don't know how to proceed further. Please see
the code snipet below

final RegisteredUserPanel registeredUserPanel = new
RegisteredUserPanel(registrationPanel);

add(registeredUserPanel);
registeredUserPanel.setOutputMarkupId(true);
registeredUserPanel.setVisible(false);

add(new AjaxLink(registerLink) {

@Override
public void onClick(AjaxRequestTarget target) {
registeredUserPanel.setVisible(true);
target.addComponent(registeredUserPanel);
}
});

the problem is that when I call registeredUserPanel.setVisible(false),
becuase by defualt I don't want this pannel to be visible; the wicket don't
render the html markup for the pannel at all and hence the ajax calls fails
becuase it don't find the markup to render the panel. Any suggestions how to
tackle a situation like this.

Regards,
RJ
-- 
View this message in context: 
http://www.nabble.com/Making-an-invisible-panel-visible-via-AjaxLink-tp22103906p22103906.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Making an invisible panel visible via AjaxLink

2009-02-19 Thread rjilani

Thanks Michael the trick worked like a charm. 

Best Regards,
RJ.


Michael Sparer wrote:
 
 put the panel in an additional container and add this container
 
 WebmarkupContainer div = new WebmarkupContainer(cont);
 div.setOutputMarkupId(true);
 div.add(registeredUserPanel.setVisible(false));
 
 then in the onclick stuff
 registeredUserPanel.setVisible(true);
 target.addComponent(div);
 
 that should do the trick
 
 hth,
 michael
 
 
 rjilani wrote:
 
 Hi: Gurus I am trying to make an invisible panel visible via Ajax link,
 but got stuck at a point where I don't know how to proceed further.
 Please see the code snipet below
 
 final RegisteredUserPanel registeredUserPanel = new
 RegisteredUserPanel(registrationPanel);
 
 add(registeredUserPanel);
 registeredUserPanel.setOutputMarkupId(true);
 registeredUserPanel.setVisible(false);
 
 add(new AjaxLink(registerLink) {
 
 @Override
 public void onClick(AjaxRequestTarget target) {
 registeredUserPanel.setVisible(true);
 target.addComponent(registeredUserPanel);
 }
 });
 
 the problem is that when I call registeredUserPanel.setVisible(false),
 becuase by defualt I don't want this pannel to be visible; the wicket
 don't render the html markup for the pannel at all and hence the ajax
 calls fails becuase it don't find the markup to render the panel. Any
 suggestions how to tackle a situation like this.
 
 Regards,
 RJ
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Making-an-invisible-panel-visible-via-AjaxLink-tp22103906p22104436.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Making an invisible panel visible via AjaxLink

2009-02-19 Thread rjilani

Thanks Martijn it was cute:-) next time I remember it.

BTW my Kudos to you for writing such an awesome book on Wicket. Really good
work.

Best Regards,
RJ.


Martijn Dashorst wrote:
 
 http://tinyurl.com/dmhfub
 
 On Thu, Feb 19, 2009 at 5:14 PM, rjilani jil...@lifebiosystems.com
 wrote:

 Hi: Gurus I am trying to make an invisible panel visible via Ajax link,
 but
 got stuck at a point where I don't know how to proceed further. Please
 see
 the code snipet below

 final RegisteredUserPanel registeredUserPanel = new
 RegisteredUserPanel(registrationPanel);

add(registeredUserPanel);
registeredUserPanel.setOutputMarkupId(true);
registeredUserPanel.setVisible(false);

 add(new AjaxLink(registerLink) {

@Override
public void onClick(AjaxRequestTarget target) {
registeredUserPanel.setVisible(true);
target.addComponent(registeredUserPanel);
}
});

 the problem is that when I call registeredUserPanel.setVisible(false),
 becuase by defualt I don't want this pannel to be visible; the wicket
 don't
 render the html markup for the pannel at all and hence the ajax calls
 fails
 becuase it don't find the markup to render the panel. Any suggestions how
 to
 tackle a situation like this.

 Regards,
 RJ
 --
 View this message in context:
 http://www.nabble.com/Making-an-invisible-panel-visible-via-AjaxLink-tp22103906p22103906.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org


 
 
 
 -- 
 Become a Wicket expert, learn from the best: http://wicketinaction.com
 Apache Wicket 1.3.5 is released
 Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.
 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Making-an-invisible-panel-visible-via-AjaxLink-tp22103906p22104606.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



sepearte stylesheet refrences for page and panel

2009-02-18 Thread rjilani

Hi: Gurus, I am attaching two separate style sheets one for a page and one
for the panel.

I am attaching the style sheets in my Java code  like this

 add(new StyleSheetReference(stylesheet, PBNASLogin.class, login.css));
//in page constructor

 add(new StyleSheetReference(stylesheetPanel, RegisteredUserPanel.class,
register.css)); //in panel constructor

here is the html mark up for page and panel respectively

link wicket:id=stylesheet/
link wicket:id=stylesheetPanel/

but when I run the code I got the following wicket error 

The component(s) below failed to render. A common problem is that you have
added a component in code but forgot to reference it in the markup (thus the
component will never be rendered)

My question is that is it possible to add 2 separate style sheets in a
parent child markup, if yes, what is the root cause of the above error.

Thanks,
RJ.
-- 
View this message in context: 
http://www.nabble.com/sepearte-stylesheet-refrences-for-page-and-panel-tp22088667p22088667.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



which jars holds the DatePicker class

2009-01-21 Thread rjilani

Hi: I am using wicker 1.4 rc1, with following libs
wicket-extensions-1.4-rc1.jar, wicket-datetime-1.4-rc1.jar, but now where in
my jar I found the DatePicker class that supposed to be in the package
org.apache.wicket.extensions.yui.calendar.DatePicker. Can some one tell me
where is the jar that holds this class?

I don't want to be a critique, but looks like finding wicket dependencies
are very confusing. I haven't worked with an open source project where
finding dependencies becomes so hard. I am not sure it is poor documentation
or shooting to a moving target, where dependencies are changing all the
time, but at the end it is very frustrating for people who wants to learn
wicket quickly.


Thanks,
RJ.
-- 
View this message in context: 
http://www.nabble.com/which-jars-holds-the-DatePicker-class-tp21590451p21590451.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: which jars holds the DatePicker class

2009-01-21 Thread rjilani

Thanks newgro for the help, I was not finding the DatePicker class while
coding. I think Wicket is an awesome framework but there are room for
improvments to document some of the dependencies more precisely, becuase you
know not every one is using Maven.



Best Regards,
RJ.


Newgro wrote:
 
 It's wicket-datetime-1.4-rc1.jar
 package org.apache.wicket.extensions.yui.calendar;
 
 Maybe you should check classpath or your pom.xml. You didn't showed us 
 your real problem.
 
 HTH
 Per
 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 

-- 
View this message in context: 
http://www.nabble.com/which-jars-holds-the-DatePicker-class-tp21590451p21592831.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



where to find javadoc for wikcet 1.4

2009-01-13 Thread rjilani

Can some one point me where to find the javadoc for wicket 1.4, it is very
confusing/frustrating working with release 1.4 and keep looking for the
Javadoc at wicket side that belongs to version 1.3.2.

Thanks,
Rashid.
-- 
View this message in context: 
http://www.nabble.com/where-to-find-javadoc-for-wikcet-1.4-tp21446463p21446463.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



where to find SpringComponentInjector class

2009-01-06 Thread rjilani

Hi: can some one tell me which jars holds the class SpringComponentInjector.
It doesn't look like the part of the core (I am using netbeans id that has
pre-installed wicket jars). I also appreciate if some one tell me the url
from where I can download the jar containing SpringComponentInjector.

Thanks,
RJ.
-- 
View this message in context: 
http://www.nabble.com/where-to-find-SpringComponentInjector-class-tp21317448p21317448.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



addComponentInstantiationListener method

2009-01-06 Thread rjilani

Hi: I am using the following code from wicket wiki to add a Springcomponent
injector to addComponentInstantiationListener to hook spring application
context, but the code is not compiling. 

addComponentInstantiationListener(new SpringComponentInjector(this, ctx));

When I dug further I found that addComponentInstantiationListener accepts a
parameter of type IComponentInstantiationListener and
SpringComponentInjector doesn't implement this interface. Am I missing some
thing? BTW I am using wicket 1.4 rc1 binaries.

Regards,
RJ

 
-- 
View this message in context: 
http://www.nabble.com/addComponentInstantiationListener-method-tp21318461p21318461.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org