473,569 Members | 2,617 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Strange FireFox problem - too much recursion

Hi!

I've implemented some DropDown list in ASP.NET that use Ajax to fetch
the data from the server. The javascript is written to call cascading to
the bottom most dropdown in order to update them all if a top one changed.
The strange thing is that the script runs without problems on IE but in
FireFox i get a "too much recursion" error and nothing happens.

Here is the javascript code generated:

<script language="JavaS cript">
<!--
function _ctl12_cob_clie ntAjaxMethods_G etChannelsByCli entByLang() {
var value = document.getEle mentById( "_ctl12_cob_cli ent" ).value;
var para_0=2;

AjaxMethods.Get ChannelsByClien tByLang( value, para_0,
_ctl12_cob_clie ntAjaxMethods_G etChannelsByCli entByLang_callb ack );
}

function
_ctl12_cob_clie ntAjaxMethods_G etChannelsByCli entByLang_callb ack(
response ) {
var ds = response.value;
if(ds != null && typeof(ds) == "object" && ds.Tables != null){
var reciever = document.getEle mentById("_ctl1 2_acob_channel" );
var viewStateElem =
document.getEle mentsByName("_c tl12_acob_chann el_VIEWSTATE")[0];
Fill_ListContro lFromDataBase( ds, reciever, viewStateElem, 'Name', 'ID' )
_ctl12_acob_cha nnelAjaxMethods _GetCategoryByC hannelClientLan g()
} else {
alert("DataSet corrupted or no data");
}
}
function _ctl12_acob_cha nnelAjaxMethods _GetCategoryByC hannelClientLan g() {
var value = document.getEle mentById( "_ctl12_acob_ch annel" ).value;
var para_0=document .getElementById ("_ctl12_cob_cl ient").value;
var para_1=2;

AjaxMethods.Get CategoryByChann elClientLang( value, para_0, para_1,
_ctl12_acob_cha nnelAjaxMethods _GetCategoryByC hannelClientLan g_callback );
}

function
_ctl12_acob_cha nnelAjaxMethods _GetCategoryByC hannelClientLan g_callback(
response ) {
var ds = response.value;
if(ds != null && typeof(ds) == "object" && ds.Tables != null){
var reciever = document.getEle mentById("_ctl1 2_acob_category ");
var viewStateElem =
document.getEle mentsByName("_c tl12_acob_categ ory_VIEWSTATE")[0];
Fill_ListContro lFromDataBase( ds, reciever, viewStateElem, 'Name', 'ID' )

_ctl12_acob_cat egoryAjaxMethod s_GetSubCategor iesByMainCat_Cl ient_Language()
} else {
alert("DataSet corrupted or no data");
}
}
function
_ctl12_acob_cat egoryAjaxMethod s_GetSubCategor iesByMainCat_Cl ient_Language()
{
var value = document.getEle mentById( "_ctl12_acob_ca tegory" ).value;
var para_0=document .getElementById ("_ctl12_cob_cl ient").value;
var para_1=2;

AjaxMethods.Get SubCategoriesBy MainCat_Client_ Language( value, para_0,
para_1,
_ctl12_acob_cat egoryAjaxMethod s_GetSubCategor iesByMainCat_Cl ient_Language_c allback
);
}

function
_ctl12_acob_cat egoryAjaxMethod s_GetSubCategor iesByMainCat_Cl ient_Language_c allback(
response ) {
var ds = response.value;
if(ds != null && typeof(ds) == "object" && ds.Tables != null){
var reciever = document.getEle mentById("_ctl1 2_acob_subcateg ory");
var viewStateElem =
document.getEle mentsByName("_c tl12_acob_subca tegory_VIEWSTAT E")[0];
Fill_ListContro lFromDataBase( ds, reciever, viewStateElem, 'Name', 'ID' )

} else {
alert("DataSet corrupted or no data");
}
}

