February 21, 201214 yr Hi, Okay, so i have 2 javascript "classes" (or the equivilant, whatever you want to call it).. and I need them to be able to talk to each other, but when I try I get an error... Here is the code: function ArenaProcessing(){ this.display = ""; this.init = function(){ alert ("ArenaProcessing Class Started"); } this.setDisplayModule = function(module){ this.display = module; } } function ArenaDisplayControl(){ this.process = ""; function init(){ alert ("ArenaDisplayControl Class Started"); } this.setProcessModule = function(module){ this.process = module; } } var ArenaProcess = new ArenaProcessing(); var ArenaDisplay = new ArenaDisplayControl(); ArenaProcess.SetDisplayModule(ArenaDisplay); ArenaDisplay.SetProcessModule(ArenaProcess); Now in theory I was expecting this to give each class the other ones instance so that they can talk to each other with ease... The problem is with the last 2 lines.. when I try and actually send the instances.. I get this message Object doesn't support this property or method Can anyone help me out here? I have a pretty sound understanding of php classes and have been using them for a good while. Just never looked into the javascript side of them and I'm having a few teething problems. Thanks
February 21, 201214 yr Author no matter, it appears that I'm actually just retarded and can't see the difference between a s and S lol...
Create an account or sign in to comment