Great Ideas. Always Flowing.

We are not happy until you are happy. Client satisfaction guaranteed. Whatever your needs and requirements, we have the skills and resources for the job!

Quick login...


Or... now make it easy with Facebook Integration
Connect via Facebook



Top Sellers

Frustrated over the lack of customization for your user's registration fields? Dynamically setup your DNN Portal with custom registration fields, layout, questions, and other core integration options......

Ultra Video Gallery is a brother product of Ultra Media Gallery, UVG allows you to upload videos in various format and automatically encode them to flv or H264 format, you also can add videos from internet or record live videos from your webcam.

Build high performance, completely customizable data-entry forms and views driven by your DNN and external databases. New built-in tools make it a snap to quickly create data entry forms, data views, and even database tables. Plus, add your own HTML, CSS, Javascript, SQL commands, stored procedures,

The most advanced DotNetNuke shopping cart on the planet. Easy to use e-Commerce, Secure Shopping Cart Software and SEO friendly. B2C / B2B Ecommerce Sites.

One stop solution for events calendar and events registration! FREE DOWNLOAD is available now!

Default value for CheckBox Groups
Last Post 02-05-2013 11:42 AM by Peter. 18 Replies.
AddThis - Bookmarking and Sharing Button Printer Friendly
  •  
  •  
  •  
  •  
  •  
Sort:
PrevPrev NextNext
You are not authorized to post a reply.
Author Messages
PeterUser is Offline
wading in the water
wading in the water
Posts:17
Avatar