function Fill_ListContro lFromDataBase( ds, reciever, viewStateElem,
textFieldName, valueFieldName ) {
if(ds != null && typeof(ds) == "object" && ds.Tables != null){
var html = [];
var i=0;
while( reciever.childN odes.length > 0 ) {
var node = reciever.childN odes[0];
reciever.remove Child( node );
}
var vs = [];
for(i=0; i<ds.Tables[0].Rows.length; i++) {
var txt = ds.Tables[0].Rows[i][textFieldName];
var id = ds.Tables[0].Rows[i][valueFieldName]
vs[vs.length] = id + ":" + txt + "|";
var opt = document.create Element("option ");
var txt = document.create TextNode( txt );
var atr = document.create Attribute( "value" );
atr.nodeValue = id;
opt.setAttribut eNode( atr );
opt.appendChild ( txt );
reciever.append Child( opt );
}

if ( viewStateElem != null ) {
viewStateElem.v alue = vs.join("");
} else {
alert("No ViewStateFound" );
}
}
}

// -->
</script>

Each function on it's own works if i remove the calls for the child
value method.

Has anyone an idea how this can happen as there is no recursion in this
functions.

thanks in advance and greetings,
chris
Jul 23 '05 #1
9 7766
In article <ne************ *********@news. sil.at>, e9806056
@student.tuwien .ac.at enlightened us with...

Has anyone an idea how this can happen as there is no recursion in this
functions.


There is, but you'd have to understand a stack (and realize that a stack is
what is being used) to realize it.
It's a stack overflow error.

As to why it happens and how to fix it, I'd need a full test example (URL?).
I hate reading through generated code and it's worse when I don't have a DOM
to look at to trace it.

You may want to grab the web developer firefox extension.
--
--
~kaeli~
Is it possible to be totally partial?
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

Jul 23 '05 #2
kaeli wrote:
In article <ne************ *********@news. sil.at>, e9806056
@student.tuwien .ac.at enlightened us with...
Has anyone an idea how this can happen as there is no recursion in this
functions.

There is, but you'd have to understand a stack (and realize that a stack is
what is being used) to realize it.


Well i know this. The thing is that i can'tz find any parts in the
methods that may cause trouble with the stack. There are max. 8 method
calls before the script terminates and in IE it runns without any
warnings or problems.
It's a stack overflow error.

As to why it happens and how to fix it, I'd need a full test example (URL?).
I hate reading through generated code and it's worse when I don't have a DOM
to look at to trace it.
I'll setup a page for you and send you the URL when it' available.

You may want to grab the web developer firefox extension.


I'll try that

thanks & greetings,
chris
Jul 23 '05 #3
In article <ne************ ********@news.s il.at>, e9806056
@student.tuwien .ac.at enlightened us with...

Well i know this. The thing is that i can'tz find any parts in the
methods that may cause trouble with the stack.
Okay, I looked at this more thoroughly, and what I don't see is the initial
call to this function (this function seems to set all the rest in motion):

function _ctl12_cob_clie ntAjaxMethods_G etChannelsByCli entByLang() {
var value = document.getEle mentById( "_ctl12_cob_cli ent" ).value;
var para_0=2;

AjaxMethods.Get ChannelsByClien tByLang( value, para_0,
_ctl12_cob_clie ntAjaxMethods_G etChannelsByCli entByLang_callb ack );
}

