How to disable the textbox in the datepicker in Infopath 2007 - InfoPath Dev
in

InfoPath Dev

How to disable the textbox in the datepicker in Infopath 2007

Last post 08-19-2010 09:36 AM by bahrom7893. 4 replies.
Page 1 of 1 (5 items)
Sort Posts: Previous Next
  • 08-18-2010 12:48 PM

    How to disable the textbox in the datepicker in Infopath 2007

    Hi,

    I'm trying to disable the textbox in the datepicker in Infopath, because I want to force users to select a date from the calendar instead of typing it; but when I add conditional formatting with read-only status, the calendar becomes read-only as well as the textbox. How can I make the textbox read-only while allowing the calendar to be edited? Can a pop-up calendar also be an option? I wasn't able to find it anywhere in Infopath. Any help would be appreciated.

    If the you can't disable anything, then how can I achieve this?

    Thank you,

    Bahrom

  • 08-19-2010 12:29 AM In reply to

    Re: How to disable the textbox in the datepicker in Infopath 2007

    Hi Bahrom,

    Here's an idea: change the width of the date picker control to be just large enough to show the datepicker button (~25 px) using datepicker properties. Then, add a read-only expression box (calculated value) to your form just to the left of the datepicker button and set it up to read from  the datepicker field. You can format this as a date by right clicking choosing properties, etc..

    When user clicks datepicker button, it will change the date but they won't be able to type it in.

    Hope this helps!

    Patrick Halstead
    Project Manager at Qdabra
  • 08-19-2010 05:35 AM In reply to

    Re: How to disable the textbox in the datepicker in Infopath 2007

    Thanx a lot, Patrick! I'm finally getting my form to work!

  • 08-19-2010 06:27 AM In reply to

    Re: How to disable the textbox in the datepicker in Infopath 2007

    One more question:

    Do you know how I can make the data validation for start and end dates' months? I want the month of my Start Date be equal to the month of the End Date. If they are not equal to each other, I want my form to give an error.

    Thanks

  • 08-19-2010 09:36 AM In reply to

    Re: How to disable the textbox in the datepicker in Infopath 2007

    Never mind, I got it. I used enddate "does not contain" substring(@startdate,6,2) Thanx for your help!

Page 1 of 1 (5 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.