Thanks Yusuf, exactly right - was obviously having a syntax meltdown - fifth language this week! Ben
Bjohnson33
Posts
-
Javascript function works only the first time it's called -
Javascript function works only the first time it's calledHi Hope someone can help with this as I'm feeling a bit stupid at the moment! I've got a form (using a master page and an update panel in case it's relevant). This is also (and unfortunately needs to) running in IE6. On there are 3 text boxes which are pre-populated server side. When the value of one of these changes, I need to update another part of the screen (client-side, this doesn't need to go back to the server). So, each of those text boxes has:onFocus="storeValue(this)" onBlur="leavingField(this) so that on entry to the field the value is stored in a global variable and on exit this is checked and actioned if it has changed. The first time you enter and exit a field it behaves as expected, subsequently you get a 'Function Expected' error. The relevant code is: var valStore; function storeValue(field) { valStore = field.value; } function hasValueChanged(val) { if (val != valStore) hasValueChanged = true; else hasValueChanged = false; } function leavingField(field) { if (hasValueChanged(field.value)) { var prefix = (ctlPrefix + curr); calculateSingleDifference(field.id.split(prefix)[1]); field.className = (field.className + ' changedValue'); } } The error is raised the second time 'hasValueChanged' is called in 'leavingField'. Any ideas gratefully received! Thanks in advance Ben
-
Convert Word documents to PDF library in C# ?We used this on a large project last year for auto-generating invoices and it worked very solidly. As with the other posters, we didn't need to call on their support, but seem to recall a very healthy forum. We did also try Report.Net (http://sourceforge.net/projects/report/[^] but found, although it had very granular control, it was very fiddly and time-consuming to get accurate output. Ben
-
What is the best free FTP toolIt depends what you need to do, for simple FTP this is fine, but if you need to use the command line, the MS FTP client doesn't support SFTP or passive connections which caused us problems when connecting to external clients. Horses for courses..... Ben
-
What is the best free FTP toolIf you want a command line tool we use MoveIt-Freely: http://www.sharewareconnection.com/moveit-freely.htm[^] Cheers Ben
-
TIBCO RIA General InterfaceHi all Has anyone got any experience in the above (http://www.tibco.com/devnet/gi/[^]. We're just about to embark on evaluating it and wondered if anyone had any pointers or gotchas? Thanks Ben
-
Move __doPostBack to include fileThanks Todd. The consultant is not familiar with .Net technology, so a combination of yours and .netmans answers should give us a enough to make it a non-issue. Ben
-
Move __doPostBack to include fileThanks - that was my understanding as well. A simple 'more clarification on the impact' question may head this off. Ben
-
Move __doPostBack to include file'Why' is a very good question.... The crux of his argument is that the cleaner the page (in his ideal world, the page would only be one css reference and H1 to H6 and P tags - obviously would not have functionality, but, hey, what does that matter), the better it will get indexed by the search engines - personally, I think this is a load of old horse sh!t, as I'm sure that Google have just about managed to figure out that it doesn't need to look inside script tags. However, the business have engaged him to be involved in the project which means we either need to come up with reasons not to implement suggested changes, or find ways to do them. If there's any easy way to do this, then I avoid a fight, if there isn't, and there's no value to it anyway, then I can go back to the business and suggest that most of what is being suggested has no value. Oh, the joy of mixing politics with technology.... Thanks in advance! Ben
-
Move __doPostBack to include fileHi all I've had a look around and can't find any reference to this, which probably indicates that I'm stupid trying to do it, but here goes... We've got an SEO consultant/master of the dark arts involved in one of our current projects and he's keen for the auto-generated __doPostBack to be in an include file rather than inline. Has anyone got any ideas how to do this, or, indeed, if it's possible? Thanks Ben
-
Linq for OracleHi Has anybody successfully used Linq against an Oracle back-end? Any recommendations for 3rd party libraries? Oracle don't appear to have any plans to implement this themselves in the near future... Thanks Ben
-
Control that automatically drags when page is scrolled downHi Gerri Not sure why you're getting that behaviour... If you replace the body from the above example with the following:
some text
And then scroll to the right, the panel remains on the left hand side.... Cheers Ben
-
DTS: Transform Task > Stored Procedure > Temp Table errorThanks for the pointer. Seems most odd that that this isn't supported - is there a reason they opted not to allow this? Cheers Ben
-
DTS: Transform Task > Stored Procedure > Temp Table errorYes, SQL Server. Fair point, just my natural tidiness :-) Anyway, dropping the drops doesn't solve the issue.... Cheers Ben
-
icon to the web pageMinor correction: IE6 will show it if you bookmark it and then revisit the page. Which is a bit rubbish. Cheers Ben
-
problem in window.onload functionUm, you haven't got a window.onload call in that code. Try adding an onload event to your body tag: cheers Ben
-
DTS: Transform Task > Stored Procedure > Temp Table errorHi all I've got a problem that's driving me a bit mad, so any help gratefully received! I've got a Data Transformation Task that is calling a parameterised stored procedure: exec [myDB].[dbo].[vlGetOutputFile] 'Sep 28 2007', 6, 86 Within that stored procedure, I'm creating and dropping a couple of temporary tables and then returning the result set. If I click preview, I get the first 200 lines I'd expect, but as soon as I go to transformations I get the error 'Invalid object name #temp' and no columns to select from. What am I doing wrong? Thanks in advance Ben
-
Control that automatically drags when page is scrolled downHi Gerri Apologies, it looks like I may have missed a couple of functions. The following html page will do what you want, although it doesn't run as smoothly as the example you gave: function movePanel(){ var panel = document.getElementById("panel"); var current = panel.style.top.split('px')[0]; var top = posTop(); if(current < top){ while (current < top){ panel.style.top = current + 'px'; current++; } } else if (current > top){ while (current > top){ panel.style.top = current + 'px'; current--; } } } function posTop(){ if(!document.body.scrollTop){ return 0; } else if (document.body && document.body.scrollTop){ return document.body.scrollTop; } else if (document.documentElement && document.documentElement.scrollTop){ return document.documentElement.scrollTop; } }
some text
Cheers Ben
-
Handling return values from Java web serviceThanks Leppie - think I was having a Friday brain melt-down. Had already tried casting to an ArrayList and a generic list of deals objects. But, of course, it was just a good old fashioned array. Cheers Ben
-
Handling return values from Java web serviceHi all I'm calling a non-.net web service and getting myself confused. The object that is being created from the WSDL includes and out_msg, which is basically the return value. Within out_msg, there is an array of deal objects, however it's not a true array as I can't enumerate it - how do I convert this return value in to something useful (XML, generic list, well, anything really!). /// [System.CodeDom.Compiler.GeneratedCodeAttribute("System.Xml", "2.0.50727.42")] [System.SerializableAttribute()] [System.Diagnostics.DebuggerStepThroughAttribute()] [System.ComponentModel.DesignerCategoryAttribute("code")] [System.Xml.Serialization.XmlTypeAttribute(AnonymousType=true)] public partial class out_msg { private object itemField; /// [System.Xml.Serialization.XmlElementAttribute("deals", typeof(deal[]))] [System.Xml.Serialization.XmlElementAttribute("errors", typeof(out_msgErrors))] public object Item { get { return this.itemField; } set { this.itemField = value; } } } Thanks Ben