text
stringlengths
8
267k
meta
dict
Q: No Such Method Error when creating JUnit test I've tried figuring out this problem for the last 2 days with no luck. I'm simply trying to create an annotation based JUnit test using the spring framework along with hibernate. My IDE is netbeans 6.5 and I'm using hibernate 3, spring 2.5.5 and JUnit 4.4. Here's the er...
{ "language": "en", "url": "https://stackoverflow.com/questions/425039", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "12" }
Q: How to estimate a programming task if you have no experience in it I am having a difficult time with management asking for estimates on programming tasks that are using third-party controls that I have no prior experience with. I definitely understand why they would want the estimates, but I feel as though any estim...
{ "language": "en", "url": "https://stackoverflow.com/questions/425044", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "105" }
Q: To Index or Not to Index I have a database that I used specifically for logging actions of users. The database has a few small tables that are aimed at specific types of actions. This data is rarely searched, but the rowcounts of the tables are starting to climb into multi-millions. I haven't noticed a large slow do...
{ "language": "en", "url": "https://stackoverflow.com/questions/425047", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to wire Interdependent beans in Spring? I want to declare two beans and instantiate them using Spring dependency injection? <bean id="sessionFactory" class="SessionFactoryImpl"> <property name="entityInterceptor" ref="entityInterceptor"/> </bean> <bean id="entityInterceptor" class="EntityInterceptorImpl"> <pr...
{ "language": "en", "url": "https://stackoverflow.com/questions/425049", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "19" }
Q: Validating action attributes on thousands of forms I've inherited a Courseware CD with thousands of <form action="page.html" method="get"><input type="submit" value="Go"></form> buttons. Some of those forms are pointing to pages that don't exist and I'd really like to use an automated testing tool/crawler to test th...
{ "language": "en", "url": "https://stackoverflow.com/questions/425068", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: regular expression lookaround I don't think this is possible with just regular expressions, but I'm not an expert so i thought it was worth asking. I'm trying to do a massive search and replace of C# code, using .NET regex. What I want to do is find a line of code where a specific function is called on a variable th...
{ "language": "en", "url": "https://stackoverflow.com/questions/425071", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: how to delete the pluginassembly after AppDomain.Unload(domain) i have a weird problem. i would like to delete an assembly(plugin.dll on harddisk) which is already loaded, but the assembly is locked by the operating system (vista), even if i have unloaded it. f.e. AppDomainSetup setup = new AppDomainSetup(); setup....
{ "language": "en", "url": "https://stackoverflow.com/questions/425077", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "18" }
Q: which is better to pass a PHP var in AJAX call to another page: POST or through the session? in a PHP site I am building, I use a Prototype AJAX call to address some other php page. This called php page needs a variable that lives as a SESSION var on the first page (in the sense that it's used multiple times through...
{ "language": "en", "url": "https://stackoverflow.com/questions/425078", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: jQuery backgroundColor animation I have a DIV with a link and a SPAN. When clicking the link, it renders a list of items by using AJAX. When an item is clicked, the content of the SPAN is changed. I want to highlight this change, by setting the background-color of the DIV to green, and animating it back to white usi...
{ "language": "en", "url": "https://stackoverflow.com/questions/425082", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: How to write this nested Linq To Xml query Hi I am writing an app for a medical study they will type in the gender, the age, and some other values which will be calculated to a ResultValue now I have an XML file which holds some information about the result in combination of Age, Gender and the ResultValues and I...
{ "language": "en", "url": "https://stackoverflow.com/questions/425087", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Permission Denied opening an Excel File using Excel 12.0 Library & VB6 I have used Excel in my VB6 apps many times before, and have never run into such a weird problem trying to accomplish something very easy.. I am trying to open an excel (xls or xlsx) file and read through values, as you can probably see. When I t...
{ "language": "en", "url": "https://stackoverflow.com/questions/425092", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Submit form using AJAX and jQuery It seems like this should be something built into jQuery without the need for more than a few lines of code, but I can't find the "simple" solution. Say, I have an HTML form: <form method="get" action="page.html"> <input type="hidden" name="field1" value="value1" /> <input ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425095", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "59" }
Q: Hybrid NHibernate DAL/BLL I have an existing asp.net webforms project that uses Microsoft's Enterprise DAAB for the DAL, I need to implement some extensive features, and I would like to use NHibernate to make things easier. Is there any design patterns/architectures out there that allow a hybrid DAAB/NHibernate DAL ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425112", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How would you reverse engineer this? I've got some code that was at the bottom of a php file that is in javascript. It goes through lots of weird contortions like converting hex to ascii then doing regex replacements, executing code and so on... Is there any way to find out what it's executing before it actually do...
{ "language": "en", "url": "https://stackoverflow.com/questions/425113", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Transform and combine *.xml I want to pull a series of relationships out of xml files and transform them into a graph I generate with dot. I can obviously do this with a scripting language, but I was curious whether or not this was possible with xslt. Something like: xsltproc dot.xsl *.xml which would produce a ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425117", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: What is the best option for passing data from SSIS to WCF? We are trying to get data out of a SQL Server DB and submit it to a WCF web service. Since using a windows service is not a option in this case, I thought of using SSIS. I have tried using the Web Service Task, but I'm having difficulties getting it to work...
{ "language": "en", "url": "https://stackoverflow.com/questions/425122", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Better way to cleanly handle nested XML with LINQ I'm working with XML that was designed by somebody who got paid by the level of nesting. The different xml files always looks something like this: <Car> <Color> <Paint> <AnotherUselessTag> <SomeSemanticBs> <Th...
{ "language": "en", "url": "https://stackoverflow.com/questions/425125", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Losing ODBC connection with SQL Server 2005 Database One of our clients has an application (FoxPro 9) running on top of a SQL Server 2005 backend. Intermittently, they are losing their ODBC connection with the SQL Server database. Below is the initial error information: Err Msg: Connectivity error: [Microsoft][ODBC...
{ "language": "en", "url": "https://stackoverflow.com/questions/425130", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: "A reference to a volatile field will not be treated as volatile" implications The following code using System.Threading; class Test { volatile int counter = 0; public void Increment() { Interlocked.Increment(ref counter); } } Raises the following compiler warning: "A reference to a volatil...
{ "language": "en", "url": "https://stackoverflow.com/questions/425132", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "44" }
Q: Apache's AuthDigestDomain and Rails Distributed Asset Hosts I've got a server I'm in the process of setting up and I'm running into an Apache configuration problem that I can not get around. I've got Apache 2.2 and Passenger serving a Rails app with distributed asset hosting. This is the feature of Rails that lets y...
{ "language": "en", "url": "https://stackoverflow.com/questions/425136", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to skip certain database tables with mysqldump? Is there a way to restrict certain tables from the mysqldump command? For example, I'd use the following syntax to dump only table1 and table2: mysqldump -u username -p database table1 table2 > database.sql But is there a similar way to dump all the tables except ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425158", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "659" }
Q: Why doesn't intellisense show the appropriate methods according to what I am passing in? Like there are 3 methods like: Modify ( int arg ) Modify ( double arg ) Modify ( string arg ) And if I am passing in a double variable, it should automatically navigate to method #2, instead of me scrolling down to see if there...
{ "language": "en", "url": "https://stackoverflow.com/questions/425161", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Embedded flash video: works locally, but not on staging server I was able to embed a video that auto plays on my local machine. When I upload my solution onto my staging server I get nothing. It's weird, everything is the same in the code. I am running Vista on my local machine and Windows Server 2003 on my server...
{ "language": "en", "url": "https://stackoverflow.com/questions/425169", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: PHP passing messages between pages I have a form on a page where the user has inputs to edit a XML file, the action for the form is to send it to a separate PHP script where the editing takes place after they hit submit. The script will either write successful or fail, either way I have it redirect back to the form ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425178", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Introduction to SharePoint Designer 2007 object model using VBA I'm finding it really difficult to find an introduction to the object model used within Microsoft SharePoint Designer 2007. For some reason, the online help if full of "Page not found". I suspect it's similar to the object model used in Internet Explore...
{ "language": "en", "url": "https://stackoverflow.com/questions/425179", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to add node into TreeView Control with Javascript I just wanna learn how to add a node to TreeView control (which takes its data from database with a parent-child relationship). Of course when I select a node the new node I wanna add should be added under the selected one and after adding it into the selected no...
{ "language": "en", "url": "https://stackoverflow.com/questions/425181", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Is REALBasic worth $50? As a Windows and web developer of 12+ years and an "at home" Mac user, I'm wondering if it's worth it to get the REALBasic for personal use. I've often wanted to dabble in development for OS X; I know VB, Java, C#, but not C, C++, or Objective-C. I don't have a specific project in mind and ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425185", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "16" }
Q: Howto create a jquery-like $() wrapper function? I'm creating a small code plugin which allows you to do some things with arrays. I do not wish to add the functions to the array object using a prototype construction, what I want is that people can do something like: arrayFunction( [1, 2, 3] ).someSpecialArrayFunctio...
{ "language": "en", "url": "https://stackoverflow.com/questions/425189", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Making a horizontal list with clickable images as members I want to make a horizontal list in my application, which will display images. While this is quite trivial, I want the image to open a flex alert box (the built in one) and display some text. For example, I will have an image of the .NET logo and I will enter...
{ "language": "en", "url": "https://stackoverflow.com/questions/425191", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: What is the best definition of MVC? I have been using the Zend Framework with an MVC configuration, read about Ruby on Rails and I plan to explore other MVC frameworks in Python (Django?). I really like the way it isolates some parts of the logic, security, and validation. But after just one year of using it I read ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425197", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "11" }
Q: Can I force Maven 2 to require a property to be specified on the command line? I'm setting up a maven build, and the destination server needs to be specified on the command line as a property (which is then used to select the appropriate profile), eg mvn -Denv=test I'd like the build to fail if the property's not s...
{ "language": "en", "url": "https://stackoverflow.com/questions/425198", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "19" }
Q: How to free a C struct? Given a struct, e.g. typedef struct { int value; } TestStruct; Why does the following code (in the context of an Objective-C class running on the IPhone) throw a "non-aligned pointer being freed" exception? TestStruct ts = {33}; free(&ts); N.B. My uber goal is to use a C library with many...
{ "language": "en", "url": "https://stackoverflow.com/questions/425205", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: How do I install/deploy/build my Visual C# application so it's available to all users? I've written an application in Microsoft Visual C# 2008 Express Edition. The Windows XP computer I want to install it on has two user accounts. One is the admin account, the other is the main user account and does not have admin ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425207", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Issue with background color and Google Chrome Sometimes I get a broken background in Chrome. I do not get this error with any other browser. This is the simple CSS line responsible for the background color of body: body { background: black; color: white; font-family: Chaparral Pro, lucida grande, verdana,...
{ "language": "en", "url": "https://stackoverflow.com/questions/425216", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "45" }
Q: How are web site passwords encrypted by browsers? What are some platform-specific API's that web browsers use to securely save passwords with reversible encryption on local systems? Since they must be able to reproduce the exact characters to pass up to a web site, the data can't be a one-way hash. My initial thoug...
{ "language": "en", "url": "https://stackoverflow.com/questions/425221", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: ProgressBar freezes when using multithreading I have a ProgressBar that uses the marquee style when a report is being generated. The reason I am doing this is because the ReportViewer control I use takes some time to generate the report thus making the form unresponsive. I generate the report using a thread so the P...
{ "language": "en", "url": "https://stackoverflow.com/questions/425226", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How do I dynamically create an in JavaScript that contains an HTML entity (— ... «)? I'd like to add an <option> element to a <select> element where the <option> element's text contains an HTML entity: &mdash; In HTML, the code would look like this: <select name="test" id="test"> <option value="">&mdash; Select...
{ "language": "en", "url": "https://stackoverflow.com/questions/425234", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "10" }
Q: How to properly and completely close/reset a TcpClient connection? What is the correct way to close or reset a TcpClient connection? We have software that communicates with hardware but sometimes something goes wrong and we are no longer to communicate with it, until we restart the software. I have tried forcing Tcp...
{ "language": "en", "url": "https://stackoverflow.com/questions/425235", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "86" }
Q: Is there a BeforeUpdate for a C# ComboBox on a Winform I come from the VBA world, and remember there was a BeforeUpdate call I could make on a combobox. Now I am in C# (and loving it) and I was wondering is there a BeforeUpdate call for a ComboBox on a Winform? I can make an invisible textbox and store the info I ne...
{ "language": "en", "url": "https://stackoverflow.com/questions/425241", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Is Micro Code Generation Considered Harmful? I recently wrote a small tool to generate a class for each tier I hand write for the boring "forms over data" work where I spend almost 90% of my time (depressing I know) ... more on this as the economy improves ;) My question is this - will using this tool instead of han...
{ "language": "en", "url": "https://stackoverflow.com/questions/425242", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "11" }
Q: Error targeting .NET framework 3.0 I have an application, which I develop in VS 2008 and I target .NET 3. Unfortunately when I install on a clean computer with .NET 3, it crashes. And besides the usual TypeInitilisationError, I have no clue why. Updating the same machine to .NET 3.5SP1 makes it run fine. * *Is th...
{ "language": "en", "url": "https://stackoverflow.com/questions/425253", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Prevent line/paragraph breaks in contentEditable When using contentEditable in Firefox, is there a way to prevent the user from inserting paragraph or line breaks by pressing enter or shift+enter? A: You can attach an event handler to the keydown or keypress event for the contentEditable field and cancel the event ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425274", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "66" }
Q: Java Style: Properly handling exceptions I keep getting stuck conceptually on deciding an Exception-handling structure for my project. Suppose you have, as an example: public abstract class Data { public abstract String read(); } And two subclasses FileData, which reads your data from some specified file, and St...
{ "language": "en", "url": "https://stackoverflow.com/questions/425281", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "17" }
Q: RDoc CONSTANT comments? In RDoc, is there any way to show constant comments? I would like to comment a constant in a project of mine but and realizing that they dont show up in the RDoc output. I checked documentation which is likely to have comments for their constants, but never saw any (http://www.ruby-doc.org/co...
{ "language": "en", "url": "https://stackoverflow.com/questions/425284", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Starting application from data file When you double-click on a Word document, Word is automatically run and the document is loaded. What steps are needed to do the same thing with my C# application? In other words, assume my application uses ".XYZ" data files. I know how to tell Windows to start my application when...
{ "language": "en", "url": "https://stackoverflow.com/questions/425292", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: SQL/Database Views in Grails Does anybody know what is the best approach to accessing a sql view through Grails (or if this is even possible)? It seems an obvious way of doing this would be to use executeQuery against the view to select a collection of rows from the view which we would not treat as a list of domain ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425294", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "28" }
Q: Use smo to rename datafiles How can I use SMO to rename the physical .mdf .ndf .ldf files. This article was helpful but I need to use C# SMO Objects. Using the SMO Server Object I can retrieve the database, then Get Access to the DataFile objects. Per this link. These have a Rename, however after rename, nothing cha...
{ "language": "en", "url": "https://stackoverflow.com/questions/425296", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Is MVC the best way to code asp.net applications? update: I know there is no one best way to do everything. Sorry for not saying that right off. In the context of the data-access tutorials, if you had to do the project he did in that tutorial, would you do what he did or would use use MVC, if you had to choose on...
{ "language": "en", "url": "https://stackoverflow.com/questions/425306", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: Javascript/xhtml - discovering the total width of content in div with overflow:hidden I'm writing a javascript based photo gallery with a horizontally scrollable thumbnail bar. >> My current work-in-progress is here << I would like the thumbnail bar to stop scrolling when it gets to the last thumbnail. To do this I ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425308", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Secured and unsecured items message in IE I'm getting "This page contains bothe Secure and Non secure items"message in IE. When I commented the following piece of code from dojo.js.uncompressed.js file, the message is gone. if(dojo.isIE){ if(!dojo.config.afterOnLoad){ document.write('<scr'+'ipt defer src="//:...
{ "language": "en", "url": "https://stackoverflow.com/questions/425315", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Using C#, how can I set a Url property to an HTML file in my project? I have the following code: if (System.IO.File.Exists(htmlLocation)) { vEarthBrowser.ObjectForScripting = this; vEarthBrowser.Url = new Uri(htmlLocation); } else { throw new Exception("HTML file not found!"); } htmlLocation is defined ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425325", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: XML validation vulnerable to culture info? a day before end of project i run into a complicated issue: i have a wtf service and 3 client application using it. service has three methods, each one receiving an xml document as an argument and returning xml document. this is how they communicate. i've got some xsd files...
{ "language": "en", "url": "https://stackoverflow.com/questions/425341", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Is there a way to request permission in IE to use window.external.AddFavorite? The JavaScript security settings on Internet Explorer for my customers disallow using window.external.AddFavorite, and it generates (best case) an error in the status bar when the users click the "Add Bookmark" link on my website. Is the...
{ "language": "en", "url": "https://stackoverflow.com/questions/425342", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Python and different Operating Systems I am about to start a personal project using python and I will be using it on both Linux(Fedora) and Windows(Vista), Although I might as well make it work on a mac while im at it. I have found an API for the GUI that will work on all 3. The reason I am asking is because I have ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425343", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Abstracted References Between Entities An upcoming project of mine is considering a design that involves (what I'm calling) "abstract entity references". It's quite a departure from a more common data model design, but it may be necessary to achieve the flexibility we want. I'm wondering if other architects have exp...
{ "language": "en", "url": "https://stackoverflow.com/questions/425350", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: MS SQL Auditing I have a problem with a Database at my work. There is currently auditing in place, but its clunky, requires a lot of maintence, and it falls short in a few regards. So I am replacing it. I want to do this in as generic of a way as possible and have designed the tables, and how everything will link an...
{ "language": "en", "url": "https://stackoverflow.com/questions/425353", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: What type of reference does NSNotificationCenter keep for 'observer's & 'object's? Can anyone clarify/elucidate the situation with respect to -[NSNotificationCenter addObserver:selector:name:object:]? * *What types of references are kept by the notification center of the 'observer' and 'object' arguments? *What ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425354", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "20" }
Q: silverlight: showing/hiding user controls My silverlight app takes the user through a sort of wizard-like process, so for each screen in the wizard I've created a seperate user control. Then in my main user control (applications RootVisual) I just show/hide each user control when needed. That means that every user...
{ "language": "en", "url": "https://stackoverflow.com/questions/425357", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: LINQ to XML updates - how does it handle multiple concurrent readers/writers? I have an old system that uses XML for it's data storage. I'm going to be using the data for another mini-project and wanted to use LINQ to XML for querying/updating the data; but there's 2 scenarios that I'm not sure whether I need to han...
{ "language": "en", "url": "https://stackoverflow.com/questions/425362", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Using .gemspec version in documentation/library/script So, I've been writing a bunch of ruby gems recently, and one thing I would find convenient is to include the current version (as specified in the gemspec) in the rdoc-generated documentation for my libraries, and in the OptionParser-generated --help sections use...
{ "language": "en", "url": "https://stackoverflow.com/questions/425372", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to export data as CSV format from SQL Server using sqlcmd? I can quite easily dump data into a text file such as: sqlcmd -S myServer -d myDB -E -Q "select col1, col2, col3 from SomeTable" -o "MyData.txt" However, I have looked at the help files for SQLCMD but have not seen an option specifically for CSV. ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425379", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "163" }
Q: Launch a URL from a WinForms app I've got a VB.NET WinForms app in which I have the need to refer the user to a web page with documentation/help. I realize the LinkButton would get the trick done, but what I want is a standard Button control to launch the system default browser when that button is clicked. The only ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425381", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "34" }
Q: Providex Query Performance I am running a query against a providex database that we use in MAS 90. The query has three tables joined together, and has been slow but not unbearably, taking about 8 minutes per run. The query has a fair number of conditions in the where clause: I'm going to omit the select part of the ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425382", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Why can't I read logs stored in C:\Windows\System32\... under Vista without moving them to another location? I'm using a program that stores its log files at C:\Windows\System32\config\systemprofile\AppData\Roaming\ProgramName\*.log, but for some reason I can't view these logs unless I move them to another location....
{ "language": "en", "url": "https://stackoverflow.com/questions/425388", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: C# Equivalent of SQL Server DataTypes For the following SQL Server datatypes, what would be the corresponding datatype in C#? Exact Numerics bigint numeric bit smallint decimal smallmoney int tinyint money Approximate Numerics float real Date and Time date datetimeoffset datetime2 smalldatetime datetime time C...
{ "language": "en", "url": "https://stackoverflow.com/questions/425389", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "719" }
Q: clearTimeout on multiple setTimeout I have multiple setTimeout functions like this: function bigtomedium(visiblespan) { visiblespan.removeClass('big').addClass('medium'); setTimeout(function(){ mediumtosmall(visiblespan);},150); }; function mediumtosmall(visiblespan) { visiblesp...
{ "language": "en", "url": "https://stackoverflow.com/questions/425392", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: C++ DLL: Not exposing the entire class How can I "hide" parts of a class so that whoever is using the libary does not have to include headers for all the types used in my class. Ie take the MainWindow class below, ho can I have it so when compiled in a static/dynamic libary, whoever is useing the libary does NOT hav...
{ "language": "en", "url": "https://stackoverflow.com/questions/425400", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: What is the preferred way to show large images in OpenGL I've had this problem a couple of times. Let's say I want to display a splash-screen or something in an OpenGL context (or DirectX for that matter, it's more of a conceptual thing), now, I could either just load a 2048x2048 texture and hope that the graphics c...
{ "language": "en", "url": "https://stackoverflow.com/questions/425401", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: When learning Java, how important is it to know Unix well? Other than the Java language itself, you have to learn the java framework. Similiar to how you have to learn the .net framework in addition to the language (C#/VB). How important is it to know unix? Or rather, what unix areas should one focus on? Seeing as...
{ "language": "en", "url": "https://stackoverflow.com/questions/425402", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Is it smart to always redirect to https? I am working on a project where the user will transfer his username to activate the internet. I want to always redirect the user to the https version and make the http version redirect to the https aswell, so there is only an http version. Is this a smart move? Could there be...
{ "language": "en", "url": "https://stackoverflow.com/questions/425405", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Extend Javascript Function passed as parameter I have a javascript function (class) that takes a function reference as one paremter. function MyClass ( callBack ) { if (typeof callBack !== 'function') throw "You didn't pass me a function!" } For reasons I won't go in to here, I need to append something to the...
{ "language": "en", "url": "https://stackoverflow.com/questions/425407", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How to check SOUNDEX in php when php SOUNDEX outputs only 3 digits I am trying to do a comparison between company names using SOUNDEX, but the php call for soundex only outputs 3 digits so the comparisons aren't quite accurate. Is there a way to get a better soundex output so that the results are more accurate? A:...
{ "language": "en", "url": "https://stackoverflow.com/questions/425421", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Databinding to a programmatically created DataTable Suppose I have a datatable like this: DataTable dt = new DataTable("Woot"); dt.Columns.AddRange(new DataColumn[]{ new DataColumn("ID",typeof(System.Guid)), new DataColumn("Name",typeof(String)) }); When I try to...
{ "language": "en", "url": "https://stackoverflow.com/questions/425424", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: In-text hyperlinks shown by Internet Explorer without the following space. What can be the reason? YUI? I've a problem which is most likely some ugly CSS mistake, but I just can't spot the solution (and a few changes I tried did not help). Some of in-text hyperlinks (not all!) are shown by Internet Explorer without ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425429", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How do you return a vector iterator from a variable in a templated class? I'm trying to return an iterator for a vector in a templated class (I'm not sure if that makes a difference, but I've read that may, so I thought I'd mention it). The problem is that I get an error about C++ not supporting default-int when I ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425430", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to check if array element is null to avoid NullPointerException in Java I have a partially nfilled array of objects, and when I iterate through them I tried to check to see whether the selected object is null before I do other stuff with it. However, even the act of checking if it is null seem to through a NullP...
{ "language": "en", "url": "https://stackoverflow.com/questions/425439", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "21" }
Q: Inheriting from a non-templated class that has a templated constructor - how to resolve ambiguity? Let's say we have a class, MyParent: class MyParent { public: template<namespace T> MyParent() { T* Something; } }; And a derived class, which uses this constructor: class MyDerived : public MyParent { pub...
{ "language": "en", "url": "https://stackoverflow.com/questions/425457", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How Do I add a local Mysql user for Rails Dev? I have a problem where I always need to give simple access to my local account, and don't want to deal with typing in my root password a million times on my local machine. How do I give perms so i can type 'mysql' with my local user and get access to everything? A: Thi...
{ "language": "en", "url": "https://stackoverflow.com/questions/425461", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Windows XP, Vista and now Windows 7, is this a maintenance nightmare for software companies? For software applications like games, does this mean software companies have a lot of extra coding to maintain 3 branches of certain libraries? I know this is hard to say, but for game development in general, are there speci...
{ "language": "en", "url": "https://stackoverflow.com/questions/425472", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Listing all indexes I'm wondering what the simplest way to list all indexes for all tables in a database is. Should I call sp_helpindex for each table and store the results in a temp table, or is there an easier way? Can anyone explain why constraints are stored in sysobjects but indexes are not? A: You could r...
{ "language": "en", "url": "https://stackoverflow.com/questions/425475", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "23" }
Q: Navigating backward and forward with the mouse in Visual Studio 2008 My install of Visual Studio 2008 does not support IE style back and forward navigation withe the mouse in the C# code editor. Searches show that multiple people have run into this problem but I have yet to find a correct solution. There's even a ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425492", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: jquery plugin for preventing entering any input not matching a regexp does jquery have any plugin that prevents entering any input to a textbox that doesnt match a regexp pattern. for example , i have a textbox for entering payment amount, i want user t be able to enter only numebers and . in the textbox, all other ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425497", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: What tools do I need to develop in ActionScript (in Linux) I've never developed Flash before but I have a project where I want to use an ActionScript 3 library and I'm not sure what tools I need to start. To further complicate things my main development box is an Ubuntu box. Are there any necessary packages I need t...
{ "language": "en", "url": "https://stackoverflow.com/questions/425511", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "19" }
Q: Custom PageHandlerFactory for .aspx I am building a fairly simple CMS. I need to intercept requests for the majority of .aspx pages in my web application, in order to gain complete control over the output. In most cases, the output will be pulled from cache and will just be plain HTML. However, there still are a c...
{ "language": "en", "url": "https://stackoverflow.com/questions/425512", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: How to do a "NOT IN" expression using the Criteria API in NHibernate? I am able to use the NHibernate Criteria API for an IN statement using new NHibernate.InExpression() Is there a way using the Criteria API to get a "NOT IN" statement? A: Use a NotExpression around it.
{ "language": "en", "url": "https://stackoverflow.com/questions/425514", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How do I programmatically create a bootable CD? I'm using a barebones tutorial as the basis for an OS I'm working on, and it seems to be an older tutorial: it has be compiling the kernel down to a floppy image, and then loading it with GRUB. Basically, I still want to use GRUB, but I'd like to have my OS run from a ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425519", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: Rails: modify form parameters before modifying the database I'm working on a Rails app that sends data through a form. I want to modify some of the "parameters" of the form after the form sends, but before it is processed. What I have right now {"commit"=>"Create", "authenticity_token"=>"0000000000000000000000000"...
{ "language": "en", "url": "https://stackoverflow.com/questions/425521", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "11" }
Q: How do I prevent selectedValue altering when calling tableAdapter's Fill() method? I have bound my ListBox to some data. The problem is when I call myTableAdapter.Fill(..) method, SelectedValue changes to whatever is the first item ID in the list. Although "Selected Value" in VS is not bound anywhere (see image). al...
{ "language": "en", "url": "https://stackoverflow.com/questions/425531", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: silverlight: How to set attached properties Programmatically Suppose I have a grid with some row definitions, and a child control in that grid. How would I go about setting the Grid.Row property of the child control programatically? A: Actually to clear a value you should use this: textBlock.ClearValue(Grid.RowPro...
{ "language": "en", "url": "https://stackoverflow.com/questions/425537", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "22" }
Q: How do you manage hundreds of "shapes" with a LINQ-based model I have a relatively modest dataset (probably 20 main tables) but it's queried a lot of different ways. Sometimes we show a product. Sometimes a product with it's picture. Sometimes a product with it's picture and comments. Sometimes a product with i...
{ "language": "en", "url": "https://stackoverflow.com/questions/425544", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: asp:CheckBoxField in GridView - VS 2008 I have a gridview control bound to an object data source. in addition to the columns that i want to display i want to display this <Columns> <asp:CheckBoxField DataField="Locked" Visible="true" AccessibleHeaderText="On Hold" ReadOnly="false"/> </Columns> Couple of ...
{ "language": "en", "url": "https://stackoverflow.com/questions/425548", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Connection Pooling Not working in .Net SQL Server 2008 I'm testing out my application with the hopes of migrating to SQL Server 2008 (From 200). In the SQL Server profiler, I'm seeing Audit Login SQL:BatchStarting SELECT ..... SQL:BatchCompleted SELECT ..... Audit Logout fo...
{ "language": "en", "url": "https://stackoverflow.com/questions/425558", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How do I customize the auto commenting text in Visual Studio? When I type the trigger the auto comment feature in Visual Studio (by typing "'''" or "///"), most of the XML commenting details show up that I like. However, I typically add the history tag to the documentation so I can track and changes that are made to...
{ "language": "en", "url": "https://stackoverflow.com/questions/425559", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "10" }
Q: Where are the latest ASP.NET MVC bits? Are the latest bits for MVC the Preview 5 release? I've been out of the loop for a while and just wanted to make sure I had the latest and greatest. A: Here is the download like: Microsoft ASP.NET MVC Beta The main site is www.asp.net/mvc Source code is here: www.codeplex.com/...
{ "language": "en", "url": "https://stackoverflow.com/questions/425574", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Template instantiation with VARIANT return type An explicit instantiation of a static template member function keeps failing to compile with the message error C2785: 'at_Intermediate CUtil::convert_variant(const VARIANT &)' and '<Unknown>' have different return types When I make a corresponding class with non-static...
{ "language": "en", "url": "https://stackoverflow.com/questions/425576", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How do I paint Swing Components to a PDF file with iText? I would like to print my Swing JComponent via iText to pdf. JComponent com = new JPanel(); com.add( new JLabel("hello") ); PdfWriter writer = PdfWriter.getInstance( document, new FileOutputStream( dFile ) ); document.open( ); PdfContentByte cb = writer.get...
{ "language": "en", "url": "https://stackoverflow.com/questions/425590", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Programmatically adjust font size to fit text inside a textbox in Word One of my applications deals with MS Word and Document creation/editing/formatting. I am using Office 2007 w/ VS 2008, and i'm coding against the Microsoft.Office.Interop.Word library, which seems to work with either 2003 or 2008. I create a Te...
{ "language": "en", "url": "https://stackoverflow.com/questions/425593", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Best way to determine if a sequence is in another sequence? This is a generalization of the "string contains substring" problem to (more) arbitrary types. Given an sequence (such as a list or tuple), what's the best way of determining whether another sequence is inside it? As a bonus, it should return the index of...
{ "language": "en", "url": "https://stackoverflow.com/questions/425604", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "30" }
Q: XPS or XAML viewer to embed in .NET app? Is there a viewer object or ActiveX control I can use to embed an XPS document, or an XAML GUI in my .NET application? A: You can use the ElementHost Control to host WPF content on a .Net Windows Form.The ElementHost appears in the Toolbox under the WPF Interoperability sec...
{ "language": "en", "url": "https://stackoverflow.com/questions/425605", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Performance anti patterns I am currently working for a client who are petrified of changing lousy un-testable and un-maintainable code because of "performance reasons". It is clear that there are many misconceptions running rife and reasons are not understood, but merely followed with blind faith. One such anti-pa...
{ "language": "en", "url": "https://stackoverflow.com/questions/425612", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "13" }