Saturday, March 24, 2012

Namespace registered once but used in severel Files

Hi everyone!I'm sorry for my english, it's a bit rusty, because I'm german.My problem:I am developing a custom webcontrol, which is inherited from WebCrontrol and IScriptControl. Everything works fine on codebehind (I think ;)). I have also developed 4 JS-Files.In JSFile1.js I registered my namespaces (i.e. "Sample", "Sample.Control", Sample.Collection").In JSFile2.js I DO NOT register any Namespace, but I want USE the registered namespaces. But when I start my webapplication, IE says that "Sample" is unknown in JSFile2.js. Is my way of implementation possible at all?I hope you guys understand what I want. :)Thanks and greetsPuppetMasterP.S. I'm sorry for doubleposting, haven't seen this area at first.

Sounds like you may have an issue with the order of files being added into the page. Make sure JSFile1.js comes before JSFile2.js when your page is rendered.

-Damien


I fixed the problem. It was a simple comma. One comma to much...What is it called like? "wood for the trees" or something? :)Thanks and greetsPuppetMaster

Glad you fixed it. Please mark this topic as answered / resolved.

-Damien

No comments:

Post a Comment