Setting XML based exam to where there are two correct answers in a question

I have an exam which pulls in questions from an XML file and to indicate what the correct answer is you would indicate in the XML as such:
PROBLEM id="1">
                <QUESTION>What is the State Capital of California:</QUESTION>
                <CHOICE letter="a">San Fransisco.</CHOICE>
                <CHOICE letter="b">San Diego.</CHOICE>
                <CHOICE letter="c">Los Angelas.</CHOICE>
                <CHOICE letter="d" correct="true">Sacremento.</CHOICE>
            </PROBLEM>
There is one question, that is structured so there are two right answers, but when I add correct="true" to both answers I want as right only one is calculated correctly in the scoring. I thinking I need to make an adjustment in the code that pulls in the XML, but not sure where. Hoping someone can help.
Here is the AS code.
package exam {
    import flash.net.* //to create URLRequest and load XML file
    import flash.events.* //for Load events
    //import flash.display.* //for testing purposes - remove when testing complete
    //This class downloads the XML document, and then inserts info into arrays and variables.
    //Also provides text of questions and correct answers when requested.
    internal class XaMLDiplomat extends EventDispatcher {
        //VARIABLES:
        //for loaded XML doc
        private var myXML:XML;
        //for loading in XML
        private var examLoader:URLLoader;
        private var numQstns:Number; //count of total questions in a section
        private var sectStart:Number;
        //contains exam questions - ALL ARRAYS ARE ZERO RELATIVE -> actual question numbers = array index + 1
        private var questions:Array;
        //contain associated answer choices
        private var choiceA:Array;
        private var choiceB:Array;
        private var choiceC:Array;
        private var choiceD:Array;
        private var choiceE:Array;
        private var choiceF:Array;
        //array of the correct answers
        private var answers:Array;
        //use custom Mixer class to randomize order
        private var myMixer:Mixer;
        private var isRandom:Boolean;
        //CONSTRUCTOR
        public function XaMLDiplomat () { //NEED TO ADD ARGUMENTS (docLocation)
            //create URLRequest from argument
            var examSite:URLRequest = new URLRequest("protected/exam.xml");
            //create a loader for the XML
            examLoader = new URLLoader();
            //add listener for load completion
            examLoader.addEventListener(Event.COMPLETE, fullyLoaded);
            examLoader.load(examSite);
            //var ugly:Mixer = new Mixer(25);
        //Load listener - creates XML object, and checks it for multiple sections. If multiple, it asks users
        //which section they want - FIRST it needs to check database for any completed sections.
        //If single, it goes ahead and starts array creation for first (& only) section
        private function fullyLoaded (e:Event):void {
            myXML = new XML(examLoader.data);
            //myXML.prettyPrinting = false;
            //still need to pull out SYSTEM data and pass it along...
            var system:XMLList = myXML..SYSTEM;
            var sysObj:Object = new Object();
            sysObj.examTitle = system.TITLE.toString();
            sysObj.totalMin = system.MINUTES.toString();
            sysObj.retakePW = system.RETAKEPW.toString();
            var numSections:Number = myXML..SECTION.length();
            if (numSections == 1) {
                generateArrays(1);
            dispatchEvent(new MultiSectEvent(MultiSectEvent.SECTIONS, numSections, sysObj));
        //Assigns arrays to instance variables for the selected section
        internal function generateArrays (sectn:Number):void {
            var whichSection:XMLList = myXML..SECTION.(@id == String(sectn));
            var probList:XMLList = whichSection.PROBLEM;
            numQstns = probList.length();
            sectStart = Number(probList[0].@id);
            questions = new Array();
            choiceA = new Array();
            choiceB = new Array();
            choiceC = new Array();
            choiceD = new Array();
            choiceE = new Array();
            choiceF = new Array();
            answers = new Array();
            for (var i:Number=0; i<numQstns; i++) {
                var curProb:XMLList = probList.(@id == String(i+1));
                if (curProb.QUESTION.hasSimpleContent()) {
                    questions[i] = curProb.QUESTION.toString();
                }else {
                    //trace(curProb.QUESTION.toXMLString());
                    questions[i] = dropTags(curProb.QUESTION[0]);
                choiceA[i] = curProb.CHOICE.(@letter == "a").toString();
                choiceB[i] = curProb.CHOICE.(@letter == "b").toString();
                choiceC[i] = curProb.CHOICE.(@letter == "c").toString();
                choiceD[i] = curProb.CHOICE.(@letter == "d").toString();
                choiceE[i] = curProb.CHOICE.(@letter == "e").toString();
                choiceF[i] = curProb.CHOICE.(@letter == "f").toString();
                answers[i] = curProb.CHOICE.(hasOwnProperty("@correct") && @correct == "true")[email protected]();
            //randomizing test
            //var makeRandom:Boolean;
            //system.RANDOM.toString() ==  'true' ? makeRandom = true : makeRandom = false;
            //myMixer = new Mixer(numQstns,makeRandom);
            trace("Question: "+questions[3]);
            trace("a: "+choiceA[3]);
            trace("b: "+choiceB[3]);
            trace("c: "+choiceC[3]);
            trace("d: "+choiceD[3]);
            trace("\r\n answer: "+answers[3]); */
        //method for external classes to acquire text of current exam question
        internal function getQuestion (qnum:Number):Object {
            var returnObj:Object = new Object();
            var randomQ:Number = myMixer.getRandomNumber(qnum-1);
            returnObj.q = questions[randomQ];
            returnObj.ca = choiceA[randomQ];
            returnObj.cb = choiceB[randomQ];
            returnObj.cc = choiceC[randomQ];
            returnObj.cd = choiceD[randomQ];
            returnObj.ce = choiceE[randomQ];
            returnObj.cf = choiceF[randomQ];
            returnObj.num = qnum;
            //trace(randomQ);
            return returnObj;
        private function dropTags (txt:XML):String {
            var txtString:String = "";
            for each (var child:XML in txt.*) {
                if (child.nodeKind == "text") {
                    txtString += child.toString();
                }else {
                    txtString += " " + child.toXMLString();
            //trace(txtString);
            return txtString;
        private function dropTags (txt:String):String {
            var sliceStart:Number = txt.indexOf(">");
            var sliceStop:Number = txt.lastIndexOf("<");
            return txt.slice((sliceStart+1), sliceStop);
        internal function getAnswer (num:Number):String {
            return answers[num];
        internal function getQCount ():Number {
            return numQstns;
        internal function getSectStart():Number {
            return sectStart;
        internal function getRealNum (num:Number):Number {
            return myMixer.getRandomNumber(num-1);

this may or may not be the probel, but as it stands right now, when you select and anser it becomes hi-lighted and when you click off and select another answer the previous answer is deselected and the current answer is hi-lighted. I need to allow for multiple selections. This code is what is doing to current select/de-select functionality.
package exam {
    import flash.display.*;
    import flash.events.*;
    import flash.text.*;
    //This class displays the current question, and contains the Choices for the question
    public class QMachine extends Sprite {
        //VARIABLES
        private var QObject:Object; //object from XaMLDiplomat, containing necessary text
        private var limit:Number;
        private var QNumTxt:TextField;
        private var QTxt:TextField;
        private var txtStyle:StyleSheet;
        private var choiceA:Choice;
        private var choiceB:Choice;
        private var choiceC:Choice;
        private var choiceD:Choice;
        private var choiceE:Choice;
        private var choiceF:Choice;
        //CONSTRUCTOR
        public function QMachine (hite:Number) {
            limit = hite;
            var style:Object = new Object();
            style.fontFamily = "Arial";
            //style.fontWeight = "bold";
            style.fontSize = "16";
            style.color = "#333333";
            txtStyle = new StyleSheet();
            txtStyle.setStyle("p",style);
            QNumTxt = new TextField();
            QNumTxt.styleSheet = txtStyle;
            //QNumTxt.embedFonts = true;
            QNumTxt.htmlText = "<p>1) </p>";
            QNumTxt.autoSize = TextFieldAutoSize.RIGHT;
            QNumTxt.x = 10;
            QNumTxt.mouseEnabled = false;
            QTxt = new TextField();
            QTxt.styleSheet = txtStyle;
            //QTxt.embedFonts = true;
            QTxt.width = 300;
            QTxt.multiline = true;
            QTxt.wordWrap = true;
            QTxt.autoSize = TextFieldAutoSize.LEFT;
            QTxt.htmlText = "<p>Question 1</p>";
            QTxt.x = 35;
            QTxt.mouseEnabled = false;
            addChild(QNumTxt);
            addChild(QTxt);
            choiceA = new Choice("a");
            choiceA.x = 350;
            addChild(choiceA);
            choiceB = new Choice("b");
            choiceB.x = 350;
            addChild(choiceB);
            choiceC = new Choice("c");
            choiceC.x = 350;
            addChild(choiceC);
            choiceD = new Choice("d");
            choiceD.x = 350;
            addChild(choiceD);
            choiceE = new Choice("e");
            choiceE.x = 350;
            addChild(choiceE);
            choiceF = new Choice("f");
            choiceF.x = 350;
            addChild(choiceF);
            addEventListener(MouseEvent.MOUSE_UP, selectResponse, true);
        internal function newQuestion (obj:Object, prior:String = ""):void {
            //trace(obj.num);
            QNumTxt.htmlText = "<p>"+ obj.num + ".</p>";
            QTxt.htmlText = "<p>"+ obj.q + "</p>";
            choiceA.deselect();
            choiceB.deselect();
            choiceC.deselect();
            choiceD.deselect();
            choiceE.deselect();
            choiceF.deselect();
            choiceA.resetSize();
            choiceB.resetSize();
            choiceC.resetSize();
            choiceD.resetSize();
            choiceE.resetSize();
            choiceF.resetSize();
            choiceA.changeTxt(obj.ca);
            choiceB.changeTxt(obj.cb);
            choiceB.y = choiceA.height + 5;
            if (obj.cc == undefined || String(obj.cc) == "") {
                choiceC.visible = false;
            }else {
                choiceC.changeTxt(obj.cc);
                choiceC.y = choiceB.y + choiceB.height + 5;
                choiceC.visible = true;
            if (obj.cd == undefined || String(obj.cd) == "") {
                choiceD.visible = false;
            }else {
                choiceD.changeTxt(obj.cd);
                choiceD.y = choiceC.y + choiceC.height + 5;
                choiceD.visible = true;
            if (obj.ce == undefined || String(obj.ce) == "") {
                choiceE.visible = false;
            }else {
                choiceE.changeTxt(obj.ce);
                choiceE.y = choiceD.y + choiceD.height + 5;
                choiceE.visible = true;
            if (obj.cf == undefined || String(obj.cf) == "") {
                choiceF.visible = false;
            }else {
                choiceF.changeTxt(obj.cf);
                choiceF.y = choiceE.y + choiceE.height + 5;
                choiceF.visible = true;
            var curHite:Number;
            if (choiceF.visible) {
                curHite = choiceF.y + choiceF.height + 5;
            }else if (choiceE.visible) {
                curHite = choiceE.y + choiceE.height + 5;
            }else if (choiceD.visible) {
                curHite = choiceD.y + choiceD.height + 5;
            }else {
                curHite = choiceC.y + choiceC.height + 5;
            if (curHite > (limit-150)) {
                shrinkText();
            if (prior != "") {
                if (prior == "a") {
                    choiceA.nowSelected();
                }else if (prior == "b") {
                    choiceB.nowSelected();
                }else if (prior == "c") {
                    choiceC.nowSelected();
                }else if (prior == "d") {
                    choiceD.nowSelected();
                }else if (prior == "e") {
                    choiceE.nowSelected();
                }else if (prior == "f") {
                    choiceF.nowSelected();
        private function shrinkText() {
            choiceA.dropSize();
            choiceB.dropSize();
            choiceC.dropSize();
            choiceD.dropSize();
            choiceE.dropSize();
            choiceF.dropSize();
            choiceB.y = choiceA.y + choiceA.height + 5;
            choiceC.y = choiceB.y + choiceB.height + 5;
            choiceD.y = choiceC.y + choiceC.height + 5;
            choiceE.y = choiceD.y + choiceD.height + 5;
            choiceF.y = choiceE.y + choiceE.height + 5;
            var curHite:Number = 0;
            if (choiceF.visible) {
                curHite = choiceF.y + choiceF.height + 5;
            }else if (choiceE.visible) {
                curHite = choiceE.y + choiceE.height + 5;
            }else if (choiceD.visible) {
                curHite = choiceD.y + choiceD.height + 5;
            }else {
                curHite = choiceC.y + choiceC.height + 5;
            if (curHite > (limit-150)) {
                shrinkText();
        private function selectResponse (e:MouseEvent):void {
            choiceA.deselect();
            choiceB.deselect();
            choiceC.deselect();
            choiceD.deselect();
            choiceE.deselect();
            choiceF.deselect();
            var letter:String = e.target.parent.getLetter();
            dispatchEvent(new ResponseEvent(ResponseEvent.SELECTION, letter));
        internal function setPriorResponse() {
            choiceA.deselect();
            choiceB.deselect();
            choiceC.deselect();
            choiceD.deselect();
            choiceE.deselect();
            choiceF.deselect();

Similar Messages

  • [svn] 3519: Fix typo in error string for situations where there are advanced messaging configuration settings from LCDS used in the configuration files but no AdvancedMessagingSupport service .

    Revision: 3519
    Author: [email protected]
    Date: 2008-10-08 04:17:40 -0700 (Wed, 08 Oct 2008)
    Log Message:
    Fix typo in error string for situations where there are advanced messaging configuration settings from LCDS used in the configuration files but no AdvancedMessagingSupport service. The error string said that there was no flex.messaging.services.AdvancedMessagingService registered but it is the flex.messaging.services.AdvancedMessagingSupport service that needs to be registered.
    Add configuration test that starts the server with a destination that has the reliable property set which is an advanced messaging feature but there is no AdvancedMessagingSupport service registered.
    Modified Paths:
    blazeds/trunk/modules/common/src/flex/messaging/errors.properties
    Added Paths:
    blazeds/trunk/qa/apps/qa-regress/testsuites/config/tests/messagingService/ReliableDestina tionWithNoAdvancedMessagingSupport/
    blazeds/trunk/qa/apps/qa-regress/testsuites/config/tests/messagingService/ReliableDestina tionWithNoAdvancedMessagingSupport/error.txt
    blazeds/trunk/qa/apps/qa-regress/testsuites/config/tests/messagingService/ReliableDestina tionWithNoAdvancedMessagingSupport/services-config.xml

    Hi,
    Unfortunately I already tried all kinds of re-installs (the full list is in my original message). The only one remaining is the reinstall of Windows 8 itself, which I would really like to avoid.
    What I find really strange is the time it takes for the above error message to appear. It's like one hour or even more (never measured exactly, I left the computer running).
    What kind of a timeout is that? I would expect that, if ports are really used by some other application, I get the message in less than a minute (seconds, actually). To me this looks like the emulator itself for some reason believes there's a problem with
    some port while in reality there isn't.
    I'll eventually contact Microsoft Support, thanks for the suggestion.

  • Does the Airport Extreme support HP cp1025?  There are two versions of the printer the cp1025 and cp1025nw.  I have the cp1025, and can't set it up. Is there a list of AE/bonjour supported printers?

    Does the Airport Extreme support HP cp1025?  There are two versions of the printer the cp1025 and cp1025nw.  I have the cp1025, and can't set it up.
    Is there a list of AE/bonjour supported printers?

    Bonjour is a transport protocol. It also provides a means of advertising a printer on a network.
    Any list that shows printers that support Bonjour is generally an indication that the printer itself supports this protocol, meaning that when it is connected to the network, you can see it in your default Add Printer browser. In the case of the Airport, it also supports the Bonjour protocol and will advertise any printer that is connected to its USB port. The printer itself does not have to support Bonjour. The Airport performs this function. And like many lists, they are not kept up to date because each vendor releases several new models every quarter or half year.
    There are definitely printers that don't work when connected to the USB port of the Airport. And this is more that the printer driver does not support this type of connection, mainly due to the port not supporting bidirectional communications which some printer drivers require. The Canon UFR2 and CAPT drivers are a good example of this limitation. But this is only the Mac drivers. The Windows equivalent drivers work fine when the printer is connected to the USB port.
    So with you having an issue with the Windows drivers then I don't think it is a case of them not supporting Bonjour but more to do with some other component not functioning when the printer is shared by the Airport. The error message appears to have more to do with local user rights which is probably driver related. I've seen some printers that you cannot use the Windows Add Printer wizard to add them. Instead you have to use the vendors utility because of some proprietary protocol being used. Maybe this is one of those?
    Now that you seen how it should work based on when you used the C3188, if you still get that error message at point 6 of adding the C1025 then it would suggest a driver compatibility issue with the Airport - which is not necessarily a Bonjour compatibility issue. So unless there was another model of HP printer driver that you could use to this C1025 and that was also compatible with the USB port of the Airport Extreme, then I would suggest your best action is to replace the printer with a model that does work. Maybe even one that has builtin wireless so you don't have to use the USB port of the Airport.

  • I have a new iPhone 6 plus and all is OK. But the mail shows more than 400 'unread' messages whereas there are none in the mailbox or trash or anywhere else I have looked. I can send and receive with no problem. I'm sure I have no unread messages.

    I have a new iPhone 6 plus and all is OK. But the mail shows more than 400 'unread' messages whereas there are none in the mailbox or trash or anywhere else I have looked. I can send and receive with no problem. I'm sure I have no unread messages.

        jsavage9621,
    It pains me to hear about your experience with the Home Phone Connect.  This device usually works seamlessly and is a great alternative to a landline phone.  It sounds like we've done our fair share of work on your account here.  I'm going to go ahead and send you a Private Message so that we can access your account and review any open tickets for you.  I look forward to speaking with you.
    TrevorC_VZW
    Follow us on Twitter @VZWSupport

  • Can you use home share where there are 2 itunes on the same computer but under different user profiles?

    Can you use 'Home Share' where there are 2 itunes on the same computer, but under different user profiles?

    check out method one from this support article -> How to use multiple iPods, iPads, or iPhones with one computer

  • I am trying to set up a child account where websites are restricted unless they are on the approved list, however youtube is still allowed.  How do I block youtube?

    I am trying to set up a child account where websites are restricted unless they are on the approved list, however youtube is still allowed.  How do I block youtube?

    Hello jmkibert,
    Thank you for using Apple Support Communities.
    For more information, take a look at:
    OS X Mavericks: Set up parental controls
    http://support.apple.com/kb/PH14414
    Web > try to limit access to adult websites > customize > never allow these websites.
    Have a nice day,
    Mario

  • TS3988 I get an unable to contact server error when i try to sign in..I don't see where there are outages.

    I get an unable to contact server error when i try to sign in..I don't see where there are outages.

    I am also having this problem.
    I'm trying to log-in from a PC. I tried both Chrome and Firefox and am getting the same error.

  • There are two CDC methods - Source based CDC and Target based CDC which one

    There are two CDC methods - Source based CDC and Target based CDC, which one is better performancewise. in data services.
    If there is any document available which compares both and provides any info on performance etc, will be helpful.
    thank you for the helpful info.

    LIke Suneer mentioned CDC is for better performance.
    Following link would be helpful.
    http://wiki.sdn.sap.com/wiki/display/BOBJ/Extractors-Source-Based+CDC
    http://wiki.sdn.sap.com/wiki/display/BOBJ/Extractors-Target-Based+CDC
    Thanks,
    Arun

  • [svn:fx-trunk] 11080: To cover cases where there are filters in the ancestry chain, we have to use our MatrixUtils sledgehammer to acquire the correct concatenated matrix .

    Revision: 11080
    Author:   [email protected]
    Date:     2009-10-22 06:37:39 -0700 (Thu, 22 Oct 2009)
    Log Message:
    To cover cases where there are filters in the ancestry chain, we have to use our MatrixUtils sledgehammer to acquire the correct concatenated matrix.
    QE notes: None
    Doc notes: None
    Bugs: SDK-23155
    Reviewer: Chet
    Tests run: Checkin
    Is noteworthy for integration: No
    Ticket Links:
        http://bugs.adobe.com/jira/browse/SDK-23155
    Modified Paths:
        flex/sdk/trunk/frameworks/projects/spark/src/spark/components/PopUpAnchor.as

    FYI - This regression has been filed here: http://bugs.adobe.com/jira/browse/SDK-31989

  • When you back up your Iphone/Ipad it backs up for camera roll. but when you take pictures and it uses photo stream, does that mean there are two copy's of your photos on icloud one set for photo stream and one set for backups?

    When you back up your Iphone/Ipad it backs up your camera roll. but when you take pictures and it uses photo stream, does that mean there are two copy's of your photos on icloud one set for photo stream and one set for backups?

    What do you mean by storage quota, does that mean i could be photo streaming about 1gb of photos and it does not get taken away from my free 5bg.

  • Get only the rows where there are no matches in the tables

    To include in the results of a join with no matching rows, you can use a full outer join. In MS SQL Server provides the FULL OUTER JOIN operator, which allows you to include all rows from both tables, regardless of the presence or absence of values.
    You can add a WHERE clause in a FULL OUTER JOIN to get only the rows where there are no matches in the tables. The following query returns only those products for which there are no matches in the sales order.
    SELECT p1.Name, p2.SalesOrderID
    FROM  TAB1 p1
    FULL OUTER JOIN TAB2 p2
    ON p1.ProductID = p2.ProductID
    WHERE p1.ProductID IS NULL
    ORDER BY p.Name ;
    FULL OUTER JOIN is not supported in ABAP.  How can you solve this?
    Thanks in advance,
    Serena

    Similar problems can often be solved by using subqueries, please have a look here and try applying it.
    http://help.sap.com/abapdocu_702/en/abenwhere_logexp_subquery.htm
    Thomas

  • I updated my 3gs and it wiped all my apps, now when trying to rebuy the apps it is asking for a postcode(i live in ireland where there are none)and it also will not accept my payment card type.any help greatly appreciated

    I updated my 3gs and it wiped all my apps, now when trying to rebuy the apps it is asking for a postcode(i live in ireland where there are none)and it also will not accept my payment card type.any help greatly appreciated

    I cannot find this 300GB "Backup" in the Finder, only in the Storage info when I check "About This Mac".
    You are probably using Time Machine to backup your MacBook Pro, right? Then the additional 300 GB could be local Time Machine snapshots.  Time Machine will write the hourly backups to the free space on your hard disk, if the backup drive is temporarily not connected. You do not see these local backups in the Finder, and MacOS will delete them, when you make a regular backup to Time Machine, or when you need the space for other data.
    See Pondini's page for more explanation:   What are Local Snapshots?   http://pondini.org/TM/FAQ.html
    I have restarted my computer, but the information remains the same. How do I reclaim the use of the 300GB? Why is it showing up as "Backups" when it used to indicate "Photos"? Are my photos safe on the external drive?
    You have tested the library on the external drive, and so your photos are save there.  
    The local TimeMachine snapshot probably now contains a backup of the moved library.  Try, if connecting your Time Machine drive will reduce the size of your local Time Machine snapshots.

  • Am I billed for periods where there are no events?

    Assume I have a dev/test scenario where there are long periods of time when I'm not actively testing my code. If I have running jobs waiting for input and there are no events, am I billed for that time?

    There are two meters for which your Stream Analytics gets billed [1]
    (1) Data ingressed by your streaming job
    (2) CPU memory used by the running job
    http://azure.microsoft.com/en-us/pricing/details/stream-analytics/
    So if you are not sending any events you will not be billed for (1) but you will still be billed for (2) since you have a streaming job that is allocated and running.
    You will have to STOP your job in order to avoid getting billed at all
    Thanks
    Zafar Abbas

  • Is the Time Capsule wi-fi router compatible with the Nest thermostat? I've read where there are issues with the Nest and Airport Extreme (AE)? Is AE used in the Time Capsule?

    I've read where there are issues with the Nest and Airport Extreme (AE)? Is AE used in the Time Capsule?
    If so, i already have a wi-fi router, so can the Time Capsule simply be used for wireless backup instead of as a router if there is conflict?

    A TC is fundamentally a AE with a sata chip included to drive the hard disk. Some slightly different bios to include disk functions, although most of those are also on the AE. So as a router it is 99.999% identical.
    And yes, if you have another router you can easily bridge the TC and use wireless for backups and internet connection. Once you no longer route through the TC the issues with most NAT problems including port forwarding should disappear.. mostly this is due to all apple routers using NAT-PMP instead of upnp which is the near universal standard for opening ports.. without upnp apple keep their routers more exclusive.

  • HT4993 on my computer there are two different accounts for the itunes store but my brothers account keeps syncing in on my iphone instead of my own account how do i get his account off of my phone and add my own back?

    on my computer there are two different accounts for the itunes store but my brothers account keeps syncing in on my iphone instead of my own account how do i get his account off of my phone and add my own back?

    Not a good idead to share IDs
    Read http://macmost.com/setting-up-multiple-ios-devices-for-messages-and-facetime.htm l
    Read Sharing an Apple ID with your Family
    Does your father have a recent backup of his phone?  If so restore his phone from that.  Please not that everythign created on th ephone since the backup was made will be lost

Maybe you are looking for