You have a try block but do not have the catch block or finally clause after it.
Incorrect
try {
// your code
}
// next set of code here
Correct
try {
// your code
}
catch (errorEvent:Error) {
// your code didn't work code
}
// next set of code here
Correct
try {
// your code
}
catch (errorEvent:Error) {
// your code didn't work code
}
finally {
// whether your code worked or not code
}
// next set of code here
try { } this.bvMC.removeEventListener(BookViewer.VIEWER_READY, this.ready);@miguel – You have a “try” block but you do not have a catch block after it. I have added more info above.
I get an error on line 382 wich is the one that says “hip” it a catch or finally clause error but I don’t know how to fix it
catch (e:Error) { try { } AssetClass = world.getClass(strSkinLinkage + strGender + "Hip") as Class; mcChar.hip.removeChildAt(0); mcChar.hip.addChild(new AssetClass); } catch (e:Error) {You have two catch blocks but only one try block. In the “try” block you have now your code is outside of it. That code needs to be inside of the brackets or inside a catch block after it.
try { trace("Trying some code"); AssetClass = world.getClass(strSkinLinkage + strGender + "Hip") as Class; mcChar.hip.removeChildAt(0); mcChar.hip.addChild(new AssetClass); trace("It worked!"); } catch (e:Error) { trace("It didn't work!"); }