text
stringlengths
8
267k
meta
dict
Q: Extended slice that goes to beginning of sequence with negative stride Bear with me while I explain my question. Skip down to the bold heading if you already understand extended slice list indexing. In python, you can index lists using slice notation. Here's an example: >>> A = list(range(10)) >>> A[0:5] [0, 1, 2, ...
{ "language": "en", "url": "https://stackoverflow.com/questions/399067", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "16" }
Q: WCF service instantiation via IoC container Can the WCF runtime be made to instantiate a service via an IoC container rather than via its usual process? (Also, given a potential clash between the container's lifestyle configuration for the type and the service's InstanceContextBehavior, would this approach be a terr...
{ "language": "en", "url": "https://stackoverflow.com/questions/399072", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "12" }
Q: What special characters must be escaped in regular expressions? I am tired of always trying to guess, if I should escape special characters like '()[]{}|' etc. when using many implementations of regexps. It is different with, for example, Python, sed, grep, awk, Perl, rename, Apache, find and so on. Is there any rul...
{ "language": "en", "url": "https://stackoverflow.com/questions/399078", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "457" }
Q: Call mysql SOURCE command from a C program I want to execute some mysql statements that are stored in a text file from my C program using the mysql.h library. My inclination was to do something like the following, but this doesn't work: mysql_query(conn, "source test.mysql"); This is because the SOURCE command is n...
{ "language": "en", "url": "https://stackoverflow.com/questions/399085", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: WPF HierarchicalDataTemplate doesn't update ItemsSource on property changed Here is some XAML <HierarchicalDataTemplate DataType="{x:Type data:FolderEntity}" ItemsSource="{Binding Path=FolderEntities,UpdateSourceTrigger=PropertyChanged}"> <Label Content="{Binding FolderName}"/> </HierarchicalDataTemplate> <Tree...
{ "language": "en", "url": "https://stackoverflow.com/questions/399101", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Why are c/c++ floating point types so oddly named? C++ offers three floating point types: float, double, and long double. I infrequently use floating-point in my code, but when I do, I'm always caught out by warnings on innocuous lines like float PiForSquares = 4.0; The problem is that the literal 4.0 is a double, ...
{ "language": "en", "url": "https://stackoverflow.com/questions/399114", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "17" }
Q: Product Installation and Configuration on a Windows Machine I am working on a .NET 3.5 project which consists of a web application and a Windows service. Both need to be deployed on the server machine. I have created an msi package using Wix 3 which installs the application files, creates shortcuts and registers the...
{ "language": "en", "url": "https://stackoverflow.com/questions/399118", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Failing to send email with the Python example I've been trying (and failing) to figure out how to send email via Python. Trying the example from here: http://docs.python.org/library/smtplib.html#smtplib.SMTP but added the line server = smtplib.SMTP_SSL('smtp.gmail.com', 465) after I got a bounceback about not having...
{ "language": "en", "url": "https://stackoverflow.com/questions/399129", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "22" }
Q: Should I rename my button event handler name? When using Visual Studio (though ideally this can apply to the generic case) and double click on a button I've created, the event handler code that is auto generated uses the following signature: Protected Sub btnSubmitRequest_Click(ByVal sender As Object, ByVal e As Eve...
{ "language": "en", "url": "https://stackoverflow.com/questions/399135", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Easiest way to alternate row colors in PHP/HTML? Here's a PHP example of mine. Can anyone find a shorter/easier way to do this? <? foreach($posts as $post){?> <div class="<?=($c++%2==1)?‘odd’:NULL?>"> <?=$post?> </div> <? }?> <style> .odd{background-color:red;} </style> Examples in other langua...
{ "language": "en", "url": "https://stackoverflow.com/questions/399137", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "26" }
Q: How do you export from Expression Design to Silverlight XAML and retain vector relativity? I am trying to export some prepared assets out of Expression Design 2 and into .XAML, with a final destination of Blend 2 for layout, but I cannot find a reliable way to keep the ability to resize those assets when they reach ...
{ "language": "en", "url": "https://stackoverflow.com/questions/399151", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: HTTP status 403: Forbidden exception using certificate to authenticate ASP.NET web service I posted days ago about access control to web service (Access control to web service). In short, I have an ASP.NET web service deployed on //service/webservice and I want my ASP.NET web application (app1) on the //web1 to acce...
{ "language": "en", "url": "https://stackoverflow.com/questions/399155", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Extracting data from an email message (or several thousand emails) [Exchange based] My marketing department, bless them, has decided to make a sweepstakes where people enter over a webpage. That is great but the information isn't stored to a DB of any sort but is sent to an exchange mail box as an email. Great. My...
{ "language": "en", "url": "https://stackoverflow.com/questions/399165", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: How can I obtain the dimensions of a Flash video file from PHP code? I have an application where users can upload video files of any size, and I'd like to be able to determine the the height/width of a Flash video file (flv or f4v) from a PHP script so that I can size the player appropriately. I'd love a pure PHP s...
{ "language": "en", "url": "https://stackoverflow.com/questions/399180", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: HTMl Helpers in MVC: How do I render html tags with helper such as ActionLink? When using ActionLink to render data from database which has HTML tags (ie <p>) incorporated in it, ActionLink escapes the tags. What is the best way to handle this? A: I don't know that you can turn off the XSS protection in the hel...
{ "language": "en", "url": "https://stackoverflow.com/questions/399190", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Calculating the semantic distance between words Does anyone know of a good way to calculate the "semantic distance" between two words? Immediately an algorithm that counts the steps between words in a thesaurus springs to mind. OK, looks like a similar question has already been answered: Is there an algorithm that ...
{ "language": "en", "url": "https://stackoverflow.com/questions/399200", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: How do I call a constructor on a generic type within a function of a base type without its own constructor? I thought a great way to test my understanding of generic functions would be to create a function that would spit out a hex representation of a hash using one of the classes that inherits from HashAlgorithm. S...
{ "language": "en", "url": "https://stackoverflow.com/questions/399202", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Distinct elements and grouping Given the following xml fragment: <Problems> <Problem> <File>file1</File> <Description>desc1</Description> </Problem> <Problem> <File>file1</File> <Description>desc2</Description> </Problem> <Problem> <File>file2</File> <Description>desc1</Description>...
{ "language": "en", "url": "https://stackoverflow.com/questions/399204", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "8" }
Q: Auto complete by end/middle of line in bash In bash is there a quick way to do tab auto-completion based on the middle of a word. So for example, if I have these files in a directory: 001_apple.txt 002_pear.txt 003_dog.txt I would like to type the sequence: *d<TAB> to auto-complete 003_dog.txt. Can this be done...
{ "language": "en", "url": "https://stackoverflow.com/questions/399209", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "8" }
Q: VS JavaScript intellisense with paramaters here is some sample javascript: SomeObjectType = function() { } SomeObjectType.prototype = { field1: null, field2: null } SomeOtherObject = function() { } SomeOtherObject.prototype = { doSomething: function(val) { /// <param name="val" type="SomeObjec...
{ "language": "en", "url": "https://stackoverflow.com/questions/399214", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: I still don't get Delegates Isn't the use of delegates to help with some asynchronous cases? I tried the following but my UI still hangs. When on earth do you use delegates? Public Class Form1 Private Delegate Sub testDelegate() Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As _ S...
{ "language": "en", "url": "https://stackoverflow.com/questions/399222", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How to get a positive mental attitude towards testing? I want to write tests for my app, though each time I look at rspec.info, I really don't see a definite path to take towards "doing things right" and testing first. I watched the peepcode videos on rspec more than once, yet it doesn't take. I want to take more ...
{ "language": "en", "url": "https://stackoverflow.com/questions/399224", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "10" }
Q: What do you think of an AWS based architecture I was reading through this article: http://aws.typepad.com/aws/2008/12/running-everything-on-aws-soocialcom.html And I was wondering if this was good or bad. I am a fan of AWS myself, but I what to hear what the crowd thinks... A: There is everything perfect in the El...
{ "language": "en", "url": "https://stackoverflow.com/questions/399244", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Embedding arbitrary metadata in audio and video files I work for an organization where we take raw MPEG-2 video files of lectures from academic institutions and make them available on our website in a variety of formats. Right now the workflow for turning the MPEG-2 into audio (MP3) and video (MP4), uploading to iTu...
{ "language": "en", "url": "https://stackoverflow.com/questions/399245", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Going where PHP parse_url() doesn't - Parsing only the domain PHP's parse_url() has a host field, which includes the full host. I'm looking for the most reliable (and least costly) way to only return the domain and TLD. Given the examples: * *http://www.google.com/foo, parse_url() returns www.google.com for host...
{ "language": "en", "url": "https://stackoverflow.com/questions/399250", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "12" }
Q: OS X: sending mail to localhost For testing purposes I want send mail to my localhost user account rather than my webserver. I am unsure how to do this using mail.app. Any help would be appreciated. A: If you don't specifically want to use Mail.app, you can send mail using the mail command. Open Terminal and: mail...
{ "language": "en", "url": "https://stackoverflow.com/questions/399252", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Finding the currently logged in user from a Firefox extension I'm writing a Firefox extension that needs to know what the username of the currently logged in user is in Windows, Mac, or Linux. So if I'm logged into my machine as "brh", it'll return "brh". Any idea how to do that from extension JavaScript? A: Firefo...
{ "language": "en", "url": "https://stackoverflow.com/questions/399263", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Why doesn't a Dictionary access nonexistent keys like a Hashtable does? If I'm using a Hashtable, I can write code like this: object item = hashtable[key] ?? default_value; That works whether or not key appears in the Hashtable. I can't do that with a Dictionary<TKey. TValue>. If the key's not present in the dicti...
{ "language": "en", "url": "https://stackoverflow.com/questions/399270", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: favicon.ico in Java WAR file Can anybody provide some instruction on how to setup a war file to show a favicon.ico in the browser address bar? A: This might be different in different application servers. For tomcat, the favicon comes from the directory your root context is mapped to. So if your application is mappe...
{ "language": "en", "url": "https://stackoverflow.com/questions/399286", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "21" }
Q: Is it possible to get the raw param string in rails? Given the following url: http://foo.com?bar=1&wee=2 What is the quickest way to get the raw param part of the url from an action? i.e. ?bar=1&wee=2 A: Sure, just use request.query_string from within your controller
{ "language": "en", "url": "https://stackoverflow.com/questions/399290", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: Average EC2 Uptime? Curious as to 99.95% uptime REALLY means; Is it really going to go down 7 minutes a month? Please post your longest/average uptimes on EC2, thanks. A: SLA's are useless. They only measure how much risk the company is willing to take on and have no bearing on actual uptime. I've seen SLA's, wit...
{ "language": "en", "url": "https://stackoverflow.com/questions/399291", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "14" }
Q: The memory could not be "read" error when opening a VB6 form from a .Net application I have an application written in C#.Net (Framework 2.0 if it matters). It calls a VB6 exe that exposes a COM class with one method - that shows a form. When the VB form is closed, I get a system error (Windows message): The memory l...
{ "language": "en", "url": "https://stackoverflow.com/questions/399295", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: WPF Default Credential I am trying to access .net 2.0 Web Service from WPF. I generated the proxy using Visual Studio and also Credential of the proxy to Default Credentials. I am getting 401 Unauthorized while accessing the web service. When I output the user name from the default credential it is empty, Am I miss...
{ "language": "en", "url": "https://stackoverflow.com/questions/399300", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: When to use Helpers instead of Partials In a rails application, in which situation would you use a partial and when would you use a helper? I find both very similar, since they represent markup fragments. Is there a convention around this? which is the 'rails way' of using them? Thanks! A: The other answers represe...
{ "language": "en", "url": "https://stackoverflow.com/questions/399302", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "45" }
Q: Store huge std::map, mostly on disk I've got a C++ program that's likely to generate a HUGE amount of data -- billions of binary records of varying sizes, most probably less than 256 bytes but a few stretching to several K. Most of the records will seldom be looked at by the program after they're created, but some w...
{ "language": "en", "url": "https://stackoverflow.com/questions/399304", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "11" }
Q: ArrayList and the problem with adding items I please for your help. I apologize for my English, it is still learning. I do one application in GUI in Java. I have one problem. In this application I have an ArrayList that I want to meet with data. User clicks on the button and data from JTextfield shall be placed in ...
{ "language": "en", "url": "https://stackoverflow.com/questions/399311", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: What is Hindley-Milner? I encountered this term Hindley-Milner, and I'm not sure if grasp what it means. I've read the following posts: * *Steve Yegge - Dynamic Languages Strike Back *Steve Yegge - The Pinocchio Problem *Daniel Spiewak - What is Hindley-Milner? (and why is it cool?) But there is no single entry ...
{ "language": "en", "url": "https://stackoverflow.com/questions/399312", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "144" }
Q: Detect if Flash application loaded correctly using Javascript? My product opens a web browser and points it at an HTML file containing a local Flash application. How do I detect programmatically whether this file loaded successfully and if not what exception was thrown? Is there a way to do this using Javascript? Ch...
{ "language": "en", "url": "https://stackoverflow.com/questions/399314", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "8" }
Q: Confused about C#/Silverlight workflow I'm working on some charting controls for my ASP.NET web app. I am aware of visifire and the Silverlight charts MS now provides. My requirement came before I knew about these and their releases and I'm intending to write charts that are as good as Dundas or ChartFX (or is it So...
{ "language": "en", "url": "https://stackoverflow.com/questions/399324", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Tix and Python 3.0 Has anyone seen anything in Tix work under python 3.0? I've tried to work through the examples but when creating anything it states that cnf is unsubscriptable. I also noticed that none of the Dir Select stuff (DirList DirTree) works under 2.6.1. Why doesn't Python either dump Tix or support it? ...
{ "language": "en", "url": "https://stackoverflow.com/questions/399326", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Fastest way to retrieve a in PHP I'm doing a bookmarking system and looking for the fastest (easiest) way to retrieve a page's title with PHP. It would be nice to have something like $title = page_title($url) A: I'm also doing a bookmarking system and found that since PHP 5 you can use stream_get_line to load the...
{ "language": "en", "url": "https://stackoverflow.com/questions/399332", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "31" }
Q: Cross platform open source Doc to RTF converter I need a doc to rtf converter that will run from the command line, and from within a Perl script (I know I'll need to use system() to run the converter). Any recommendations. Something that can be compiled statically linked so it can run on workstations as standalone...
{ "language": "en", "url": "https://stackoverflow.com/questions/399339", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: on checkboxes: is there a reason why more websites don't use it? I always try to do the following: <label><input type="checkbox" /> Some text</label> or <label for="idOfField"><input type="checkbox" id="idOfField" /> Some text</label> My question is related to the label tag, specifically on a checkbox. Most websi...
{ "language": "en", "url": "https://stackoverflow.com/questions/399340", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "11" }
Q: MTU for WebServices We have an ERP application which has all clients connect using WebService. My network engineer tells me that the MTU of the webservice is too small and we would like to increase it to improve performance. As far as I can tell there is no config section for MTU for dotnet web services. Any idea...
{ "language": "en", "url": "https://stackoverflow.com/questions/399347", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Joomla problem: where does "$mainframe->getCfg('lang')" come from? In Joomla: $mainframe->getCfg('lang'); will return "english" (i think this is a default value), anyone can tell me where defined it? Can I change it? A: It's what you configure in the Language Manager. A: jlleblanc,thanks for your help. i think i...
{ "language": "en", "url": "https://stackoverflow.com/questions/399348", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Change iPhone App Status Bar Properties My app will be full screen, but I am having trouble finding the document that explains how to change the status bar properties. How can I change the status bar properties? A: [[UIApplication sharedApplication] setStatusBarHidden:YES animated:NO] should hide the status bar. Is...
{ "language": "en", "url": "https://stackoverflow.com/questions/399352", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "11" }
Q: Shortest code to spawn a modal dialog box from a thread Say I have a thread that keeps running in the background to figure if a URL is accessible. If the URL is not accessible, the application need to show a modal dialog box. Things cannot go on if the URL is down. If I simply do a MessageBox.show from inside the th...
{ "language": "en", "url": "https://stackoverflow.com/questions/399353", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Splitting a string on AT&T IA-32 Linux Assembler (gas) .section .data astring: .asciz "11010101" format: .asciz "%d\n" .section .text .globl _start _start: xorl %ecx, %ecx movb astring(%ecx,1), %al movzbl %al, %eax pushl %eax pushl $format call printf addl $8, %esp movl $1, %eax movl $0, %ebx int $0x80 Supp...
{ "language": "en", "url": "https://stackoverflow.com/questions/399356", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: possibility of jQuery document ready() function taking a very long time to execute My issue is that sometimes a piece of JavaScript (often Google Analytics) may take a very long time to load, although it's not important to the HTML be ready to be "traversed and manipulated". If I were to use the following code: $(do...
{ "language": "en", "url": "https://stackoverflow.com/questions/399359", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Long-lived connections (asynchronous server push) with Apache/PHP/Javascript? I come from more of a Java background. In the last year or two, it's become somewhat popular to do server push over HTTP using long-lived HTTP connections in Comet. It's an extremely useful technique. So I'm curious what the equivalent i...
{ "language": "en", "url": "https://stackoverflow.com/questions/399366", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: How to make an embedded video not autoplay I'm embedding a Flash video into an HTML and would like the user to have to click it to begin playing. According to the Adobe <object> / <embed> element documentation, there are variety of methods to do this: 1) Add a Flash parameter inside the <object> tag: <param name="pl...
{ "language": "en", "url": "https://stackoverflow.com/questions/399370", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "17" }
Q: Update without first selecting data in LINQ 2 SQL? How can you go about updating a record without having to select the data first in LINQ? As you must first perform a linq select (obviously calls a SQL SELECT which is costly), change required properties, then perform SubmitChanges(). I wish to avoid this and just p...
{ "language": "en", "url": "https://stackoverflow.com/questions/399379", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Development tactics : phoenix development cycles I was wondering how you guys actually develop large applications when you are your own boss. For myself I have been learning the hard way the necessity for patience and hope. I have been working on implementing an application (in the form of a series of scripts linked...
{ "language": "en", "url": "https://stackoverflow.com/questions/399380", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: What's your favorite web view for Subversion (SVN) repositories? I have just built up my first SVN server, along with the mod_dav_svn module for Apache so that I have a rudimentary web view into the repository. There appear to be lots of alternate/additional packages to make the web view more full-featured, along th...
{ "language": "en", "url": "https://stackoverflow.com/questions/399387", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "11" }
Q: Can you get DB username, pw, database name in Rails? I'm writing a rake task that does some DB work outside of Rails/ActiveRecord. Is there a way to get the DB connection info (host, username, password, DB name) for the current environment as defined in database.yml? I'd like to get it so I can use it to connect lik...
{ "language": "en", "url": "https://stackoverflow.com/questions/399396", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "162" }
Q: Hibernate and currency precision I have a hibernate mapping as follows: <hibernate-mapping> <class name="kochman.elie.data.types.InvoiceTVO" table="INVOICE"> <id name="id" column="ID"> <generator class="increment"/> </id> <property name="date" column="INVOICE_DATE"/> ...
{ "language": "en", "url": "https://stackoverflow.com/questions/399401", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Does Microsoft Access have Full Text Search? Does Microsoft Access have Full Text Search? I know that MySQL and SQL Server have Full Text Search, but I am not too certain on Access. If Access doesn't have Full Text, what is the best alternative to achieve the same objective of Full Text Search? Thanks A: I'm not 10...
{ "language": "en", "url": "https://stackoverflow.com/questions/399406", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "13" }
Q: free secure distributed make system for linux Are there any good language-agnostic distributed make systems for linux that are secure and free? Background Information: I run scientific experiments (computer-science ones) that sometimes have large dependency trees, occasionally on the order of thousands or tens of th...
{ "language": "en", "url": "https://stackoverflow.com/questions/399409", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "8" }
Q: MySQL Cluster with MySQL innoDB persistent store We are working on a database solution for a high available (5 9s) application with high performance and data consistency needs. We are planning to use MySQL Cluster as the primary in-memory datastore backed up by a secondary innoDB MySQL datastore for persistent stora...
{ "language": "en", "url": "https://stackoverflow.com/questions/399415", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: I found SwfDotNet to help me create swf flash files with C#, but I found SwfDotNet to help me create swf flash files with C#, but I need some documentation or some examples on how to use this better. http://sourceforge.net/projects/swfdotnet/ I'd like to be able to take multiple images and create a slide show, and h...
{ "language": "en", "url": "https://stackoverflow.com/questions/399423", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to implement a singleton model I have a site in rails and want to have site-wide settings. One part of my app can notify the admin by SMS if a specific event happens. This is an example of a feature that I want configurable via the site-wide settings. So I was thinking I should have a Setting model or something....
{ "language": "en", "url": "https://stackoverflow.com/questions/399447", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "36" }
Q: Forward declare method pointer I am using the pimpl idiom and want to reference one of the methods of the forward declared class. Below isn't exactly what I'm doing but uses the same concepts. template< typename Class, void (Class::*Method)(void) > struct Call { Call( Class* c ) : m_c(c) { } void oper...
{ "language": "en", "url": "https://stackoverflow.com/questions/399452", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How can I improve Visual Studio performance on a slow hard drive? I currently have a laptop with a 5400rpm drive. It has visual studio installed and whilst it's just ok for working on, I've read plenty of places that you can get a pretty nice performance boost from VS just by increasing the drive speed. I don't hav...
{ "language": "en", "url": "https://stackoverflow.com/questions/399458", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: NHibernate Mapping intermediary table Hi I'm looking for some help in mapping the following tables to a hibernate mapping file: schema image http://barry-jones.com/temp/sch2.jpg I'm trying to fill the localCalandarGroups List with related localCalendarGroups when loading my userVOs. I'm using a intermediary table(us...
{ "language": "en", "url": "https://stackoverflow.com/questions/399459", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Google Map Overlay Icon disappears at certain zoom level I notice that Firefox 3 demonstrates this problem. I put down an overlay icon and play around with the map zoom. At certain zoom level, I found that the icon disappears for some unknown reason. Zooming out brings back the icon. Or during the disappearance, I ...
{ "language": "en", "url": "https://stackoverflow.com/questions/399460", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Providing a content management solution I am developing a small site (non-profit) for a charity. The charity chairman would like to add content to the site upon completion, mainly text. However they would not like to type directly into the XHTML. What are the possible options regarding this problem? Thank you in adv...
{ "language": "en", "url": "https://stackoverflow.com/questions/399469", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Can I change the height of a specified window's caption bar? I want to self-draw the caption bar of my application's window, so I decided to override OnNcPaint() methods. But I don't know how to set a different height of the caption bar. Everytime I use GetSystemMetrics(SM_CYCAPTION), it retruns the same value. Can ...
{ "language": "en", "url": "https://stackoverflow.com/questions/399482", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Open the Save Image dialog using jQuery/Javascript? When a user clicks on an image on a web page, I'd like to trigger the browser's Save Image dialog and to let the user save the image on their hard drive. Is there a cross-browser way to do this with jQuery/Javascript? A: The only thing that comes to my mind is the...
{ "language": "en", "url": "https://stackoverflow.com/questions/399486", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "11" }
Q: How to stop renaming of excelsheets after running the save macro Below is a macro to save multiple sheets to different csv files BUT it keeps renaming and saving the original workbook, how to stop this. Private Sub CommandButton1_Click() Dim WS As Excel.Worksheet Dim SaveToDirectory As String Dim CurrentWorkbook A...
{ "language": "en", "url": "https://stackoverflow.com/questions/399488", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: rails model attributes without corresponding column in db I have some rails models which don't need any persistence, however I'd like rails to think the model actually has attributes x, y, z so when calling methods like to_json in the controller I get them included for free. For example, class ModelWithoutTableColum...
{ "language": "en", "url": "https://stackoverflow.com/questions/399490", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: The most elegant way to import flatfiles into SQL server 2005 without using SSIS For some reasons, SSIS is not avalialble. I read about OPENROWSET, but I will have others problem from on the format file and path of file. How can I do it in a elegant way? A: Not knowing your whole situation, here's what I would reco...
{ "language": "en", "url": "https://stackoverflow.com/questions/399498", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: DHTML: Get updated element size I'm updating the src attribute of an <img> tag in javascript. After I've done this, I need to get the new height of its parent <div> so that I can update the size of other elements on the page. If I retrieve the parent's offsetHeight property directly after updating the image's src,...
{ "language": "en", "url": "https://stackoverflow.com/questions/399508", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Synchronization of sql server 2000 and postgresql 8.3 the scenario: Two databases(each has a database named, for example testdb): * *MS Sql Server 2000 *Postgresql 8.3 I need to synchronize these two testdbs, actually the direction is from SqlServer to Postgresql. The structure of testdb on SqlServer may chan...
{ "language": "en", "url": "https://stackoverflow.com/questions/399509", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Making JavaFX compile to Java 1.6 level source code How do I make JavaFX with netbeans compile my code to 1.6 level compliance. At the moment it seems to be hard coded to 1.5 levels - stopping me from using useful tools in java.awt.Desktop (and the like) A: Remember - because JavaFX must run on the Apple Java run-t...
{ "language": "en", "url": "https://stackoverflow.com/questions/399510", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Type of object rendered(CUPS) I am making a copy of my RIP for CUPS(pstoraster.I wanted to know the type of the object rendered using ghostscript. Does anyone have this idea A: Here is the documentation for the output of pstoraster, which is merely a script that calls ghostscript: http://www.cups.org/documentation....
{ "language": "en", "url": "https://stackoverflow.com/questions/399526", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Parsing unsupported date formats in via Cocoa's NSDate With the Cocoa framework how can I parse @"2008-12-29T00:27:42-08:00" into an NSDate object? The standard -dateWithString: doesn't like it. A: If you only need to handle the ISO 8601 format (of which that string is an example), you might try my ISO 8601 parser ...
{ "language": "en", "url": "https://stackoverflow.com/questions/399527", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "13" }
Q: iPhone Development - Complex application using multiple views/xib/nib I'm new to iPhone development, and multiple views (xib or nib) are really confusing me. This is what i'm trying to achieve... * *View with Tab Bar (Tab 1, Tab 2, Tab 3) *Tab 2 View (Navigation Controller) 2.1 Selecting Table Row will show a Vi...
{ "language": "en", "url": "https://stackoverflow.com/questions/399530", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: How can I grab a double key stroke in .NET How can I grab something like ^MM (CTRL + M + M) in .NET, using C#? A: This is just a guess, you could store the key and key modifiers on each key stroke and then next time through check the last keys pressed for a matching sequence. You could probably implement this in e...
{ "language": "en", "url": "https://stackoverflow.com/questions/399532", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Missing drive when attaching database in SQL Management Studio 2005 I'm trying to attach an external mdf file to my SQLEXPRESS instance from within the SQL Management Studio 2005. However, I'm unable to see the drive that the database file resides in under the directory browser within the "Locate Database Files" pro...
{ "language": "en", "url": "https://stackoverflow.com/questions/399536", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How do I link PDCurses to a C++ application on Windows? I'm building a C++ application and need to use PDCurses on Windows. I'm compiling with VC++ from MS VS 2005 and I'm getting a link error. error LNK2019: unresolved external symbol __imp__GetKeyState@4 referenced in function __get_key_count There are 11 er...
{ "language": "en", "url": "https://stackoverflow.com/questions/399538", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Synthetic Class in Java What is a synthetic class in Java? Why should it be used? How can I use it? A: According to this discussion, though the language specification describes an "isSynthetic" proprty for classes, this is pretty much ignored by implementations and not used for either dynamic proxies or anonymous c...
{ "language": "en", "url": "https://stackoverflow.com/questions/399546", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "152" }
Q: avoid javax.servlet.ServletException I am getting a javax.servlet.servletException while executing the following code.... "<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%> "<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%> "<%@ taglib uri="http://jakarta.apache.org/tiles" prefix="tiles"%> tiles:im...
{ "language": "en", "url": "https://stackoverflow.com/questions/399551", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: PostgreSQL performance issue I can see in the postgresql logs that certain simple queries (no joins and using only match conditions that use indexes) take anywhere from 1 to 3 seconds to execute. I log queries that take longer than a second to execute thus there are similar queries which execute under a second which...
{ "language": "en", "url": "https://stackoverflow.com/questions/399559", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: How do I compare overlapping values within a row? I seem to have a problem with this SQL query: SELECT * FROM appts WHERE timeStart >='$timeStart' AND timeEnd <='$timeEnd' AND dayappt='$boatdate' The time is formatted as military time. The logistics is that a boat rental can be reserved at 7am til 1pm or 9am til...
{ "language": "en", "url": "https://stackoverflow.com/questions/399567", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: linq2sql missing event model? How come the "Table" classes Generated in the Dbml do not contain useful events like OnBeforeInsert OnBeforeUpdate OnAfterInsert etc. Am I missing something? This question is related to frustration trying to set timestamp columns. UPDATE I created the following method of doing this ne...
{ "language": "en", "url": "https://stackoverflow.com/questions/399569", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How do you attach to events on a ScriptObject in Silverlight? The HtmlObject provides all the necessary functionality to register managed event handlers for script and DOM events, but what if the class you need to listen to doesn't exist as a DOM element, but a scripting variable (referenced via ScriptObject) instea...
{ "language": "en", "url": "https://stackoverflow.com/questions/399572", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Grails renders JSP as blank page I have a Grails application with a JSP page (I'm porting a legacy JSP application). For some reason, the page renders completely blank. Looking at the HTTP headers I see it's 200 with a content length of 0. HTTP/1.1 200 OK Content-Language: en-US Content-Type: text/html; charset=iso-...
{ "language": "en", "url": "https://stackoverflow.com/questions/399582", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Organizing using directives I've been using ReSharper for the past months and, advertising aside, I can't see myself coding without it. Since I love living on the bleeding "What the hell just went wrong" edge, I decided to try my luck w/ the latest ReSharper 4.5 nightly builds. It's all nice. However, I've noticed t...
{ "language": "en", "url": "https://stackoverflow.com/questions/399594", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Flex: Is there any way to find find out when a ComboBox is open? I may be missing something here because I thought this might be really easy but... Using Flex, how can you tell when a ComboBox is open? I do find the open and close events that this component dispatches can be flaky so I'm looking for something a lit...
{ "language": "en", "url": "https://stackoverflow.com/questions/399595", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Hardware requirements for development machines Given that: * *SSD’s are now [high end] mainstream *Two+ cores are not hard to come across *24+ Inch monitors are plentiful *Dual Video Outputs are the norm. *64-Bit OS’s complement very cheap memory Can I ask two questions to hardware enthused developers [not ...
{ "language": "en", "url": "https://stackoverflow.com/questions/399605", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: Mercurial: No editor appears when merge conflicts are detected I wonder if anyone here has any experience with mercurial running on Ubuntu? I've been playing with it all morning and love everything I've seen so far. The one problem I though is when I do a merge and conflicts are detected, it doesn't automatically br...
{ "language": "en", "url": "https://stackoverflow.com/questions/399606", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How to Capture / Post system-wide Keyboard / Mouse events under Mac OS X? For a scripting utility I need to be able to record a series of keyboard and mouse events that occur when an application has focus. The second part is being able to later send those events to the active window. I do not need to worry about men...
{ "language": "en", "url": "https://stackoverflow.com/questions/399616", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: What is fuzzy logic? I'm working with a couple of AI algorithms at school and I find people use the words Fuzzy Logic to explain any situation that they can solve with a couple of cases. When I go back to the books I just read about how instead of a state going from On to Off it's a diagonal line and something can b...
{ "language": "en", "url": "https://stackoverflow.com/questions/399618", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "43" }
Q: Is there an equivalent of Perl's URI.pm for C# / .NET? .NET has the Uri class. Perl has its URI module. The major difference is that URI.pm allows you to retrieve the query string components as a hash, and set a hash into the URI to construct a nice URI with query arguments. I don't see anything like that on the .NE...
{ "language": "en", "url": "https://stackoverflow.com/questions/399633", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: AJAX Page Download progress I want to get the progress of my AJAX request - how much has been downloaded so far out of how much the file is. For example, I am downloading a large picture with AJAX so I can put the content in a DATA url (this may not be the best way to do that, it's just a example.) So, I make the A...
{ "language": "en", "url": "https://stackoverflow.com/questions/399641", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "27" }
Q: Preventing same Event handler assignment multiple times If I am assigning an event handler at runtime and it is in a spot that can be called multiple times, what is the recommended practice to prevent multiple assignments of the same handler to the same event. object.Event += MyFunction Adding this in a spot that w...
{ "language": "en", "url": "https://stackoverflow.com/questions/399648", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "48" }
Q: Are there any rules for OOP? Recently I heard that there are 9 rules for OOP(Java). I know only four as Abstraction, Polymorphism, Inheritance and Encapsulation. Are there any more rules for OOP? A: Not sure about any rules. All these mentioned things are more like OO paradigms to me. There are few advices we follo...
{ "language": "en", "url": "https://stackoverflow.com/questions/399656", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "20" }
Q: iPhone Development - Creating a class like UIImagePickerController that returns data to parent I have a situation where I have to take input from the user using multiple views (like Personal Information -> Professional Information -> Process Completed). I was wondering, how can I build a class like UIImagePickerCont...
{ "language": "en", "url": "https://stackoverflow.com/questions/399661", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Merge trunk to branch in Subversion I'm using Subversion 1.4.6, and I cannot upgrade to version 1.5 right now. The situation: * *The trunk has a lot of structural changes (i.e. moving files around, mostly). *I have a branch that was recently merged from the trunk, but before the major changes. What is the best w...
{ "language": "en", "url": "https://stackoverflow.com/questions/399669", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "81" }
Q: How can I read Authorization header from a REST based WCF service? How can I read Authorization header information from a REST based WCF service? A: You are trying to read the http header. OperationContext.Current.OutgoingMessageProperties or OperationContext.Current.IncomingMessageProperties A: Actually since yo...
{ "language": "en", "url": "https://stackoverflow.com/questions/399674", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "8" }