What calls this?
And since the function it calls takes a parameter called 'response', where is
that coming from?
function
_ctl12_cob_clie ntAjaxMethods_G etChannelsByCli entByLang_callb ack(
response ) {
var ds = response.value;

I'll setup a page for you and send you the URL when it' available.


Let me know if you get one set up.
I'm curious now. :)

--
--
~kaeli~
A boiled egg in the morning is hard to beat.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

Jul 23 '05 #4
kaeli wrote:
In article <ne************ ********@news.s il.at>, e9806056
@student.tuwien .ac.at enlightened us with...
Well i know this. The thing is that i can'tz find any parts in the
methods that may cause trouble with the stack.

Okay, I looked at this more thoroughly, and what I don't see is the initial
call to this function (this function seems to set all the rest in motion):


right this one calls the next hierachical level and so on. no recusion
in this
function _ctl12_cob_clie ntAjaxMethods_G etChannelsByCli entByLang() {
var value = document.getEle mentById( "_ctl12_cob_cli ent" ).value;
var para_0=2;

AjaxMethods.Get ChannelsByClien tByLang( value, para_0,
_ctl12_cob_clie ntAjaxMethods_G etChannelsByCli entByLang_callb ack );
}

What calls this?
It is called by the OnChange Event handler in an DropDownList
And since the function it calls takes a parameter called 'response', where is
that coming from?
This is the result DataSet that get initialised and transfered to the
client by the Ajax.NET wrapper library.
function
_ctl12_cob_clie ntAjaxMethods_G etChannelsByCli entByLang_callb ack(
response ) {
var ds = response.value;

I'll setup a page for you and send you the URL when it' available.


Let me know if you get one set up.
I'm curious now. :)


Will let you know - maybe i'll manage it to bring it online tonight.

thanks and greetings,
chris
Jul 23 '05 #5
Christian Hubinger wrote:
kaeli wrote:

[snip]

Let me know if you get one set up.
I'm curious now. :)


Will let you know - maybe i'll manage it to bring it online tonight.


Well i've put it online today.

Register yourself at http://www.jobline.cc/jobline.cc
And after logging in insert the URL:
http://www.jobline.cc/jobline.cc/Def...c.aspx?id=4910

Theere you should see 4 drop down lists updating each other without
doing postbacks - works perfectely in IE but FireFox throws the
described errors.
thanks in advance for your help and greetings,
chris

Jul 23 '05 #6
In article <ne************ ********@news.s il.at>, e9806056
@student.tuwien .ac.at enlightened us with...

Register yourself at http://www.jobline.cc/jobline.cc


I don't speak German. I don't what to put where in that form.
Register a test account and mail me the username/pass at
tiny_one (at) comcast (dot) net
and I'll check it out when I get home tonight.
Or you can post it here (x-no-archive) and delete the account later.
Whichever floats your boat. :)

You should have a test account set up anyway, even on the production machine,
for things just like this.

For best error tracing, though, you need to pull out as much code as possible
while still recreating the error conditions. Put that in a test page that
doesn't need registering or logging in. It's a LOT easier to trace things
when you pull out all the stuff that does work. Many times I've found my
error just putting together the test case.

--
--
~kaeli~
Condoms should be used on every conceivable occasion.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

Jul 23 '05 #7
kaeli wrote:
In article <ne************ ********@news.s il.at>, e9806056
@student.tuwien .ac.at enlightened us with...
Register yourself at http://www.jobline.cc/jobline.cc
I don't speak German.


Well i understand we need to add a flag to our language change menu ;)
I don't what to put where in that form.
Register a test account and mail me the username/pass at
tiny_one (at) comcast (dot) net
and I'll check it out when I get home tonight.
Or you can post it here (x-no-archive) and delete the account later.
Whichever floats your boat. :)
Well thanks a lot for you help offer but i've just updated the Ajax.NET
dll we are using to handle XmlHttpRequests and the problem disappeared.
So it was actually a problem with one of the client script this library
thrown on the client.
You should have a test account set up anyway, even on the production machine,
for things just like this.
We are planning to have such a test platform online as soon as we do the
official launch of the plattform. So everything now online is a test
plattform.
For best error tracing, though, you need to pull out as much code as possible
while still recreating the error conditions. Put that in a test page that
doesn't need registering or logging in. It's a LOT easier to trace things
when you pull out all the stuff that does work. Many times I've found my
error just putting together the test case.

