OnKeyDown Event Handling - InfoPath Dev
in

InfoPath Dev

OnKeyDown Event Handling

Last post 05-24-2012 01:32 PM by patrickli415. 4 replies.
Page 1 of 1 (5 items)
Sort Posts: Previous Next
  • 05-23-2012 10:48 AM

    OnKeyDown Event Handling

    Hello,

     Does anyone how to create an event handler for an OnKeyDown event within a control for an InfoPath 2010 form that is published on a SharePoint 2010 server?  Does it require the use of VSTA?

     

    Thanks!

     

    -Patrick

  • 05-23-2012 10:56 AM In reply to

    Re: OnKeyDown Event Handling

    Unfortunately, to the best of my knowledge, InfoPath doesn't directly support keyboard events.  What is it that you are looking to do?
    Jimmy Rishe / Software Developer / Microsoft MVP
    Qdabra Software
  • 05-23-2012 11:05 AM In reply to

    Re: OnKeyDown Event Handling

    Thanks for the quick response.

     I'm trying to add a prefix to a text field control if the user starts to enter data into the field but also allow for the field to be null if the the field should be null.

  • 05-24-2012 09:51 AM In reply to

    Re: OnKeyDown Event Handling

    How about adding a rule to the field like this:

    Condition: <field> does not begin with <prefix>
    Action: Set <field> to concat('<prefix>', <field>)

    Jimmy Rishe / Software Developer / Microsoft MVP
    Qdabra Software
  • 05-24-2012 01:32 PM In reply to

    Re: OnKeyDown Event Handling

    That worked fantastically!  Thanks for the solution, I guess I was barking up the wrong tree.

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