A while ago I was confronted to a very strange runtime error:
“An invalid register <number here> was accessed”
I was like “what the …”. I didn’t really understand, why this error suddenly showed up – reproducible. So I started digging around in my sourcecode.
After a while (few hours!) commenting, cutting, pasting code I found out 2 facts:
- The error was in connection with some code dealing with XML
- I could make the error go away by moving functions around in my code (simply moving a function from the end of the sourcecode to the top!?)
So I took a closer look at the XML thing.
As it turned out it was a problem with xml default namespace i had set up because I didn’t want to/couldn’t write the namespace to every tag I wanted to access. It looked something like this:
…
public function GetXMLResult(event:ResultEvent):void { var doc:XML=XML(event.result); var ns:Namespace = new Namespace(doc.namespace()); default xml namespace = ns; //some xml data extracting... }
What was the solution to this strange issue (yeah, at some point even the code-moving-around-hack didn’t work)?
Adding one single line at the end of this funcion:
public function GetXMLResult(event:ResultEvent):void { var doc:XML=XML(event.result); var ns:Namespace = new Namespace(doc.namespace()); default xml namespace = ns; //some xml data extracting... default xml namespace = new Namespace(""); }
Setting default xml namespace to the “”-namespace solved the problem!
That’s it!
In times of garbage collection you’re tempted to forget “tidying up” such things like the xml default namespace. But, honestly, it’s just a bug.
Look here:
http://soledadpenades.com/2007/07/03/verifyerror-error-1025-an-invalid-register-1-was-accessed/
J*** C****! It’s 1 in the morning and I have been looking at this for hours!
That stupid line at the end was all I needed, heh. I’m not sure if I want to laugh or cry.
Just wanted to say I appreciate you taking the time to post.
Leave a link next time and I’ll buy you a cup of coffee for this one.
Many thanks! Saved me lots of time 😉
bravo. learnt a new stupidity of great mighty flex
I hope you dont mind, but i’m posting this answer everywhere…..you just saved me 5 days of work….
Haaaaaaaaaaaaaa horrible error !!!
Just removed the default namespace I set before and its worked !
Thank YOU ! You saved my day 🙂
thank you!!!! very strange thing…
Как практика показывает, каталоги уже не вариант, доски объявлений дают мало толку! Покупка ссылок на биржах удовольствие дорогое!
Мы предлогаем наростить массу вашего сайта в поисковых системах, путем наращиванием обратных ссылок!
Осуществляем раскрутку вашего сайта, либо любого объявления, услуге по профилям, форумам, блогам, гостевым!
___________________________________
Чем мы лучше???
-Низкие цены!
-Акции и постоянные скидки!
-Партнерская программа 10%
-Скидки постоянным клиентам до 20%
-Огромный вариант тарифов и возможностей!
_______________________________________
Раскрутим:
-Сайты(личные, компании, фирм)
-объявления о ваших услугах, либо не услугах!
Консултация!
_______________________________________
Примерные тарифы:
10 000 профилей на сайтах(ссылка вашего сайта внутри профилям) Всего 400 руб!!!
200 000 профилей на сайтах(ссылка вашего сайта внутри профилям) Всего 4800 руб!!!
Солянка 10 000 сайтов(ссылка вашего сайта в профилях, каталогах, блогах, гостевых, форумах) Всего 350 руб!!!
Солянка 600000 сайтов(ссылка вашего сайта в профилях, каталогах, блогах, гостевых, форумах) Всего 8000 руб!!!
_______________________________________
Также имеется огромное количество комплексных тарифов на любой вкус, цвет и возможность!
-Гарантия!
-Отчет!
Контакты для связи:
ICQ 648486829
ICQ 623315134
email: progonseomail@gmail.com
Terrific work! This is the kind of info that are supposed to be shared around the net. Disgrace on the seek engines for not positioning this submit upper! Come on over and talk over with my web site . Thank you =)
Hi there Dear, are you actually visiting this web page daily, if so then you will absolutely take good know-how.
Hey there! Someone in my Facebook group shared this website with us so I came to take a look. I’m definitely enjoying the information. I’m bookmarking and will be tweeting this to my followers! Excellent blog and fantastic style and design.
_cat
Foregoing a background check, the landlord has 14 days in which to inform the tenant landlord insurance (landlordsinsurance.webeden.co.uk) which scheme the money is held in, as well as having a flexible schedule. The family finally moved out of the one-bedroom walk-up because she gave it up in May. Tenants often have more rights and freedom of manoeuvre than they think, however, there will need to be familiar with your local landlord and tenant law. 5 per cent, if the mortgage interest is only 6 per cent, this makes good business sense.
Excellent way of telling, and pleasant piece of writing to get data
regarding my presentation topic, which i am going to deliver in university.
We stumbled over here by a different page and thought I might check things out.
I like what I see so now i am following you. Look forward to looking at your web page
again.
Hello There. I found your blog the use of msn. This is a really well written article.
I’ll be sure to bookmark it and come back to learn more of
your helpful information. Thank you for the post.
I will certainly comeback.
Oh my goodness! Awesome article dude! Thank you, However I am encountering problems with your RSS.
I don’t understand the reason why I cannot subscribe to it.
Is there anyone else getting similar RSS problems?
Anyone that knows the answer will you kindly respond?
Thanx!!
It’s the best time to make some plans for the long run and it is
time to be happy. I’ve learn this post and if I could I want
to suggest you few attention-grabbing things or tips. Maybe you could write subsequent articles relating to this article.
I desire to learn more things about it!
You can either edit or update the content on these web pages.
This value or indicator is quickly calculated with the use of multiple
factors taken into consideration. Reason for use of SEO Service:
– In fact what is the main reason to create a website, it is simple that
you want more business with fewer expanses.
v,hy