--
01-17-2013 10:24 AM
    I've been able to setup DNN User Default values for almost all other kinds of fields by choosing the corresponding DNN User Profile filed in the Advanced Field Options.

    It's only the CheckBox Group type that no matter what I try the checkbox don't get checked even if I got the matching values in the User Profile. 

    Any ideas?
    Ryan BakerinkUser is Offline
    river guide
    river guide
    Posts:1900
    Avatar

    --
    01-17-2013 10:49 AM
    Hello,

    Please note that when gathering the Value of a Checkbox group, all checked checkboxes will store a value into a csv type list.

    For instance, if I have a checkbox group with the short field name of "Answer" with 3 checkboxes:

    * Yes
    * No
    * Maybe

    And if I check all three of them, then the value associated with this checkbox group will be:

    Yes,No,Maybe

    Please note that DNN Profile Properties won't actually store Checkboxes(true or false). You should add a Profile Field that is type String or Text and map your Checkbox group to that field.

    NOTE: The DNN User Default feature will only pull in a default value for the Dynamic Form Question. So upon page load, if there's a value in this field for the user reviewing the page, then the value will be pulled in. This doesn't mean that when you submit the form, the Profile Property will be updated with any alterations that you made to your Checkbox group.

    So my guess is that because you've just created this Profile PRoperty and are mapping to it with a Checkbox group, you're never actually storing the selected checkbox information into the User Profile. Therefore you'll never see the values being pulled in when you load the page.

    You need to create a SQL Completion Event that Updates the Profile Property responsible for storing the Checkbox Group values.

    Please let me know if you have any questions.

    Thanks,

    Ryan
    PeterUser is Offline
    wading in the water
    wading in the water
    Posts:17
    Avatar

    --
    01-17-2013 12:13 PM
    I'm using both the Dynamic Registration module and the Dynamic Form module and the backend DNN Profile field was used to synchronize both forms. The DNN Profile field is setup as a text field and I have created the same CheckBox Group options in both DR and DF.

    I also checked the DNN Profile in the DNN User Accounts and it did indeed store the csv value correctly. The strange thing is DR was able to load the values back into the CheckBox Group correctly but the DF module was not able to load anything at all.
    Ryan BakerinkUser is Offline
    river guide
    river guide
    Posts:1900
    Avatar

    --
    01-17-2013 02:23 PM
    Does your Dynamic Form have initial SQL Binding enabled? It sounds like there is something happening on your form where the value of the Checkbox group is either getting overwritten or an error is occurring before the value is assigned to the textbox.

    Please place the Dynamic Form in debug mode and let me know what you find, relevant to the Checkbox control.

    Thanks,

    Ryan
    PeterUser is Offline
    wading in the water
    wading in the water
    Posts:17
    Avatar

    --
    01-18-2013 07:17 AM
    My form don't have SQL Binding enabled.

    When I put the Dynamic Form in debug mode it shows:

    ***DYNAMIC FORMS DEBUG MODE ON***
    Dynamic Forms Version: 4.10.4.23731
    DotNetNuke Version: 6.0.1
    Web.Config Trust Level: Unrestricted

    Initial Javascript:

    **** Preparing to process all Affected Field Question Events ****

    Could this be related to the version of DNN I'm running (6.0.1)?

    I'm certain the values are being pulled correctly because when I switched the control to a textbox the textbox does show the correct value from the DNN Profile. (The question was "Where you heard about us" and the answer was "tv,radio"

    But when I switch it back to Checkbox Group, it doesn't populate.
    Ryan BakerinkUser is Offline
    river guide
    river guide
    Posts:1900
    Avatar

    --
    01-18-2013 10:45 AM
    Hello,

    Can you please send us the URL to this form as well as Host Credentials to dnnsupport(at)datasprings(dot)com ?

    This type of behavior is strange, however I'm certain that we'll find the fix or at least provide a work around.

    Please let me know if you have any questions.

    Thanks,

    Ryan
    PeterUser is Offline
    wading in the water
    wading in the water
    Posts:17
    Avatar

    --
    01-18-2013 01:00 PM
    Hi,

    We don't have a public facing website setup yet as we're still in the process of getting the forms to work internally.

    I've quickly setup two testing pages on betasprings and hopefully it'll illustrate the question at hand.

    Dynamic Registration is setup at this location (for the sake of testing I've used a textbox field so I know exactly what is being input into DNN profile):

    http://www.betasprings.com/DynamicF...fault.aspx

    Dynamic Forms is setup at this location and both forms are mapped to the same DNN profile property.

    http://www.betasprings.com/DynamicF...fault.aspx

    I've registered an account for testing and put in DR the value:
    apple,banana
    However DF is not populating the corresponding checkboxes.
    Ryan BakerinkUser is Offline
    river guide
    river guide
    Posts:1900
    Avatar

    --
    01-21-2013 05:46 AM
    Hello,

    Dynamic Registration requires that you fully configure it before you can begin creating user accounts. I noticed that your Dynamic Registration module was simply 1 field, which isn't going to work.

    You need to fully configure the Dynamic Registration module to ensure that you can store values into profile properties after creating a DNN User accoutn. Then you can begin extracting the profile value using Dynamic Forms.

    Perhaps your Dynamic Registration module isn't fully configured on your site?

    -Ryan



    PeterUser is Offline
    wading in the water
    wading in the water
    Posts:17
    Avatar

    --
    01-21-2013 07:32 AM
    Hi Ryan,

    I have created the required fields on Dynamic Registration on the betasprings page and added 3 profile properties to the Dynamic Forms page. While the First Name, Last Name and Email (all 3 are textboxes) loaded correctly into the Dynamic Forms, the Favourite Fruit question being a Checkbox Group did not get populated.

    Ryan BakerinkUser is Offline
    river guide
    river guide
    Posts:1900
    Avatar

    --
    01-22-2013 10:36 AM
    Hello Haitai,

    Please do the following for proper testing:

    1.) Build a Dynamic Registration Form with the following fields:
    * Username
    * Password
    * FirstName
    * LastName
    * Email
    ** Answer(checkbox group with values "Yes", "No", "Maybe")

    - All of the fields on the Dynamic Registration form will be mapped to like Profile Properties. Be sure to accomplish that step.

    1b.) Use the Dynamic Registration Module and see if you can successfully create an account using this Registration Form. To verify a successful account creation, go to Admin -> User Accounts an search for the user that you just attempted to create. Is the User Account created? If so, move on to # 2 below. If not, your Dynamic Registration module isn't configured correctly.


    2.) Build a Dynamic Form that has 1 form field:

    * Answer(checkbox group with the values "Yes", "No", "Maybe")

    Map the default question value to the DNN Default of the Profile Field that you created and mapped your Dynamic Registration Answer Registration field to from Step 1.

    3.) Does it work correctly, when you log into the account that you just created, and go to this new Dynamic Form?

    Please let me know if this helps. Let me know how far you can get before you run into difficulty.

    Thanks,

    Ryan
    PeterUser is Offline
    wading in the water
    wading in the water
    Posts:17
    Avatar

    --
    01-22-2013 02:25 PM
    I have created the Dynamic Registration as you have described here:
    http://www.betasprings.com/DynamicF...fault.aspx

    Everything works great with the registration and the profile property that I created (haitaiproperty) stored the value for the new user with Yes,Maybe

    Dynamic Form is setup also as you have described here:
    http://www.betasprings.com/DynamicF...fault.aspx

    And it did not populate any checkboxes even though the matching profile property has value in it.

    I think we can safely leave the registration process out of it for the time being because all we really need to look at is that the Profile Property has the value Yes,Maybe and the corresponding Dynamic Form question is not getting populated.

    Thanks for taking the time to look into this issue.
    Ryan BakerinkUser is Offline
    river guide
    river guide
    Posts:1900
    Avatar

    --
    01-24-2013 06:24 AM
    Hello Haitai,

    I see what you mean. I have tested and confirmed that the expected behavior isn't working for a Checkbox Group.

    However I had provided a workaround specific for this Dynamic Form that you built.

    I used your Registration for to build the following user:
    U: RyanTest123
    P: 1234567

    I also assigned the Administrator role to this user account so that I could see behind the scenes for this user account when interacting with the Dynamic Form.

    Please log in as the account I have created and go to your Dynamic Form:
    http://www.betasprings.com/DynamicF...fault.aspx

    Or Register for a new account(using the Registration module that you built on Beta Springs), authorize that user, then go to the Dynamic Form and you should see your selections checked.


    You'll see that on the Dynamic Form I have a text field which uses a SQL Default Value to obtain the Profile Field value for your profile field named "HaitaiProperty" for the User Logged in. If pushing this to something live, we would convert the type from textbox to hidden so nobody knows it's on the page.

    Then I am using JavaScript to check the checkboxes in the checkbox group based off of the profile field selected values.

    You can find the JavaScript involved under Module Configuration -> Advanced Coding Options -> Custom JavaScript file.

    Please note that this is a viable work around that has been configured to work specifically for the Dynamic Form that you built. You can't simply copy/paste the JavaScript and expect it to work. You'll need to tailor the JavaScript to your Form. The SQL Default Query needs to be tailored as well, to use the correctly PropertyDefinitionID. In the Query 290 is the PropertyDefinitionID for your HaitaiProperty Profile field. This probably won't be the case on your site.

    At the moment this seems to be a bug with Dynamic Forms. I will log this into our Bug tracking system, however this type of item may not be pushed to the top of our list for some time. So I would recommend utilizing the workaround.

    Please review the work around and let me know if you have any questions.

    Thanks,

    Ryan



    PeterUser is Offline
    wading in the water
    wading in the water
    Posts:17
    Avatar

    --
    01-24-2013 08:54 AM
    Hi Ryan,

    Thanks for looking into this issue and logging the bug into the system. However the workaround using client-side javascript will cause other problems during server postback because the checkbox group will reset back to whatever values it had before when the page reloads.

    In our case we use a lot of checkbox groups and required field validators. I've modified the beta springs form and added one required field to illustrate. Let's say you had the values "Yes" and "No" in your profile from before. Now when you do the form again you checked off "Maybe" but forgot to enter a value into a required field. When you submit all the checkbox groups will revert to the original values (Yes and No only). I have checked that Client-Side Javascript Validation is enabled but it is still reloading the page and revert any changes I made due to the javascript workaround.

    And in addition we have also used the Question Events function to show a textbox field that was hidden. You'll notice on the betasprings page that I've setup an event to display a question when you selected "No" in the checkbox group. Not only is it not showing on form load, the javascript workaround messed up the question event that was firing in the back.

    I also wanted to point out that the Date field type also has the same problem of not populating from the profile. Although in the case of Date field I did find a workaround by using a textbox type and jquery datepicker.

    For the two issues that were mentioned regarding the conflict with required field validators and question events while I can potentially simulate those functionalities using client-side javascript, but that would defeat the purpose of purchasing the DF and DR modules in the beginning (to speed up form creation with an out of the box solution).

    It's good that this bug has been logged and that the developers can be aware of it. Hopefully it can be taken care of in the next release. If you know any recent previous release that did not have this bug please let me know so I can downgrade to an earlier version without losing any major functionality.

    Thanks!
    Ryan BakerinkUser is Offline
    river guide
    river guide
    Posts:1900
    Avatar

    --
    01-24-2013 02:16 PM
    Hello Haitai,

    I highly doubt that this fix will make it in the next release/patch for Dynamic Forms,I know that there are several higher prioritized items. This will probably be fixed within a small hotfix.

    My example was illustrating how to assign a Comma Separated List from a Profile Field and check any checkboxes in a checkbox group, based on the profile property values.

    Of course I didn't elaborate further, such as Question Events, refreshing pages, post backs, etc.. because I simply wasn't illustrating this at the time.

    I know that Dynamic Forms 4.1.4 is the latest, stablest version of Dynamic Forms, so I don't believe downgrading will fix the issue here.

    There are basically 3 scenario's that you may want to consider:

    1.) Find a work around, such as I've began demonstrating.
    2.) Wait for a Patch that fixes this, which could literally take months as there are several priorities before this item.
    3.) Explore another product that may not have this type of limitation with a Checkbox Group.

    Please let me know if you have any questions.

    Thanks,

    Ryan



    PeterUser is Offline
    wading in the water
    wading in the water
    Posts:17
    Avatar

    --
    01-25-2013 12:56 PM
    I found a workaround by using the SQL Driven Option and pulling the values from the User Profile table and matching it to the DynamicForms_QuestionOption table. It successfully populated the checkbox groups (yay!) but for some reason the Question Events did not fire.

    Any idea or suggestion on why this is the case?
    Ryan BakerinkUser is Offline
    river guide
    river guide
    Posts:1900
    Avatar

    --
    01-28-2013 04:55 AM
    Hello Haitai,

    Your work around shouldn't have affected your Question Events. Please analyze the Question Event and make sure that it is configured correctly.

    What happens if you enable FireBug for FireFox, and then try to invoke the Question Event? Is an error logged into the FireBug Console?

    If you've never used FireBug, please download it, install it onto FireFox. This plugin is great for debugging.

    Let me know if you have any questions or find any issues.

    -Ryan
    PeterUser is Offline
    wading in the water
    wading in the water
    Posts:17
    Avatar

    --
    01-29-2013 02:03 PM
    I believe it is running okay. Once the page is loaded I can check and uncheck the checkbox group and it does fire the question event to bring up the textbox question. It's only the initial page load that doesn't trigger the Question Event to show the hidden textbox question.

    I was wondering though is there anyway to load the default value into the textbox whenever a question event fires that triggers the display of a hidden texxtbox? Currently AFAIK the textbox always clears itself whenever it gets shown by the question event no matter what you have in there before.

    Thanks.
    Chad NashUser is Offline
    Posts:5260
    Avatar

    --
    01-30-2013 11:46 AM
    Hi. I don't actually think there would be a way to load a default value unless you setup some custom client side events to fire upon initial JavaScript and if the text was blank it could default the text. This would for sure require a client side event though.

    Thanks,

    Chad
    PeterUser is Offline
    wading in the water
    wading in the water
    Posts:17
    Avatar

    --
    02-05-2013 11:42 AM
    Hi,

    Ryan was right. The workaround with SQL Driven Events was not the one causing the Question Events to not fire. It was the checkbox group that didn't work with Question Events. I tested it by using the manual default value option and still it did not fire the Question Events. But once I changed it to use RadioButtons the Question Events was working.

    Thanks.
    You are not authorized to post a reply.


     
     

    Join our mailing list...

    Get current news and events the easy way
    Subscribe Me

    Recent Blogs...

     
    Copyright 2005 - 2011 by Data Springs, Inc.
     
  • film izle
  • 720 izle
  • film
  • sinema izle
  • film makinesi
  • T�rk�e dublaj film
  • film izle
  • film izle
  • baglan film izle
  • sinema izle
  • 1080 film izle
  • film mercegi