Based on:
https://surveyjs.io

Survey creator to help us to create surveys (Get the JSON content):
https://surveyjs.io/create-survey

Version 1.1

neoSurvey sample app (Customer satisfaction survey)
https://visualneo.com/tutorials/neosurvey

another sample (Quiz):
https://visualneo.com/tutorials/neosurvey2


Description

The neoSurvey plugin for VisualNEO Web provides tools to create and manage interactive surveys and quizzes, allowing developers to collect user responses and track quiz performance. Based on the SurveyJS library, this plugin is ideal for applications that require feedback forms, quizzes, or assessments with real-time data capture and customizable survey options. Here’s an overview of its primary features and usage:

Creating a Survey: The neoSurveyStart command initializes a survey within a specified container using JSON data generated from SurveyJS Creator, providing a flexible structure for various survey types.

    • Command: neoSurveyStart
    • Syntax: neoSurveyStart "objId" theObjectVar callBackSub
      • objId: Container where the survey displays.
      • theObjectVar: JSON object variable containing survey questions and settings.
      • callBackSub: Optional callback subroutine executed after survey completion.

Example:

neoSurveyStart "surveyContainer" "[surveyData]" "onSurveyComplete"

This command starts a survey within surveyContainer, using surveyData for the survey structure and triggering onSurveyComplete when finished​.

Managing Survey Data: The plugin includes commands to retrieve and set survey data, making it easy to handle user responses and reuse survey configurations.

    • Commands:
      • neoSurveyGetData: Retrieves survey results in JSON format.
        • Syntax: neoSurveyGetData "objId" [returnVar]
      • neoSurveySetData: Loads JSON survey data into a survey.
        • Syntax: neoSurveySetData "objId" [dataVar]

Example for Data Retrieval:

neoSurveyGetData "surveyContainer" "[surveyResults]"

This command retrieves the survey responses from surveyContainer and stores them in surveyResults​.

Tracking Quiz Performance: For quizzes, the plugin offers specific commands to assess user performance by retrieving correct and incorrect answer counts.

    • Commands:
      • neoSurveyGetCorrectAnswers: Retrieves the number of correct answers.
      • neoSurveyGetIncorrectAnswers: Retrieves the number of incorrect answers.
      • Syntax: neoSurveyGetCorrectAnswers "objId" [resultVar]

Example:

neoSurveyGetCorrectAnswers "quizContainer" "[correctCount]"

This retrieves the count of correct answers in quizContainer and stores it in correctCount, making it useful for providing feedback in real-time​.

Displaying Quiz Feedback: The neoSurveyShowQuizAnswers command provides users with immediate feedback by highlighting correct and incorrect answers within the quiz interface.

    • Command: neoSurveyShowQuizAnswers
    • Syntax: neoSurveyShowQuizAnswers "objId" "correctText" "incorrectText"
      • correctText: Text to display for correct answers (e.g., “Correct”).
      • incorrectText: Text to display for incorrect answers.

Example:

neoSurveyShowQuizAnswers "quizContainer" "Correct!" "Try Again"

This setup highlights quiz answers in quizContainer, giving users instant feedback based on their responses​.

Practical Applications

The neoSurvey plugin is perfect for:

    • Feedback Collection: Surveys for user feedback or customer satisfaction.
    • Educational Assessments: Quizzes for testing knowledge with score tracking.
    • Interactive Forms: Gathering information from users through customizable forms.

With flexible options for survey creation, data retrieval, and performance tracking, the neoSurvey plugin adds robust interactive and assessment capabilities to VisualNEO Web applications.

neoSurveyStart

Purpose:

Create a Survey. Get the JSON data from:
https://surveyjs.io/create-survey

Category:

neoSurvey

Syntax:

neoSurveyStart "objId" theObjectVar callBackSub

 

objId

Select a Container object

theObjectVar

Object variable with survey definitions

callBackSub

Callback subroutine to send results

 

neoSurveyGetData

Purpose:

Get survey data in JSON format

Category:

neoSurvey

Syntax:

neoSurveyGetData "objId" [returnVar]

 

objId

Container object

returnVar

Variable object to store result

 

neoSurveySetData

Purpose:

Set survey data in JSON format

Category:

neoSurvey

Syntax:

neoSurveySetData "objId" [dataVar]

 

objId

Container object

dataVar

JSON data variable to assign to the Survey

 

neoSurveyGetCorrectAnswers

Purpose:

Get the number of correct answers in a quiz

Category:

neoSurvey

Syntax:

neoSurveyGetCorrectAnswers "objId" [resultVar]

 

objId

Container object

resultVar

Variable to store result

 

neoSurveyGetIncorrectAnswers

Purpose:

Get the number of incorrect answers in a quiz

Category:

neoSurvey

Syntax:

neoSurveyGetIncorrectAnswers "objId" [resultVar]

 

objId

Container object

resultVar

Variable to store result

 

neoSurveySetValue

Purpose:

Set a survey question value

Category:

neoSurvey

Syntax:

neoSurveySetValue "objId" "fieldName" fieldValue

 

objId

Container object

fieldName

Question name

fieldValue

Value

 

neoSurveyGetValue

Purpose:

Get a survey question value

Category:

neoSurvey

Syntax:

neoSurveyGetValue "objId" "fieldName" [resultVar]

 

objId

Container object

fieldName

Question name

resultVar

Variable to store result

 

neoSurveyDisplayMode

Purpose:

Set survey display mode

Category:

neoSurvey

Syntax:

neoSurveyDisplayMode "objId" modeName

 

objId

Container object

modeName

Display mode

 

neoSurveyShowQuizAnswers

Purpose:

Show quiz correct and incorrect answers

Category:

neoSurvey

Syntax:

neoSurveyShowQuizAnswers "objId" "correctText" "incorrectText"

 

objId

Container object

correctText

Correct text (ie: Correct)

incorrectText

Incorrect text (ie: Incorrect)

 

Created with the Personal Edition of HelpNDoc: Transform Your Word Doc into a Professional-Quality eBook with HelpNDoc