Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

try/catch

gooi: function () {
        try {
            if (this.balPositie !== "links") {
                throw Error("bal in verkeerde positie")
            }
            this.draw(300, 50);
            this.balPositie = "midden";
        } catch {
            var bericht = "fout, bal al in de lucht of al gevangen";
            document.getElementById("melding").innerHTML = bericht;
        }
    },
Source by skillsbuddy.nl #
 
PREVIOUS NEXT
Tagged:
ADD COMMENT
Topic
Name
3+6 =