Shurely that is what i did on the page i use for testing. The problem is
that we are using our own home brewn portal software and therefore i
neet to test if things work inside that environment. Thats the reason
why i didn't put a simple blank page online.
But you are accutally right i'll setup such a simple playground in the
near future to track down such problems.

So again thanks a lot for your offer.

greetings from vienna,
chris
Jul 23 '05 #8
In article <ne************ ********@news.s il.at>, e9806056
@student.tuwien .ac.at enlightened us with...

Well thanks a lot for you help offer but i've just updated the Ajax.NET
dll we are using to handle XmlHttpRequests and the problem disappeared.
So it was actually a problem with one of the client script this library
thrown on the client.


I had a feeling it was.
Glad you solved the problem.

--
--
~kaeli~
Murphy's Law #2000: If enough data is collected, anything
may be proven by statistical methods.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

Jul 23 '05 #9
Christian Hubinger wrote:
kaeli wrote:
@student.tuwien .ac.at enlightened us with...
Register yourself at http://www.jobline.cc/jobline.cc

I don't speak German.


Well i understand we need to add a flag to our language change menu ;)


No, you don't :) <http://www.cs.tut.fi/~jkorpela/flags.html>
PointedEars
--
Messen, was messbar ist, und messbar machen, was noch nicht messbar ist.
-- Galileo Galilei
Jul 23 '05 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
1808
by: Jp Calderone | last post by:
Due to some bizarre constraints placed on me, I've written the following metaclass: import types def remove(t, o): return tuple() class BizarreMetaclass(type): def __new__(klass, name, bases, attrs):
1
1486
by: Mike the Canadian | last post by:
I am having a strange problem with field verification in a form. The JavaScript below works just fine in Firefox but in IE. "license" is a pull-down list and "requiredDiscount" is a text field. When license is "Freeware" and requiredDiscount is "N/A", in IE (but not Firefox) you get the message "For trialware you must enter a valid discount"....
9
1450
by: sylsau | last post by:
Hi, I am doing a little program who calculates the permutation of a set of vertex. I use the recursivity for this calcul. My function who calculate the permutations : void permutation(set *e, int *current, int nbre) {
7
27117
by: Hoss | last post by:
Hello all- This is what im trying to achieve. At the top of my page there is some search functionality, through which you cause to be loaded a string representing an HTML page. Below this and occuupying about 80% of the window real estate, there is a DIV. There is also a toggle button with two options "Code View" and "Text View" as I have...
2
1276
by: niels.froehling | last post by:
Hy; I converted the tables (for _tabular_ :) data) in a project from the plain <table><tr><td></td></tr></table> structure to seperation into head/foot/body divisions (not the <div>-element). Now I get a strange behaviour in FireFox not obeying the given sizes anymore, but not in all cases. It seems that when there are elements with...
4
12925
by: Daniel Guettler | last post by:
I'm getting lots of "Error: too much recursion" in my Firefox Error Console I have created these little files to test it. It justs opens a new window and closes it again. I see plenty of errors showing up in the Error Console The main file: <html> <body>
4
2267
by: szimek | last post by:
Hi, I've already posted an email with this problem, but this time I think I got a bit more info. The app I'm currently working on works like this: when user clicks on a clickable element, it handles its onclick event and sets values of input fields in hidden form according to event data etc. The form is submitted, on the server side...
8
2434
by: =?GB2312?B?yum09MXt?= | last post by:
today I forgot to include some header,then I found the error message by the compiler is quite strange. so I want to know exactly the inner details of the compiler impletation,if possible. and I want to know what does the standard say about this situation. here is the code just to demonstrate the error.
2
3732
by: scdowney | last post by:
First and foremost, thank you in advance for any attempts to help me out. I am working on a project with work, and it requires I use CSS selectors to locate elements within a webpage. For the most part, I have had no issues using the selectors, but I am having a very strange issue which does not seem to make much sense to me. Please advise if...
0
7924
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
1
7677
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7979
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
5219
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3653
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3643
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2115
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1223
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
940
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.