Survey Forums

HomeHomeSurvey Project ...Survey Project ...DevelopmentDevelopmentFor each this.VoterAnswersFor each this.VoterAnswers
Previous
 
Next
New Post
8/24/2016 4:13 PM
 

I would like to make a loop on each answer from:
this.VoterAnswers

Or is there another way to get all answers from one voter?


 
New Post
8/26/2016 3:27 PM
 

Solved it!

                string sQueryAnswer = "";
                VoterAnswersData dataSet = new Voters().GetVoterAnswers(this.VoterAnswers.Voters[0].VoterId);
                if ((dataSet != null) && (dataSet.Voters.Rows.Count > 0))
                {

                    foreach (System.Data.DataRow dr in dataSet.VotersAnswers.Rows)
                    {
                        sQueryAnswer += "&AID=" + dr["AnswerIDText"].ToString();
                    }
                }

And i have added to the SP also....

A little bit ugly but it works!

 
Previous
 
Next
HomeHomeSurvey Project ...Survey Project ...DevelopmentDevelopmentFor each this.VoterAnswersFor each this.VoterAnswers