Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8245057
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T22:03:52+00:00 2026-06-07T22:03:52+00:00

I am trying to build an JSF library control for XPages based on the

  • 0

I am trying to build an JSF library control for XPages based on the examples by Keith Strickland.

http://xprentice.gbs.com/A55BAC/keithstric.nsf/default.xsp?documentId=82770C11FA7B9B21852579C100581766

I am trying to create a function which creates an InputBox control with an attached DatePicker control.

here is code that I have tried :

    XspInputText inputText = new XspInputText();
    inputText.setId("inputText1");

    DateTimeConverter converter = new DateTimeConverter();
    converter.setType("date");
    inputText.setConverter(converter);
    XspDateTimeHelper dateTimeHelper = new XspDateTimeHelper();

    dateTimeHelper.setId("dateTimeHelper1");
    inputText.getChildren().add(dateTimeHelper);
    inputText.setRendered(true);
    this.getChildren().add(inputText);

The InputText control is rendered but the Converter, Validator and DatePicker button are not rendered.

Hi the answer from Keith solved the problem but now I had an other. I have tryed to add the inputtext to an fromtable from the exlib. Without the formtable arround the “DateTimePicker” is rendered correctly, but with the Formtable it is only rendered as a textfield.

here is the complete code:

    public class Libcontrol extends UIComponentBase implements FacesComponent {

            private static final String RENDERER_TYPE = "de.chris.Libcontrol ";
            private static final String COMPONENT_FAMILY = "de.chris";

            public void CommonContactInfo() {
                    setRendererType(RENDERER_TYPE);
            }

            @Override
            public String getFamily() {
                    return COMPONENT_FAMILY;
            }



            @SuppressWarnings("unchecked")
            public void initBeforeContents(FacesContext arg0) throws FacesException {


                    UIFormTable table = new UIFormTable();
                    table.setId("mytable");
                    table.setDisableRowError(false);
                    table.setDisableErrorSummary(true);
                    table.setLabelPosition("left");

                    UIFormLayoutRow row = new UIFormLayoutRow();
                    row.setId("myrow");
                    row.setLabel("DATEROW");

                    XspInputText inputText = new XspInputText();
                    inputText.setId("inputText1");

                    DateTimeConverter converter = new DateTimeConverter();
                    converter.setType("date");
                    inputText.setConverter(converter);
                    XspDateTimeHelper dateTimeHelper = new XspDateTimeHelper();

                    dateTimeHelper.setId("dateTimeHelper1");
                    inputText.getChildren().add(dateTimeHelper);
                    inputText.setRendered(true);
                    this.getChildren().add(inputText);


                    row.getChildren().add(inputText);
                    table.getChildren().add(row);

                    this.getChildren().add(table);


            }

            public void buildContents(FacesContext arg0, FacesComponentBuilder arg1) throws FacesException {
            // Do Nothing
            }

            /**
            * This method must be present because we're implementing FacesComponent
            */
            public void initAfterContents(FacesContext arg0) throws FacesException {
            // Do nothing
            }
    }

I’m not sure where the problem is, any ideas?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T22:03:53+00:00Added an answer on June 7, 2026 at 10:03 pm

    OK, think I may have found your issue. On the XPage/Custom Control itself, set the properties for:

    dojoParseOnLoad=true

    dojoTheme=true

    or, if you don’t want to set those properties in your XPage/Custom Control you can do it in the renderer encodeBegin with the following lines somewhere before the call to super.encodeBegin():

    //Here context = FacesContext or FacesContext.getCurrentInstance();
    UIViewRootEx rootEx = (UIViewRootEx) context.getViewRoot();
    rootEx.setDojoParseOnLoad(true);
    rootEx.setDojoTheme(true);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to build sample JSF 2 based autocomplete form. I am using
I'm trying to build JSF application and I'm using hibernate as ORM solution. The
I'm trying to build a POC to migrate a heavy JSF application to a
I am trying to build a navigation tree via recursion in JSF. I have
I'm trying to build an Java EE 6-application on GlassFish V3, using JSF 2.0,
I'm trying to deploy a JSF based application to Tomcat 6. The way my
We are trying to build a JSF application with JPA. For now, we want
Trying to build my own user control: <%@ Control Language=C# AutoEventWireup=true CodeFile=TabMenu.ascx.cs Inherits=TabMenu %>
Trying to build a linq query based on parameters a user selects (reporting) but
Trying to build a shopping cart based on the Agile Web Development 4th edition.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.