I am trying to
use LtiLibrary and post grades to all students under
LTI item in the gradebook in Moodle.
For 2 week I have been trying to
figure it out
… How can I get lis_result_sourcedid
with LTI for each student ?
For now, I can post only grade for a student that click on the LTI like so,
var result=LtiLibrary.Core.Outcomes.v1.OutcomesClient.PostScore(Request.Form["lis_outcome_service_url"].ToString(), Request.Form["oauth_consumer_key"].ToString(),
ConfigurationManager.AppSettings["SharedSecret"].ToString(), Request.Form["lis_result_sourcedid"].ToString(),
0.40);
The question is how
can I post grade for a student with id 22 (for example), my id is 35 and I am
trying to replace it,
like so...but it does not allow me to post grade. Any
ideas?
ConfigurationManager.AppSettings["SharedSecret"].ToString(), Request.Form["lis_result_sourcedid"].ToString().Replace("\"userid\":\"35\"", "\"userid\":\"22\""), 0.40);