Using code in a Infopath form - InfoPath Dev
in

InfoPath Dev

Using code in a Infopath form

Last post 07-21-2010 05:28 PM by Patrick Halstead. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 07-21-2010 04:17 AM

    Using code in a Infopath form

    Hello,

    I'm not sure if this post belongs to General, Newbie or Code, but here we go..

    I am trying to create a questionnaire, that randomizes for example 10 questions out of 40, every time the questionnaire is taken.

    I've found out that I can use Visual Studio to randomize a certain amount of numbers, which I could then use in my form to hide/unhide a certain amount of questions.This is ok, and I can google for the string of code I need, but the problem is that I really don't have an idea how to use this string of code in my Infopath form. I guess I need to make it as a onload event, but how do I bring the random numbers into use?

    This might be an easy task, but I am no coder, and I'm also fairly new to Infopath..

    Thank you!

    -Mikko

  • 07-21-2010 05:28 PM In reply to

    Re: Using code in a Infopath form

    Hi Mikko,

    This is easy to do using the random number generator in C#. Too bad xpath doesn't support it. I've asked my team to add a Random rule to qRules v2.3 which we hope to release at the end of August. We're in beta test mode now. If you want to beta test qRules 2.3 (with the new rad Rand rule), just let us know. If you send feedback on the qRules stuff, we'll give you a 50% discount if you decide to buy the $199 package (includes forum support). qRules requires InfoPath 2007 or 2010.

    The other option is to spend $50 and have someone add the code to your forum. Should not take more than an hour. That option is also available and we'd be happy to provide an InfoPath MVP and expert coder to help you quickly solve the task, but you will get a ton of other goodness if you go the qRules route. We developed this qRules add-in to help all of the InfoPath form creators out there. It includes all of the stuff that requires code so you don't have to worry about writing any code whatsoever. And, of course, if you aren't completely satisfied, we'll refund your purchase.

    Cheers!

     

    Patrick Halstead
    Project Manager at Qdabra
Page 1 of 1 (2 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.