Date Picker Control and Conditional Formatting - InfoPath Dev
in

InfoPath Dev

Date Picker Control and Conditional Formatting

Last post 09-11-2012 05:50 AM by Daniël N. 9 replies.
Page 1 of 1 (10 items)
Sort Posts: Previous Next
  • 01-27-2012 01:39 AM

    Date Picker Control and Conditional Formatting

    Hi,

    I am modifying the SharePoint 2010 New,Edit,View forms in InfoPath 2010 to provide some conditional formatting functionality.  There a number of date controls on the form, and what I am trying to do is unless a tick box is 'ticked' the date control is disabled, i.e. 'Have management been advised?' if no, the date field is disabled, if yes the date field defaults to todays date but the user can enter a new date BUT the problem i am getting is the date picker control doesn't appear when you click on it.

    Other date controls work fine until conditional formatting is applied. It works fine when previewing in InfoPath Filler, but when i publish it back to my SP list it the Date picker control doesn't work. I have switched off the open in dialogue, but this makes no change (kinda figured it wouldn't as it is still opening in InfoPath Forms Services).

    I have toyed with using conditonal formatted sections, but wanted to avoid this if possible.

    Has anyone else experienced this, and if so how did you overcome it?

    Regards,

    Richard Duffy

  • 01-27-2012 07:29 AM In reply to

    Re: Date Picker Control and Conditional Formatting

    Is this a SharePoint list (and a SharePoint list form) and not a Sharepoint Form Library?

    I just want to get an idea of whether we are dealing with a locked schema or not.

    Thanks.

    Ernesto Machado
    Qdabra® Software/ InfoPathDev.com
    The InfoPath Experts – Streamline data gathering to turn process into knowledge.™


  • 01-27-2012 07:49 AM In reply to

    Re: Date Picker Control and Conditional Formatting

    Hi,

    Yes, this is a SharePoint 2010 list and I am using InfoPath 2010 to customise the new item form.

    Richard

  • 01-30-2012 05:48 AM In reply to

    Re: Date Picker Control and Conditional Formatting

    Hi Richard,

    I just tried this in my environment and it worked. In my example, if the Customer Name columns is blank, the Phone Number field is not displayed.

    I'm attaching a screenshot. Please review your form; there may be an error in the condition?

    Hope this helps!


    Ernesto Machado
    Qdabra® Software/ InfoPathDev.com
    The InfoPath Experts – Streamline data gathering to turn process into knowledge.™


  • 01-30-2012 06:58 AM In reply to

    Re: Date Picker Control and Conditional Formatting

    Hi Ernesto,

    Thats not really a helpful answer as you are using text field controls, where I am using Date Picker controls, so not really a like for like comparison.

    The condition in the control is if Manager Selected (which is a tickbox) = false the Disable the control, so it's not a complicated condition.  Then, if Manager Selected = true set the field value to Today's date - again, not a complicated condition.

    Obviously if i remove all the conditions then it works just fine, and it works fine in InfoPath filler (another reason why i know the condition is fine), but when opened in a browser the conditional formatting seems to prevent the calendar date picker dropdown from appearing.

    Richard

  • 01-30-2012 07:28 AM In reply to

    Re: Date Picker Control and Conditional Formatting

    Hi Richard,

    Can you attach the XSN to your next reply? You can do so via the Options tab. I'd like to take a look.

    Thanks!

    Ernesto Machado
    Qdabra® Software/ InfoPathDev.com
    The InfoPath Experts – Streamline data gathering to turn process into knowledge.™


  • 02-01-2012 01:33 AM In reply to

    Re: Date Picker Control and Conditional Formatting

    Hi Ernesto,

    I have added the .xsn

    Richard

  • 02-01-2012 08:27 AM In reply to

    Re: Date Picker Control and Conditional Formatting

    Thanks Richard. Your form looks OK and I can confirm that everything works fine in Preview mode. I can't publish it to test on the browser because of the data connections though.

    So I created another form on my end with a date picker, and I am able to disable the Date Picker based on conditional formatting (dependent on another field).

    I'm not sure what else to recommend, since I cannot reproduce the issue. I would ask whether this is something that is happening for all forms, or if it's an issue isolated to this list and this form. I notice you're using look up fields, and I'm not, so perhaps that's the difference.

    Anyway, I'm sorry I can't be of further help. Good luck!

    Ernesto Machado
    Qdabra® Software/ InfoPathDev.com
    The InfoPath Experts – Streamline data gathering to turn process into knowledge.™


  • 09-11-2012 05:03 AM In reply to

    • Daniël N
    • Not Ranked
      Male
    • Joined on 09-11-2012
    • Netherlands
    • Posts 2

    Re: Date Picker Control and Conditional Formatting

    Ernesto, i think he means the other option "Hide this control", i am having the same trouble over here. It seems that only text fields are able to hide.
    Nothing to report
  • 09-11-2012 05:50 AM In reply to

    • Daniël N
    • Not Ranked
      Male
    • Joined on 09-11-2012
    • Netherlands
    • Posts 2

    Re: Date Picker Control and Conditional Formatting

    Place a section control, and put the date field in the section. use the conditional formating on the section control. Only 1 problem rises, it seems to hide it but it reserves some page space. so don't put all the controls in one section.
    Nothing to report
Page 1 of 1 (10 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.