Android Question How to show AnotherDatePicker

Discussion in 'Android Questions' started by DanteS, Jun 11, 2015.

  1. DanteS

    DanteS Member Licensed User

    I am programing an interfase to capture and save data about customers. One field to capture is contract date. I found that the AnotherDatePicker is the best control to this task, because it is only necesary to capture the date and send it to a text box.
    My first question is: is it true that this is the better datepicker for this case?
    My second question is:how can I call the datepicker from a textbox, once it gains the focus?
    My interfase is on a data.bal file and I added to the project a date.bal file to show the datepicker.
  2. DonManfred

    DonManfred Expert Licensed User

    Maybe. Maybe not.
    i dont know whether the ADP can be used for EditTexts too or not. Maybe you need to use a label like in the example and then you take the value from the edit... You can take the focus eventsub from the edittext to call the ADP though when the edittext get the focus.
  3. hibrid0

    hibrid0 Active Member Licensed User

  4. DanteS

    DanteS Member Licensed User

    Thank for you early answer guys

    I was trying to do this:
    1. from textbox1__FocusChanged event, show the calendar (layout anotherdatepicker)
    2. select the desired date on the calendar
    3. receive in a magical form the date in textbox1

    Now I know that life is not so easy.
    I think that I need to use the ADP object in my main layout, to call the layout with the calendar, and then read the date from the ADP with maybe ADP.GetDate.

    If this is the way, how can I add the ADP control to my main layout? I only know how to load regular controls.
    If this in not the way, can someone send me an example of an application using the anotherdatepicker?

    The name "anotherdatepicker" sounds like at the beginning of the times existed a firstdatepicker. Where is this control?

    Another question: Is there a library containing the anotherdatepicker?
  5. klaus

    klaus Expert Licensed User

    Did you search in the forum for anotherdatepicker ?
    Probably no, because you would have found it as the first item.
    AnotherDatePicker is a Class and not a Library!
    Look HERE.
    NJDude likes this.
  6. DanteS

    DanteS Member Licensed User


    I found how to load a Custom View
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice