text
stringlengths
8
267k
meta
dict
Q: Java: Rectangle2D and negative dimensions I have a script in which the user clicks once to begin a Rectangle2D. When he moves the mouse, the rectangle is updated with the new coordinates. He clicks again to end it. It's then stored in an ArrayList, and all these items are painted. This all works fine; it's not the p...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540343", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Limit number of rows of listview I am developing an application that needs to pair with other devices through Bluetooth. I was having trouble in order to show the list of paired devices in correct manner. I had also viewed the example in the android api (Bluetooth Chat), but i was having the same problem. The list o...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540350", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Find word with maximum number of occurrences What is the most optimal way (algorithm) to search for the word that has the maximum number of occurrences in a document? A: * *Scan the document once, keeping a count of how many times you have seen every unique word (perhaps using a hashtable or a tree to do this). *...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540351", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How to use AdWhirl with an unsupported ad company? Does anyone know how AdWhirl works? I set up my custom event for Greystripe in which I initialize the SDK if it wasn't already initialized, and refresh the BannerView, but I don't see the custom event getting called. So my main question is, how and when does AdWhirl...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540355", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: 3NF Normal form I have a question about 3NF normal form: Normalize, with respect to 3NF, the relational scheme E(A, B, C, D, E, F) by assuming that (A, B, C) is the unique candidate key and that the following additional functional dependencies hold: A,B -> D C,D -> E E -> F My understanding is that...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540357", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: ashx error http handler 2 I'm getting the an error at "byte[] param = [...]" from the following http handler. Other ashx files are working. Tell me if you need more info... Request is not available in this context Description: An unhandled exception occurred during the execution of the current web request. Please r...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540363", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: buildbot force build ignoring repository When I click on the 'builders' link of builbot URL and force a build, the git repository I specify on the form is getting ignored; the builder is using the repository it was originally built/configured with. Is this a known problem ? Is there some way to force the builder to ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540368", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: subplot titles in R I'm new in R. I have created 9x3 subplots using par(mfrow= c(3,3)) command using a simple loop and plotted scatter plot for pair-wise dependent variable. Now I want to have sub titles through (a-c) for 1st row; (d-f) for 2nd row & (g-i) for the last. Using "sub" command I could get (a-c) for 1st ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540375", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Inspect helper clone I use the Google Chrome developer tools. When I want to inspect an element, I usually right click it and select "inspect element". This doesn't work for draggable helper clones. My code is as follows: $myElement.draggable({helper: 'clone'}); How can I inspect the helper clone that is only creat...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540379", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "12" }
Q: Jquery append a div area Hi I want to add a new line in a table every time a button is clicked in my code, The code below works but I am expecting it inside the DIV tag called 'selector' as an addition to my table but instead it appears at the top of the page, What am i doing wrong please ? thanks <script t...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540380", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Regex for multiple email address replacements OK so here is my situation. I have a site that is run by WordPress. I need to ensure email obfuscation and as such have installed a plugin called 'Graceful Email Obfuscation'. This works great already. The catch is that I want a catchall in case someone does not follow t...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540384", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: MySQL search problem to find lowercase and uppercase letters at the sametime I have a table where users enters there username in both lower case(eg: arup) and uppercase(eg: Arup) or both (eg: aRuP). But my problem is now that if I search database to show member username like %Arup, mysql returns empty result if not ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540385", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Android, Saving and loading a bitmap in cache from different activities I have i bitmap that needs to show in a new activity, so i cahe it and in the opened activity i try to load it but i get a nullPointerException. Here i save the image : File cacheDir = getBaseContext().getCacheDir(); File f = new File(cacheDir,...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540386", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "11" }
Q: how to get info using ast parser i want to get info from every class of a .java file so that i can save in a structure (maybe a list) the methods that every method of every class calls. Can anyone help me? thanx! A: ANTLR can generate a lexer/parser that will give you an AST. It has Java grammars ready to go, too....
{ "language": "en", "url": "https://stackoverflow.com/questions/7540388", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to get image with ajax request? There is some .php file, that returns .png image file. How to get this image with jQuery $.ajax() ? Also, is there were some mistakes with input parameters, .php file will return error in JSON way. How to understand, which infomation was returned - image or JSON with error? UPDATE...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540389", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: How can I fetch the HTML contents of one single TYPO3 page into another CMS? We need to display the content of one single TYPO3 page in Habari. It would suffice to retrieve the HTML, as styling (CSS) is done separatly. However, we only want the HTML of the content elements - not the whole, fully rendered page. * ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540390", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: PHP/PEAR SearchReplace - String is "varyingText" - How to replace "varyingText" with "newVaryingText"? I have a simple application based on the php pear class SearchReplace: // Define result of Activate click if (isset($_POST['action']) and $_POST['action'] == 'Activate') { include "$docRoot/includes/pear...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540392", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to change fill color of a cell in MS Excel 2010? i need to change color of a cell in excel 2010 by function. a person who has low score be "Red" for example. A: Here are the steps to use conditional formatting (using Excel 2007/2010): * *Select the cells you want to apply the formatting to *Click on Conditi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540394", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Convert NaN to 0 in JavaScript Is there a way to convert NaN values to 0 without an if statement? Example: if (isNaN(a)) a = 0; It is very annoying to check my variables every time. A: You can do this: a = a || 0 ...which will convert a from any "falsey" value to 0. The "falsey" values are: * *false *null *u...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540397", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "316" }
Q: Can binarysearch be used for checking primality? I wonder if binary search can be used to check whether a number is prime , Since the real question is can I find a number which is divisble other than the number itself and 1, and therefore I can imagine looking through an array of ordered integers from 2 to i/2 (i be...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540406", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: jQuery: Get tag inside element with class <div id="yes"> <div class="wrapper"> <something>...</else> <p>foobar</p> </div> </div> I want to get the p-tag to append a classname $("div.wrapper", "#yes").addClass("newClassName"); But where to add the "p"? A: Try $("div#yes > div.wrapper > p").addClass("n...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540409", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: How to disable thunderbird shortcut i use both thunderbird and zend. ctrl+shift+r is used by them. but when i use it in zend and other places, i found that it is a global shortcut of thunderbird. does any one know how to disable the shortcuts or it's just a bug for me only? A: You can install keyconfig and deactiva...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540419", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How do you refactor two classes with the same, duplicated events? Both of these classes contain another private class that raises events. These two classes then re-raise these events to clients. Unfortunately, each of the two classes has this exact same code: public class FirstClass { public delegate void FooEve...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540422", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Add line break after some (ex. 8) words I was searching for a script to put a line break after a number of words. I found this here in stackoverflow: Applying a style to and inserting a line break after the first word in a link So, i change it a little: var el = $('.wtt'); //where wtt is the class of the elements ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540425", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: SAX2 (Xerces-C): How to get the line number of parsed tags? I parse an XML file in C++ using the SAX2 api of Xerces-C. So I do implement the DefaultHandler interface and its functions void startElement( const XMLCh* const uri, const XMLCh* const localname, const XMLCh* const qname, con...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540428", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to cache result/data sets in EF 4.1? I have a view in MVC3 application that calls a stored procedure (that takes a while to execute) to populate a grid on a view and would like to cache that data somehow? Not familiar with EF cacheing but I would actually like to somehow run the query possibly on a background t...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540430", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Best Practice: using jQuery within an iframe CASE 1: once when using fancybox, i was not able to get the following code to work within an iframe.(yes i tried all the flavours related to the following code. see here [i have also replied to this thread] ) parent.$.fancybox.close(); Finally I solved this problem by ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540432", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: IDisposable with member from missing external assembly fails in finalizer I have 2 assemblies, A containing the Main method and the Foo class, that uses Bar the class from assembly B: Bar assembly (assembly B): public sealed class Bar : IDisposable { /* ... */ public void Dispose() { /* ... */ } } Foo cla...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540433", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Detecting change in the value of python variables Is there some way to call a function each-time the value of a variable changes, in python? Something like a listener, perhaps? Specifically, I'm referring to the case where only the variable is shared between scripts like a GAE-Session. (Which uses Cookies, Memcac...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540443", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: In what "event" should i put the -account-ID-session code? I am currently building a new site, where my customers get their own subdomain. for example: user1.mydomain.com user2.mydomain.com userDef.mydomain.com ... The site is built in and running on: IIS, asp.net C# So. Because there is a lot of virtual host subdo...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540445", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Need help to make the first option blank in php retrieving column in mySQL? I have a good php script that works. But I need to modify it so the first select option is blank. Can anyone help? <?php // connect to MySQL $query = "SELECT <col> FROM <table>"; $result = mysql_query($query); ?> <select name="sel" id="se...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540446", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: how to see what menu item was clicked from Android.Gallery if I have two menu items When you want to send an image to facebook from your device, you open the Android.Gallery and select image and press share. I see Facebook have two Menu items in the Share-List: - facebook - facebook for HTC Sence (in my phone HTC...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540448", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Which unique id to use for blogs and comments? This is a question that arose from the consequences of another question here: Is it better to have two separate user tables or one? Assuming I have two types of users, an Author and a Reader, each stored in relational tables keyed to a main Accounts table like so: TABLE...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540449", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Elements in java ArrayList taking up two places I have made a LinkedList to store State objects which is a class I have created. I can add states to the list as expected, but whenever I try the size() method on the list it always returns twice the amount of elements I have added. Why is it doing this and how can I t...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540454", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: UNIX named PIPE end of file I'm trying to use a unix named pipe to output statistics of a running service. I intend to provide a similar interface as /proc where one can see live stats by catting a file. I'm using a code similar to this in my python code: while True: f = open('/tmp/readstatshere', 'w') f.write('...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540460", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How dump assembler from executable I have an executable I compiled with C# and I would like to dump the code in assembler code from it, are there any tools to do that? Also is it possible to also create an executable from the assembler generated? A: C# doesn't compile down to assembler level, it compiles into a com...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540462", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: html form to edit php code I'm working on a project that allows users to edit PHP code in PHP file. I have a PHP page that uses the mail function to send emails. I want to allow the user to change the message sent out (in the mail function). I know how to re-write over a file but how to edit it, I'm not sure... So h...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540466", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Clojure simple sort function error I'm new in clojure, i try create functions thats will be sort collections and store it in object. My code: (defn uniq [ilist] ([] []) (def sorted (sort ilist))) I try to run it: (uniq '(1,2,3,6,1,2,3)) but get error: #<CompilerException java.lang.IllegalArgumentException: Ke...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540471", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to write - If Visible selector? Not sure how to write this; If .sub1 is visible, .homepage fadeTo .25 Sub1 has a FadeIn and I want the homepage opacity to drop to .25 if the sub1 is open? I have this; $("#cat").click(function(){ if ($('.sub1').is(':visible') ) { $(".homepage").fadeTo(500, .25);} else { $("...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540474", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to save this code into a variable? Is there any way to save this block of code into a PHP variable ? The reason of doing this is because I want to send it through mail() echo 'MONDAY<BR>'; query_posts('meta_key=Date1&meta_value=MONDAY'); while (have_posts()): the_post(); if (in_category( '11' )) { ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540476", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: symfony 1.4/ doctrine 1.2 active record relationship tables code organize Let´s say I have a schema containing 3 tables: Users,Pages and Followers. An user can follow many pages. The followers table would contain the page_id and user_id. I need to create a method to return all the users following a page.. Should i c...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540479", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to continue developement of live Django Webapp? I am building a Django powered web app that has a large database component. I am wondering, how would I go about continuing to develop the web app while users are using the live, production version? There are two parts to the problem, as I see it, as follows: * ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540480", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Streaming a remote file i'm new to fmod, and I'm trying to use it for a simple application. I just need to open a remote music file (mostly mp3, and if that can help I can transcode on the server to always have mp3). When I try to FMOD_System_CreateSound(system, "http://somewhere.com/song.mp3", FMOD_SOFTWARE | FMOD...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540482", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: reloadData call second function When i call a reload data then second times pass same directGestire function. How to correct update tableView? -(void)directGesture:(UISwipeGestureRecognizer *)gesture{ if (gesture.state == UIGestureRecognizerStateEnded) { NSLog(@"Get gesture"); [self.tableView b...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540486", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Javascript Regex: Match text NOT part of a HTML tag I would really want to have a Regex that is executable in node.js (so no jQuery DOM Handling etc., because the tags can have a different nesting) that matches all the text that is NOT a HTML tag or part of it into seperate groups. E.g. I'd like to match "5","ELT.",...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540489", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: log4j for logging a Web Application which is in production I am using log4j for logging Our Application which will be into production in three weeks. Our Application will be deployed into remote location server We want to take help of lo4j if an user reports error while using the Application . Regarding this I hav...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540492", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: linear layout orientation changes What i want is : * *In portrait mode : an imageView and a text below *In landscape mode : an imageView on the left and a text to the right How can i do that ? knowing that in my manifest there is a : android:configChanges="orientation|keyboardHidden" in this activity. A: You...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540493", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to set THTTPRio.Converter.Options to soLiteralParams in OnBeforeExecuteEvent This refer to the post Delphi SOAP Envelope and WCF. Could someone please post a sample code which can show me how to set soLiteralParams in THTTPRio.Converter.Options in Delphi 7. I have the following code currently. I have drag-droppe...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540495", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: If security is not an issue, is an immutable interface a good pattern? It is commonly suggested that immutable classes should be sealed, to enforce a promise to consumers that observed properties of the class will remain invariant. Certainly that would seem a good practice for classes that would be employed in secu...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540496", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: No output when running C++ applications via Eclipse CDT IDE Eclipse can build my applications for me so far, and I can execute them directly (via Windows 7 Explorer), but I get no results when I use the run command via the CDT perspective. The console tab only tells me that the application terminated, even with a co...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540500", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: ArrayAdapter custom view state gets repeated when scrolling I have a ListView that gets populated with custom view items. The custom view consists of an icon, a label and a checkbox. When I first create the list, everything displays as it should. If I scroll down the list, the icons and labels continue to be correct...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540504", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Restrict number of requests from an IP I am writing an application wherein its a requirements to restrict the number of logins a user can have from a single IP address (as a way to stop spam). We can't use captcha for some reason! The only 2 ways I could think of to make this work was to either store in the database...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540505", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: FF Xpather to Nokogiri -- Can I just copy and paste? I was doing this manually and then I got stuck and I can't figure out why it's not working. I downloaded xpather and it is giving me: /html/body/center/table/tbody/tr[3]/td/table as the path to the item I want. I have manually confirmed that this is correct but wh...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540506", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Using Microsoft Office software as part of my web service backend? What licensing issues arise if I install and use Microsoft Office software (in this case Visio) as part of my web service backend? My company's flagship piece of software can convert Microsoft Visio files for use in their environment, but of course r...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540508", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: efficient line from hough transform coordinates i'm working with a hough transform (polar coordinates). i'd like to compute a vector representation of a line from a coordinate from the hough transform. my current implementation loops through all the pixel coordinates in the image from (0,0) to (M, N) where M and N a...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540511", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to get systemtimestamp in Cassandra How will i get systemtimestamp from cassandra-cli like select sysdate from dual; in oracle. i am using cassandra in windows7. A: I'm not sure this makes sense for Cassandra. Each Cassandra node has its own system clock - these are distributed and independent so there is no in...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540513", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: JQuery scrollTop() not doing anything My .scrollTop() is just not working. It's used in a function (which do get called - checked with an alert) but nothing happens. I tried: $(window).scrollTop(); $("html").scrollTop(); $(document).scrollTop(); I tried them separately and together, and it just doesn't do anything....
{ "language": "en", "url": "https://stackoverflow.com/questions/7540515", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Exchange symetric keys between server and client in a secure way I have an algorithm that I believe to be secure. So the server creates a public and private key combination for every new connection. In this example I am just dealing with one thread but in reality I will have to construct several threads so that the ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540519", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: QtCreator 2.3--Lost ability to see QString contents in debugger So I recently upgraded to QtCreator 2.3 (and want to keep it for its QtQuick support) and initially debugger performance slowed to an unusable crawl (though I could still see QString contents). Googling around led me to install gdb 7.3.1, the latest st...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540523", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Pollard-Rho Factorization Parallelization I recently stumbled upon a paper on a parallelization of Pollard's Rho algorithm, and given my specific application, in addition to the fact that I haven't attained the required level of math, I'm wondering if this particular parallelization method helps my specific case. I'...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540529", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: how to pass filename via intent, to be used in that activity's view i've a list of filename in a listactivity. when the user clicks on a filename that image should be loaded. i pass the filename via an intent, that bit works ok. the recieving activity can get the filename. this activity has a custom view and this i...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540530", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Drag-drop text over DIV I have a div in my website, and when it's clicked upon, it reveals the search box (done with jQuery). However, I would like this div to accept drag'n'dropped text. In my use case, a user selects regular text from anywhere on the site, and drag'n'drops it to copy-paste it into the search box....
{ "language": "en", "url": "https://stackoverflow.com/questions/7540531", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: Best way to save a Parent object Just wondering what's the best-practice for saving a Parent that ordinarily contains a collection of Child objects (many-to-many in my case), but that collection in the Parent is currently set to null because it hasn't been loaded? In my case, the Parent is passed to my service layer...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540539", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: SqlDependency.Start An attempt to attach an auto-named database for file failed iv'e got copy of NORTHWND.mdf along with NORTHWND.LOG in my App_Data folder MY CONNECTION STRING : <add name="northwind_connection" connectionString="Data Source=.\SQLEXPRESS;AttachDbFileName=|DataDirectory|NORTHWND.mdf;Integrated ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540544", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Merging 2 Binary Search Trees How do you merge 2 Binary Search Trees in such a way that the resultant tree contains all the elements of both the trees and also maintains the BST property. I saw the solution provided in How to merge two BST's efficiently? However that solution involves converting into a Double Linked...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540546", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "21" }
Q: Implementing fa unction that adds and sorts data in a singly linked list (addsort)? I'm very new to C++ so it's a bit hard to understand the syntax sometimes. Anyways, I'm supposed to implement a function that adds and sorts the data given into a linked list. For example if I pass 2 into the list [1,4,5] then I shou...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540554", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Classic ASP Session/IIS Reset Bug in IIS 7? I have an application in classic asp running on IIS 7. The website uses global ASA (Application_OnStart and Session_OnEnd, the others are not being used) The problem is this. When one user logs in/out, sometimes the entire site does some sort of IIS reset and all the vis...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540556", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Hierarchy in array (php) -> how to get parent? I have a hierarchy in array and i'd like to know how can i "move" from children to parent. Is there a better way to work with php and hierarchy? I'd like to avoid using recursive steps for each child i need to check a parent. Is there a class or something similar? As e...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540558", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-2" }
Q: iLO3: Multiple SSH commands is there a way to run multiple commands in HPs integrated Lights-Out 3 system via SSH? I can login to iLO and run a command line by line, but I need to create a small shell-script, to connect to iLO and to run some commands one by one. This is the line I use, to get information about the ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540566", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: UISwitch customization? Is possible to add images to an UISwitch background,like when the state is ON (be one background) and when the state is OFF (another background image)? A: To change the background color (not image) all you have to do is below. This changes the off color for all UISwitch controls in realm. ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540569", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Sphinx delta index ignoring main index I have a really strange problem where for some reason my indexes simply do not function as they should. I have built a fully working delta index in Sphinx with full cron jobs to keep it all in shape and everything is fine. Then I come to query in PHP with: class sphinx_searcher...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540571", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: Is there a way to do "git log -n 100 -from 200"? Is there a way to do like paginated retrieval of commit history like git log -n 100 -from 200? It would fetch 100 commits after the first 200th commit. Is there such a feature? A: You can do that with: git log -n 100 --skip=200 The documentation for these options ca...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540572", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: comparing two vector images I want to compare two vector images (say SVG) and see how close they are. Basically, I want to test the correctness of a tracing algorithm which converts raster images to vector format. The way I am thinking to test this algorithm is: -Take some vector images. -Rasterize the vector image ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540575", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "17" }
Q: PhoneGap -- or something else? For iOS app utilizing Swipes and Pinches My iOS app needs to utilize "swipes" gestures and "pinches". I'd rather not develop native iOS app myself, but use some tool like PhoneGap or anything like that. I want this to be pretty much a Web app, as much as possible, so I don'd deal with ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540576", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: cluetip plug-in on jQuery loaded nods This is the scenario: The user clicks on e.g. a button, that loads (using jQuery) a node, e.g. '<span id="selected" title="|click to reselect">selected: #' + id + '</span>' Then goes jQuery (for cluetip) code: $('#selected').cluetip({splitTitle: '|', showTitle: false}); Clueti...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540577", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Process.Start will not launch chrome I'm having trouble getting Process.Start to launch chrome. If chrome is set as the default browser - nothing is opened. I also have tried providing two argument ex: Process.Start("chrome",url) Process.Start("PathToChrome",url) Process.Start("chrome.exe",url) None of ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540585", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: I am working with arrays and need to sort the array. This array keeps showing out of range exceptions I have established an array and a large textbox which displays the array. Basically, you enter a name, 4 quarterly sales figures and it calculates the yearly total. I am now starting on the sort button. This woul...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540590", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-3" }
Q: How can I create a new DataGridView control for each new row in another datagridview in vb.net? I have a DataGridView control (DataGridView6) that displays a list of managers. I want to generate a new DataGridView everytime I add a new manager to the list and put it in a specific place on my form. EDIT: say if i ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540596", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Difference between lazy loading in NHibernate and Entity Framework While playing around with the Entity Framework and NHibernate using POCO entities, I made the following observation which I find a bit unusual: I have two POCO entities, an 'Order' and a 'Product'. There is a many-to-many relationship between the two...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540599", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: POSIX regex in C is not working I want to match every thing in between two words GET and HTTP. I tried every thing I know. But it is not working. Any help appreciated. The pattern GET.*HTTP should match GET www.google.com HTTP. Here is the code Headers: #include <sys/types.h> #include <regex.h> #include <stdio.h> #i...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540600", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Rails how to validate file format? How do I validate my file fields for the correct format? I want the image field to validate that it is a .png, .jpg, .jpeg. And the flv that it has the ending .flv And the quicktime that it have the ending .mov And how do I create error messages to tell that the field is not valid....
{ "language": "en", "url": "https://stackoverflow.com/questions/7540601", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Problem in show value jQuery toolti I created a tooltip and i have problem with it, i want: When that mouseenter on hi show value into next div it value hi When that mouseenter on hello show value into next div it value hello But in following code, when that mouseenter on each tow hi & hello showing value hello, H...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540602", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Memory leak in IE8? http://jsfiddle.net/mplungjan/SyHFR/ Sorry for the messy code - I have modified a script not chosen by me and originally from Dynamic Drive - it is used by someone I am helping and rather that rewriting the whole thing from scratch, I agreed to the feature creep. The intended changes was to add a...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540604", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: How to make a b2body move at a constant speed with box2d I am making a box2d game and have enemies fly in from the left side of the screen to the right side of the screen. If I apply a force in the tick method like shown below, the enemies increasingly move faster over time. I want the enemies to move at a constant ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540608", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Button and Edittext styles differ between real phone (Galaxy S2) and emulator On the AVD, my buttons and edittexts look very nice with rounded corners and shaded backgrounds. Also in the gui editor of Eclipse, they look nice as it should be. But when I then install the app on my SGS2, the buttons and edittexts are b...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540612", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Reading dataset value into a gnuplot variable (start of X series) I originally thought this may be the same as gnuplot - start of X series - Stack Overflow - but I think this is slightly more specific. Since I'm interested in finding the "start of X series", so to speak - I'll try to clarify with an example; say yo...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540614", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "10" }
Q: jQuery Table Sorting by Attr e.g. Title Does anyone know of a jQuery plugin that allows table sorting when clicking on the header, but checks say the title of a cell and sorts by that before looking at the contents of the cell? I have some data in my cells such as 3h 5m and 5m, most sorting plugins get these in the ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540619", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How to detect mouse click on menuItem when added via addMouseListener Consider you want to close your java application using "Close application" menu item. 3 possible solutions are (using ActionListener or MouseAdapter or MouseListener): menuItemClose.addActionListener(new ActionListener() { @Override publi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540626", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: jQuery listener click not working So I have this code that should listen for a click on #button but it won't work, and is driving me crazy! <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js"></script> <script type="text/javascript"> $('#button').click(function() ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540632", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: same method, multiple return types. code organization Let´s say I a have an User class and I want to return all the users in my database. For that i have create a method called getAll(); I need to call the method in different parts of my application and return the data in different formats. I might need all users se...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540635", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: obtain radio interface layer on mobile website not application I was using IP2location dlls to get the user's location but i realised that it doesn't work on mobile websites. I read about getting the users location through the cell ID information and i was wondering if this can be used through mobile website on a s...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540636", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: List files and sub directories Android What i want to do is to open a directory through android application and list all the files as well as directories present in that directory. I would also like to retrieve permissions and owner information of each file/directory. This can be achieved in java but how can i do th...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540641", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How to add in TextView new data(1 textView = 1 name), from Data Base? in a cycle I have tableLayout with 3 textView in a TableRow. How to add in TextView new data(1 textView = 1 name), from Data Base? thats doesnt work: my cursor say: select * from TABLE_NAME Cursor cursor = database.query(TABLE_NAME, new S...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540644", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Generate random bytes Cocoa? I need to generate some random data to append to my file for encryption. How would I go about doing this? Would it be sort of the same idea as generating a string of random characters? Something like: NSData *randomData = @"what should i put here?"; And then use the rand() function to...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540651", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Shift focus from one JTree node to another I need to shift focus from a JTree node to another node on the previous node being clicked. Example XML document: <br/> <'obo'><br/> <'term'><br/> <'id'>GO:0001<'/id'><br/> <'name'>candida... '<'/name'><br/> <'dbname'>' blah blah '<'/dbname'><br/> <'is_a'>'GO:0035'<'/is_a'>...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540655", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: textarea as list Im trying to make 2 side by side text areas, with 2 buttons between them, one that adds an item from a selected line in the left textarea to the textarea on the right, the other to remove a selected item from the list on the right. Basically, a 'line selected' function is where Im failing. Any ideas...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540663", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: Is the "Signals and Slots" concept reactive programming? As written in the title - is "Signals and Slots" a simple way of reactive programming? A: Signals/Slots is an implementation of the Observer Pattern . From the wiki on Reactive Programming: Reactive programming has principal similarities with the Observer pa...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540665", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Google's website translator and content loaded via AJAX I am using Google's website translator on a website I am developing. In one section of the website I use AJAX to load new content into the page. I was hoping that there was a way to tell the Google translator to re-translate the loaded content (I could provide ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540667", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Help with list output I have this expression here $data = file_get_contents('groups.txt'); function links1($l1, $l2){echo "<a href='". $l1 ."'><img src='". $l2 ."'/></a>";} $parsed1 = get_string_between($data, "[Group1]", "[/Group1]"); $data = explode("\n", $parsed1); foreach($data as $string2){ list($l1, $l2)...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540672", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Best practice to define multi-dimensional arrays in wsdl I'm developing a WebService with a function which returns a database result, which means an MxN array. My question is, what's the better way to define this in wsdl: * *Define a row as sequence of (string) columns, define the resultset as sequence of rows, p...
{ "language": "en", "url": "https://stackoverflow.com/questions/7540673", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }