text
stringlengths
8
267k
meta
dict
Q: Greasemonkey: Text processing - What's the best way to find certain words in a website and have a function work on it? I want greasemonkey to scan through a website and change certain words to something else. Is there a way to do it with regex or some other string processing function in javascript? Thanks for your ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439487", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: What can we do about a randomly crashing app without source code? I am trying to help a client with a problem, but I am running out of ideas. They have a custom, written in house application that runs on a schedule, but it crashes. I don't know how long it has been like this, so I don't think I can trace the crashes...
{ "language": "en", "url": "https://stackoverflow.com/questions/439489", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How can I escape square brackets in a LIKE clause? I am trying to filter items with a stored procedure using like. The column is a varchar(15). The items I am trying to filter have square brackets in the name. For example: WC[R]S123456. If I do a LIKE 'WC[R]S123456' it will not return anything. I found some informa...
{ "language": "en", "url": "https://stackoverflow.com/questions/439495", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "291" }
Q: ID fields in SQL tables: rule or law? Just a quick database design question: Do you ALWAYS use an ID field in EVERY table, or just most of them? Clearly most of your tables will benefit, but are there ever tables that you might not want to use an ID field? For example, I want to add the ability to add tags to obj...
{ "language": "en", "url": "https://stackoverflow.com/questions/439507", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Can a VBA function in Excel return a range? I seem to be getting a type mismatch error when trying to do something like this: In new workbook: A1 B1 5 4 Function Test1() As Integer Dim rg As Range Set rg = Test2() Test1 = rg.Cells(1, 1).Value End Function Function Test2() As Range Dim rg As Range ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439510", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "29" }
Q: Run a .NET program from a mapped drive or shared folder - Pros/Cons This may be a silly question for some of you, but what are Pros/Cons of running a Windows Forms .Net application from a shared drive. Up until recently I didn't even know this was possible. From research it looks like .Net 3 SP1 allows this behavior...
{ "language": "en", "url": "https://stackoverflow.com/questions/439515", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Thinking in Vectors with R I know that R works most efficiently with vectors and looping should be avoided. I am having a hard time teaching myself to actually write code this way. I would like some ideas on how to 'vectorize' my code. Here's an example of creating 10 years of sample data for 10,000 non unique combi...
{ "language": "en", "url": "https://stackoverflow.com/questions/439526", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "26" }
Q: Changing the .NET application configuration file name I have a VB6 app which calls a .NET assembly, which references settings from the app.config file. By default, .NET looks for a config file named after the VB6 app. How can I redirect it to use a different config file name? This needs to become the default config ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439538", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "10" }
Q: Function pointer to class member function problems First of all I have to admit that my programming skills are pretty limited and I took over a (really small) existing C++ OOP project where I try to push my own stuff in. Unfortunately I'm experiencing a problem which goes beyond my knowledge and I hope to find some ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439540", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Delegates and Lambdas and LINQ, Oh My! As a fairly junior developer, I'm running into a problem that highlights my lack of experience and the holes in my knowledge. Please excuse me if the preamble here is too long. I find myself on a project that involves my needing to learn a number of new (to me) technologies, i...
{ "language": "en", "url": "https://stackoverflow.com/questions/439541", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "12" }
Q: How to prevent scrollbars from overlapping the content? I have a block of preformatted code (<pre>) which overflows horizontally so there is an horizontal scrollbar to allow the user to view the content. overflow: auto; However, in IE7 (maybe other IE versions), the scrollbar overlaps the last line of my content (w...
{ "language": "en", "url": "https://stackoverflow.com/questions/439553", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "13" }
Q: Regular Expression to match {if cond}foo{else}bar{/if} I'm having difficulty throwing away the bits of the expression I don't want, and keeping the bits I do. The problem is - given the input string: {if cond}foo{else}bar{/if} I'd like just to have: 0: {if cond}foo{else}bar{/if} 1: cond 2: foo 3: bar And for the i...
{ "language": "en", "url": "https://stackoverflow.com/questions/439561", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Dictionary like implementation in C/C++ (Update info) Does anyone have information or example of how to mount the equivalent of a Dictionary (VB6) in C or C++ ? This implementation is used to be passed as a parameter called DLL VB6. My intention is to create a Dictionary in C (win32 using VARIANT/ARRAYs, etc) and pa...
{ "language": "en", "url": "https://stackoverflow.com/questions/439572", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to convert a single char into an int I have a string of digits, e.g. "123456789", and I need to extract each one of them to use them in a calculation. I can of course access each char by index, but how do I convert it into an int? I've looked into atoi(), but it takes a string as argument. Hence I must convert e...
{ "language": "en", "url": "https://stackoverflow.com/questions/439573", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "70" }
Q: What's the best way to refactor a method that has too many (6+) parameters? Occasionally I come across methods with an uncomfortable number of parameters. More often than not, they seem to be constructors. It seems like there ought to be a better way, but I can't see what it is. return new Shniz(foo, bar, baz, q...
{ "language": "en", "url": "https://stackoverflow.com/questions/439574", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "125" }
Q: best way to programmatically modify excel spreadsheets I'm looking for a library that will allow me to programatically modify Excel files to add data to certain cells. My current idea is to use named ranges to determine where to insert the new data (essentially a range of 1x1), then update the named ranges to point...
{ "language": "en", "url": "https://stackoverflow.com/questions/439580", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: Printing multiple pages of different data In my app I have several forms that print specific data. For accomplish that I use the PrintDocument PrintPage Event. If one report has more than 1 page, I set the hasMorePages flag to true, and the event is fired again and it is my responsability to continue printing from...
{ "language": "en", "url": "https://stackoverflow.com/questions/439591", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How to check for deletions on a LINQ to SQL EntitySet I have an entity that has a collection of associated entities in an EntitySet. Ultimately, I'm trying to report on some changes that have been made to this entity. I will most likely use the GetModifiedMembers() method to do this, and I'm guessing I can just do t...
{ "language": "en", "url": "https://stackoverflow.com/questions/439611", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How do send a Collection of Enums to a WCF Service I am having trouble sending a collection of Enums to a WCF service method. I used this post as a guide: Sharing Enum with WCF Service [ServiceContract] [ServiceKnownType(typeof(MyEnum))] [ServiceKnownType(typeof(List<MyEnum>))] public interface IMyService{ [Op...
{ "language": "en", "url": "https://stackoverflow.com/questions/439612", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Hanging process when run with .NET Process.Start -- what's wrong? I wrote a quick and dirty wrapper around svn.exe to retrieve some content and do something with it, but for certain inputs it occasionally and reproducibly hangs and won't finish. For example, one call is to svn list: svn list "http://myserver:84/svn...
{ "language": "en", "url": "https://stackoverflow.com/questions/439617", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "32" }
Q: JAXB XmlID and XmlIDREF annotations (Schema to Java) I am exposing a web service using CXF. I am using the @XmlID and @XmlIDREF JAXB annotations to maintain referential integrity of my object graph during marshalling/unmarshalling. The WSDL rightly contains elements with the xs:id and xs:idref attributes to represen...
{ "language": "en", "url": "https://stackoverflow.com/questions/439629", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Create a Date with a set timezone without using a string representation I have a web page with three dropdowns for day, month and year. If I use the JavaScript Date constructor that takes numbers, then I get a Date object for my current timezone: new Date(xiYear, xiMonth, xiDate) Give the correct date, but it think...
{ "language": "en", "url": "https://stackoverflow.com/questions/439630", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "498" }
Q: How can I script the body of a VMS mail? I have a script that addresses and sends an email but I need a body in the message without creating a file and then inserting the file with the standard MAIL commandline. How can I do that? A: Assuming the body you want to create is something you can write to SYS$OUTPUT (e.g...
{ "language": "en", "url": "https://stackoverflow.com/questions/439635", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: netTcpBinding - Pending Security Sessions I've got an internal service hosted over tcp. It's being self-hosted inside of a windows service. The service works fine for the most part, but once in awhile I'll get a bunch of exceptions (all in a row) from it. System.ServiceModel.Security.SecuritySessionServerSettings....
{ "language": "en", "url": "https://stackoverflow.com/questions/439637", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: PIL vs RMagick/ruby-gd For my next project I plan to create images with text and graphics. I'm comfortable with ruby, but interested in learning python. I figured this may be a good time because PIL looks like a great library to use. However, I don't know how it compares to what ruby has to offer (e.g. RMagick an...
{ "language": "en", "url": "https://stackoverflow.com/questions/439641", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: How do I print unique elements in Perl array? I'm pushing elements into an array during a while statement. Each element is a teacher's name. There ends up being duplicate teacher names in the array when the loop finishes. Sometimes they are not right next to each other in the array, sometimes they are. How can I pr...
{ "language": "en", "url": "https://stackoverflow.com/questions/439647", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "25" }
Q: Getting process information in .NET Duplicate of this question. update - This is not an exact duplicate. See my solution. I see a java.exe process in process explorer, and double clicking it gives me its working directory & starting command line arguments. From .NET, I run the following code and get a process with t...
{ "language": "en", "url": "https://stackoverflow.com/questions/439653", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Can Visual Studio 2005 Pro generate UML style class diagrams? Can Visual Studio 2005 Pro generate UML style class diagrams? A: You can click on the magnifier icon in Solution Explorer window. Then the diagram will be generated. A: 2005 does not have a UML modeler. The class designer mentioned above will allow you ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439655", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: MySQL design with dynamic number of fields My experience with MySQL is very basic. The simple stuff is easy enough, but I ran into something that is going to require a little more knowledge. I have a need for a table that stores a small list of words. The number of words stored could be anywhere between 1 to 15. ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439656", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: XSD - Child elements depending on attribute value I am trying to create an XSD schema for the following XML: <root> <!-- The actual file must contain one of the following constraints --> <constraint type="interval"> <min>100</min> <max>200</max> </constraint> <constraint type="equals"> <value>EO...
{ "language": "en", "url": "https://stackoverflow.com/questions/439657", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: What is the difference between #import and #include in Objective-C? What are the differences between #import and #include in Objective-C and are there times where you should use one over the other? Is one deprecated? I was reading the following tutorial: http://www.otierney.net/objective-c.html#preamble and its para...
{ "language": "en", "url": "https://stackoverflow.com/questions/439662", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "405" }
Q: I must enclose object creation/release with try/finally? In Delphi, is normal do this: ob = TObject.create; try //code finally ob.free; end; I wonder if that is similar in Obj-c. A: You could do it that way, but exceptions tend to have a high cost in Objective-C. There are some differences in their performance...
{ "language": "en", "url": "https://stackoverflow.com/questions/439664", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: svn:switch doesn't work with relative svn:external? We have a subfolder that is a relative svn external (../project/subfolder). In a fresh trunk checkout it points to (...TRUNK/project/subfolder) and in a fresh branch checkout it points to (...BRANCH/branchName/project/subfolder). But if you do a switch on the pro...
{ "language": "en", "url": "https://stackoverflow.com/questions/439666", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How can I mix COUNT() and non-COUNT() columns without losing information in the query? I started with a query: SELECT strip.name as strip, character.name as character from strips, characters, appearances where strips.id = appearances.strip_id and characters.id = appearances.character.id and appearances.date...
{ "language": "en", "url": "https://stackoverflow.com/questions/439670", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to run JavaScript prior to System.Web.UI.Timer OnTick? I need a client-side script to confirm that the Timer's OnTick event can proceed. How do I invoke CanContinue() before the Timer1 postback occurs? How do I cancel the postback if user selects Cancel? <%@ Page Language="C#" %> <script runat="server"> ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439677", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Arithmetic operators against varchar data in SQL server Could someone please explain to me how arithmetic operators such as > or < compare strings in SQL Server 2005? A: If they are against a numeric field, they work about as you would expect. If it's against a character type of data field, they would work alphabet...
{ "language": "en", "url": "https://stackoverflow.com/questions/439679", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Modifying cells in SQL Server Management Studio 2005 without a mouse I'm always making manual changes to a lot of data as part of my job. One thing I've noticed is that I can use the arrow keys to browse around to different cells when viewing the data. But when I go to a new cell, the entire text in it is highlighte...
{ "language": "en", "url": "https://stackoverflow.com/questions/439681", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Implementing a tree in c# managing parent-child I am implementing a tree think of it as a folder structure so I have a class that looks like: public class Folder { //Various Props like Name etc. public IList<Folder> Children{get;} public Folder Parent {get;} } Now what I want is to be able to walk up an...
{ "language": "en", "url": "https://stackoverflow.com/questions/439686", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Fixing the timezone on Solaris 10 I have no ideas how to fix this. In my /etc/TIMEZONE file the TZ variable has the correct value (Canada/Eastern) and still it's showing a -1 hour lag. Where else should I be looking? A: You should check what your hardware clock is. I would suggest doing this: * *Set the UTC ti...
{ "language": "en", "url": "https://stackoverflow.com/questions/439690", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to run a recorded (HTML) selenium test from .NET I run Selenium tests with Selenium RC from .NET (c#). In some cases, I would like to keep the test case source as HTML (to be able to modify it from Selenium IDE), but I would like to run/include these tests from my c# unit tests. Maybe it is obvious, but I can't ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439693", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: What is the best ORB for Java/C++ interoperation using CORBA? I have a client-server application written in Java using CORBA for the communication. The ORB used is orbd, the one provided by the Java6 platform. I have to replace the Java server implementation with another one written in C++. So the question is, of th...
{ "language": "en", "url": "https://stackoverflow.com/questions/439704", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: Solution File in VS 2008 I have referenced a config file that is located in a solution folder. I then reference that file in my projects. How do I get that config file into the bin directory when I publish the project? A: Select the file and then Properties->Copy to Output Directory->Copy Always
{ "language": "en", "url": "https://stackoverflow.com/questions/439706", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Is there any scenario where an application instance runs across multiple computers? We know that a single application instance can use multiple cores and even multiple physical processors. With cloud and cluster computing, or other special scenario, I don't know if a single stance can run across multiple computers, ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439714", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: MIDP heap vs VM heap Some Java mobile devices have distinct heaps for MIDP and VM. What's the distinction between these two heaps, and how can a J2ME app control which is used for a given piece of data? A: You can't control which one is used by your MIDlet, it's decided by the implementation of the KVM (and thus by...
{ "language": "en", "url": "https://stackoverflow.com/questions/439721", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Linking issue with indirect dependencies on Mac OS X we have some linking problems with indirect dependencies. Guessing from what I read on the web it may be because of two-level namespace usage. This happens when we link against a boost library, boost_filesystem to be precise, which itself depends on boost_system. ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439727", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Decorator Chaining of Repositories and Specialized Repositories with Dependancy Injection Right now I'm trying to figure out a way to do things smarter, and in the course of doing so all i've managed to do is use a full bottle of excedrin in a single day. Assume i have an interface called IRepository like so. publi...
{ "language": "en", "url": "https://stackoverflow.com/questions/439729", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: making download option in grails Possible Duplicate: Grails File Download I am in the training of web developement.I want make a page which shows all the files in the D://downloads directory.I made that part in grails.If i click on the particular file i want download that file.I dont know how to make that part.I ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439734", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Removing objects from Java Collections I have a HashMap (although I guess this question applies to other collections) of objects. From what I understand, when the documentation talks about removing mappings, then it is removing the entry from the hashtable, i.e. not necessarily destroying the actual object. If the o...
{ "language": "en", "url": "https://stackoverflow.com/questions/439738", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Visual Source Safe Version 8 My issue is that when I check a project out of SS I sometimes do not get the latest version of the project, and when I check a project into SS the .frx files are corrupt. A: Are you tied to SS? Can you not use a more modern repository? Subversion would be a good start. Getting that s...
{ "language": "en", "url": "https://stackoverflow.com/questions/439740", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Flash AS2: How to POST CDATA to a server? I have an XML object that I want to send to my player via HTTP POST. This is all good when using XML.sendAndLoad. The problem is that when the XML object I generate contains CDATA, the CDATA is stripped out before the POST occurs. so if I have: var xml:XML = new XML("<root...
{ "language": "en", "url": "https://stackoverflow.com/questions/439747", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: T-SQL: Selecting rows to delete via joins Scenario: Let's say I have two tables, TableA and TableB. TableB's primary key is a single column (BId), and is a foreign key column in TableA. In my situation, I want to remove all rows in TableA that are linked with specific rows in TableB: Can I do that through joins? De...
{ "language": "en", "url": "https://stackoverflow.com/questions/439750", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "530" }
Q: Access sound card or OS synthesizer device in Java When I try to list Synthesizer devices in Java (1.6.0), I get only one device, Java Sound Synthesizer. I want to use the Synthesizer in the sound card or use any other installed synthesizer, eg. the Microsoft Synthesizer. How can I go about doing that ? If this capa...
{ "language": "en", "url": "https://stackoverflow.com/questions/439758", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Is a PHP, Python, PostgreSQL design suitable for a business application? I'm looking for some quick thoughts about a business application I am looking to build. I'd like to separate the three layers of presentation, domain logic, and data using PHP, Python, and PostgreSQL, respectively. I would like to hear, possib...
{ "language": "en", "url": "https://stackoverflow.com/questions/439759", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: JVM heap sizing in VMware guests This question is probably better phrased: how does running a Java server on a hypervisor such as VMware ESX affect the Java heap? * *Access to JVM heap is random from the OS/hypervisor perspective *It is difficult to for guest OS or hypervisor to optimize memory that is randomly ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439777", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: public directory for .htaccess I have a dispatcher function in index.php so URLs like: /blog/show go to /index.php/blog/show <IfModule mod_rewrite.c> RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^(.*)$ index.php?url=$1 [QSA,L] </IfModule> How ca...
{ "language": "en", "url": "https://stackoverflow.com/questions/439784", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: How to implement shared memory in .NET? I have a C++.NET app and a C#.NET app. I would like them to communicate via shared memory. How is it possible in .NET version 2.0 ? Mainly want to share a queue object. A: There are several options for your applications to communicate. The most popular are Remoting and Pipes....
{ "language": "en", "url": "https://stackoverflow.com/questions/439787", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "18" }
Q: external interface I have a calc function in java script that takes three integer parameters, following is the AS3 code import flash.external.ExternalInterface; var para:Array = new Array(); send_btn.addEventListener(MouseEvent.CLICK, clickListener); function clickListener(eventObj:Object ):void { para.push(me...
{ "language": "en", "url": "https://stackoverflow.com/questions/439794", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Is it better to convert existing user accounts for them or have the users re-register? I'm rewriting a website and going from a home-grown authentication model where users logged in with their account id (numbers) and password, to .NET FormsAuthentication where users will login with a username that they choose (or i...
{ "language": "en", "url": "https://stackoverflow.com/questions/439796", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: What's a good Java, curses-like, library for terminal applications? I would like to write a Java terminal application that does screen manipulation. Are there any good libraries out there that allow you to manipulate the screen like curses in the *nix/C world? Minimal features I'm looking for are windowing and user ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439799", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "112" }
Q: Prime factor of 300 000 000 000? I need to find out the prime factors of over 300 billion. I have a function that is adding to the list of them...very slowly! It has been running for about an hour now and i think its got a fair distance to go still. Am i doing it completly wrong or is this expected? Edit: Im trying ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439814", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: user defined Parameter used as part of a filename in Access I have an access 2007 Database that outputs a report in excel format, the report is dependent on a date parameter that is chosen by the user. This parameter is selected via a textbox (text100) that has a pop up calendar. I would like to use the date in the ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439815", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Customizing Linq to Sql DataContext Is there anyway simple ways to add a property to Linq to Sql generated entity to reference its DataContext? For example: var myContext = new DataContext(); var product = context.Products.Where(p => p.Id == productId).SingleOrDefault(); and product entity has a property called "...
{ "language": "en", "url": "https://stackoverflow.com/questions/439823", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Where do rspec tests for code under lib/ go? I've got some code in the lib/ directory that don't really belong under controls, models or helpers. I'd like to write some rspec tests for this code, but am not sure where they should go under the spec/ directory. Is there a convention that's commonly followed? A: I w...
{ "language": "en", "url": "https://stackoverflow.com/questions/439828", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "33" }
Q: Crystal reports: is there a way to regex in crystal reports? I have a crystal report function which requires me to trim off characters which start with a "-" and delete the rest following the the "-" (dash). For example, I would have order number 00000112345-C43-PJ. How would I just trim off everything from the r...
{ "language": "en", "url": "https://stackoverflow.com/questions/439829", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Import VBScript General Date Time Into MS Access Date/Time Column Setup I have a VBScript for driving the stress testing of a web service. The script creates a data file of measurements, with each record timestamped with a general date/time: FormatDateTime(Now(), 0) This creates dates like mm/dd/yyyy hh:mm:ss [AM|P...
{ "language": "en", "url": "https://stackoverflow.com/questions/439831", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Cannot execute program if using boost (C++) libraries in debug-version on WinXP I'm using boost for several C++ projects. I recently made a upgrade (1.33.1 to 1.36, soon to 1.37), since then I cannot run any debug-builds anymore. To be sure that no other project issues remain, I've created a minimum test-project, w...
{ "language": "en", "url": "https://stackoverflow.com/questions/439840", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How do you (Unit) Test the database schema? When there are a number of people working on a project, all of who could alter the database schema, what's the simplest way to unit test / test / verify it? The main suggestion we've had so far is to write tests for each table to verify column names, constraints, etc. Has ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439855", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "11" }
Q: Is there a movie showtime api? Does anyone know of any (preferrably free) supported api's for accessing movie showtimes by zip code? I don't believe any existing api's, such as netflix or imdb, provide this information. A: Yep, Yahoo apparently removed their secret movie API in November 2009. It seems everyone gets...
{ "language": "en", "url": "https://stackoverflow.com/questions/439857", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "71" }
Q: Advantage of SQL SERVER CLR What advantages does SQLServer CLR offer over T-SQL? Is using .NET syntax easier than T-SQL? I see that you can define user types, but I'm not quite clear on why that's better. For example, you could define an email type and it would have a prefix property and a domain property. You could...
{ "language": "en", "url": "https://stackoverflow.com/questions/439859", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "13" }
Q: Spring MVC tag interaction with custom tag I have a JSP that is using Spring:form tags to bind controls to a command object. I would like to modify it as follows: if [some condition is true] than display the controls; otherwise, just display the text. (Examples: if the user is an Admin, display the controls, otherwi...
{ "language": "en", "url": "https://stackoverflow.com/questions/439861", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: Why are primes important in cryptography? One thing that always strikes me as a non-cryptographer: Why is it so important to use prime numbers? What makes them so special in cryptography? Does anyone have a simple short explanation? (I am aware that there are many primers and that Applied Cryptography is the Bible, ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439870", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "205" }
Q: XAML Template Binding Horizontally I'm wondering how one could use template databinding to accomplish what the following code produces (a grid of checkboxes with some associated text): int tbIndex = 0; for (int i = 1; i < 5; i++) { StackPanel pan = new StackPanel(); pan.Orien...
{ "language": "en", "url": "https://stackoverflow.com/questions/439877", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Guidelines for using IDictionary (.NET) I believe that IDictionary classes works better with sortable objects. I believe also that the IComparer interface is necessary to sort objects from a class. I also read at MSDN that when you implement IComparable you'll need to override the Equals method (and GetHashCode by e...
{ "language": "en", "url": "https://stackoverflow.com/questions/439897", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: C# - Modifying a Data Table I have a Data Table that is filled from a database connection. I would like to run checks on the Data Table like replacing the numbers with text and add my own data before binding it to the Data Grid for viewing. How do I access one piece of data in the Data Table? Thanks. A: Just look i...
{ "language": "en", "url": "https://stackoverflow.com/questions/439900", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Java equivalent to C#'s TimeSpan Does Java have a data type that represents a period of time eg 34 seconds, 5 minutes etc. I've seen a few implementations of a TimeSpan that cover a Time period like from the 10th of December to the 11th of December. What I need is something like TimeSpan in C#. A: Not a part of the...
{ "language": "en", "url": "https://stackoverflow.com/questions/439903", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "34" }
Q: UTF-8 From File to TextBox VC++ 6.0 How do I get an old VC++ 6.0 MFC program to read and display UTF8 in a TextBox or MessageBox? Preferably without breaking any of the file reading and displaying that is currently written in there (fairly substantial). I read a line into CString strStr, then used this code: int nL...
{ "language": "en", "url": "https://stackoverflow.com/questions/439915", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Applying taxes on Satchmo's cart total price I can't seem to apply a tax value on the cart total value even though I : * *activated the "By Country/Area" tax module. *added my country/region tax rate. *checked the "Show With tax included" checkbox. here's attached a screenshot of the on-going problems, I've s...
{ "language": "en", "url": "https://stackoverflow.com/questions/439917", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How does "map" interpret its first argument in Perl? I have some questions about Perl's "map" function. Specifically: * *How does %hash = map {$_ => 1} @array create a hash mapping array's elements to 1? How does block return a list of two elements? I thought block returns its last value. Does => implicitly creat...
{ "language": "en", "url": "https://stackoverflow.com/questions/439927", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Getting currently logged on user when running as admin I've written an installer using NSIS and I need it to install some files (DLLs etc.) in a standard location like C:/Program Files/App Name/. I also need to install files in the current user's Application Data directory. The problem is that when the user is not a...
{ "language": "en", "url": "https://stackoverflow.com/questions/439932", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Need to convert EPS files to jpg/png in Java We have a webapp where people can upload various image file types and on the backend we convert them to a standard type (typically png or jpeg). Right now we are using ImageIO to do this. However the new requirement is to be able to support eps files. I haven't found a...
{ "language": "en", "url": "https://stackoverflow.com/questions/439934", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Move/rename project in Visual Studio 2008 with TFS Our team is developing a new product on the base of the old one and I received an honorable task of renaming old projects to the new name. For example: * *project OldProductLib.vcproj must become NewProductLib.vcproj *\main\OldLib must become \main\NewLib ... ...
{ "language": "en", "url": "https://stackoverflow.com/questions/439941", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Highest Performance Database in Java I need ideas to implement a (really) high performance in-memory Database/Storage Mechanism in Java. In the range of storing 20,000+ java objects, updated every 5 or so seconds. Some options I am open to: Pure JDBC/database combination JDO JPA/ORM/database combination An Object D...
{ "language": "en", "url": "https://stackoverflow.com/questions/439958", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "16" }
Q: ClearCase: How to find elements that do NOT have a particular label I'm looking for a ClearCase command that will list all the elements that are visible in my current view, but do NOT have a particular label applied to them. Say for example, most of the elements that are visible in my view have LABEL_X applied to th...
{ "language": "en", "url": "https://stackoverflow.com/questions/439959", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Correct Model Data Structure? (My 1st Rails App) I'm about to build my first Ruby on Rails application (and first anything beyond xhtml and css), and I'm looking for some helpful feedback on my model structure. I've included a mockup to help visual the application. The only models I'm sure I need so far are: 1. a mo...
{ "language": "en", "url": "https://stackoverflow.com/questions/439966", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Make the C preprocessor ignore certain #include directives I use a parser generator here, that unfortunately insists on putting a #include <some/file.h> at the top of every generated source file. The header has since long been renamed. While it is no problem forcing the compiler (gcc) to use the new header with -in...
{ "language": "en", "url": "https://stackoverflow.com/questions/439970", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to force Buttons, TextBoxes to repaint on form after a MessageBox closes in C# I have a form with buttons, textBoxes and userControls on it. When a button is clicked, it calls a method in another class. In this class a Message box opens. When user clicks OK, the messageBox closes, and the class method proceed...
{ "language": "en", "url": "https://stackoverflow.com/questions/439974", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Writing a CANopen test utility How do I listen in (preferably using Java) on a small set of well-defined CANopen messages without a commercial CANopen stack? A: There is really nothing special about CANopen in this regard. If you are able to read CAN data from the CAN bus you should be OK. The CAN ID of the message...
{ "language": "en", "url": "https://stackoverflow.com/questions/439976", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How can I implement an IRC Server with 'owned' nicknames? Recently, I've been reading up on the IRC protocol (RFCs 1459, 2810-2813), and I was thinking of implementing my own server. I'm not necessarily looking into adhering religiously to the IRC protocol (I'm doing this for fun, after all), but one of the things I...
{ "language": "en", "url": "https://stackoverflow.com/questions/439987", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Activator.CreateInstance with private sealed class I'm trying to new up a LocalCommand instance which is a private class of System.Data.SqlClient.SqlCommandSet. I seem to be able to grab the type information just fine: Assembly sysData = Assembly.Load("System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b7...
{ "language": "en", "url": "https://stackoverflow.com/questions/440016", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "12" }
Q: .NET Options Stream Video Files as WebCam Image I am interested in developing an application that will allow me to build a list of videos from xml (containing video title, duration, etc) and play that list as my webcam stream. Meaning, if I were to visit ustream.tv, or activate my webcam on live messenger my video p...
{ "language": "en", "url": "https://stackoverflow.com/questions/440017", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Adding Java packages to GWT I've tried searching but couldn't come up with a defined way on how to add your own packages to a GWT project. My tree structure looks like this: -com.mycompany -public MyApplication.html MyApplication.gwt.xml -com.mycompany.client MyApp.java -com.mycompany.gui TableLayout....
{ "language": "en", "url": "https://stackoverflow.com/questions/440018", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "10" }
Q: Visual Studio (with Team Foundation Server) - How to get back to "Resolve" screen? I started resolving conflicts in a merge and then had to quit to set something up. Now I don't see any way to get back to the stupid conflict resolution window. If I try to merge again it just gives me a bunch of warnings about the pe...
{ "language": "en", "url": "https://stackoverflow.com/questions/440027", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Re-creating threading and concurrency knowledge in increasingly popular languages I am primarily a Java developer, and I've been reading a lot of in-depth work on threads and concurrency. Many very smart people (Doug Lea, Brian Goetz, etc) have authored books on these topics and made contributions to new concurrenc...
{ "language": "en", "url": "https://stackoverflow.com/questions/440036", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: Is there a native excel class which allows a range to be copied and sorts/filters applied? I have a range I'd like to arbitrarily sort and filter using vba. I don't, however, want it to affect the worksheet. I'd like to essentially copy the range into some native class that supports filtering and sorting (so i don't...
{ "language": "en", "url": "https://stackoverflow.com/questions/440037", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Is it possible to reuse a .NET WinForms Form object? Once a window has been closed, it is possible, and it is recommended, to reuse that window's Form instance to show the same window again? Or is it required or recommended to always create a brand new instance of the class when you will be showing a window. What t...
{ "language": "en", "url": "https://stackoverflow.com/questions/440051", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: Convert 12-hour date/time to 24-hour date/time I have a tab delimited file where each record has a timestamp field in 12-hour format: mm/dd/yyyy hh:mm:ss [AM|PM]. I need to quickly convert these fields to 24-hour time: mm/dd/yyyy HH:mm:ss. What would be the best way to do this? I'm running on a Windows platform,...
{ "language": "en", "url": "https://stackoverflow.com/questions/440061", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "11" }
Q: make a parent function return - super return? there is a check I need to perform after each subsequent step in a function, so I wanted to define that step as a function within a function. >>> def gs(a,b): ... def ry(): ... if a==b: ... return a ... ... ry() ... ... a += 1 ... ry() ... ... b*=2 .....
{ "language": "en", "url": "https://stackoverflow.com/questions/440063", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Is there any unobtrusive way to hook into jQuery methods for triggers? I was wondering if there was any unobtrusive way to hook into methods such as attr, data, css, etc and call custom triggers? Ideally, I could do something like this: $(".friend a").bind("attr.changed", changed /* data */, function(e) { alert(...
{ "language": "en", "url": "https://stackoverflow.com/questions/440068", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Database Access Libraries for C++ Background: I have an application written in native C++ which uses the wxWidgets toolkit's wxODBC database access library which is being removed from all future versions of wxWidgets . I need to replace this with another database access method that supports the assumptions and contr...
{ "language": "en", "url": "https://stackoverflow.com/questions/440069", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "8" }
Q: When debugging an ASP.NET MVC app, how can I get my changes to Site.css to show up? I'm debugging on my development machine and when I make changes to the css file, they don't show up and I can't figure out why. I'm using firebug and inspecting the css and the changes are not there. I've tried clear private data an...
{ "language": "en", "url": "https://stackoverflow.com/questions/440074", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }