text
stringlengths
8
267k
meta
dict
Q: Show two projects in one UML diagram I have an enum that has two dependencies. These two are in different projects (Im coding in Java). I want to show this dependency ina UML diagram but how can I show what projects these classes are from? (I know for packages you can put it like this: Package :: pkgName). Any ideas...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520791", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: JSON time service "json-time.appspot.com" is broken. Anyone have a replacement? http://json-time.appspot.com/time.json?tz=GMT has been broken for a while now... at least a month. This service returns the current time in jsonp, and I have a jquery plugin that uses it to determine the correct time. I'm under the assum...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520793", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: clearTimeout only works at end of loop I am having problems with the clearTimeout JavaScript Function. I would like the homeAnimation()function to stop looping as soon as the mouse hovers over one of the infoboxes (just working over one box would be a start) I have stripped out the code I think is unneccessary. Any ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520794", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: How to combine a local editor with a remote compiler? I am used to the local IDE interface which integrates the code editor and compiler. However, I want to test if the code compiles well with the remote compiler on Unix server. I am tired of copying my source file to the server, and working in the command window (S...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520797", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Are values stored in NSUserDefaults removed when the app that put them there is uninstalled? If I put a token (a string) into NSUserDefaults, lets say as a paramter passed to a REST API that is used by the app, and the app is uninstalled, will the string remain on the device? A: No. You can see that the data saved...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520800", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "16" }
Q: How can i use php to export a mysql table I am trying to export just the rows of a mysql table without the table information to an xml file. I read that the mysqldump command will get the job done but I cant manage to get the correct syntax. Can someone post an example code for mysqldump command? Thank you. $command...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520801", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Routing issue while using high_voltage for static pages I am trying to use high_voltage to serve up static pages. It seems to be working in that if I put .../pages/PAGE_NAME in the browser window it will bring up the correct page. The problem that I am having is that the default root doesn't appear to be working p...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520813", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: javascript scroll to bottom of div if current scroll location is near bottom I am working on a script that will append text (varies on size) to a div block (varies in height) with overflow scroll. After this text is appended I need the div block to be scrolled to the bottom in order to see the new appended text, ho...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520815", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Backslashes disapearing after my vb.net query to Mysql I'm having some problems, when I do my query from my vb.net program to my mysql DB the data is sent, but its missing some things, let me explain. My query is pretty simple I'm sending a file path to my DB so that after I can have a php website get the data and m...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520819", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Problem with calling jquery ajax in asp.net i am having a strange problem, while calling ajax jquery in asp.net.. i am getting the parseError, and this is not expected, because everything is in place. below is my webmethod. public class MyLogic { private int _id; public int Id { get { return _id...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520825", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Magento: How to enable/disable module output per website level? I would like to display an image in the onepage checkout payment methods section that would only show up in one of two website levels. So I have three questions: 1) Am I correct to assume this change would be coded in app/design/frontend/default/mytheme...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520826", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Preprocess SCSS with HAML I have an app that has some categories: Tomato, Orange, Banana. Each category has it's own color saved in the database: FF0000, FF6600, FFFF00. There're also some posts in the app that belong to a category. I want HAML and/or SASS to generate classes from the category names/color, like: .to...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520830", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Android GLSurfaceView as subview I'm very new to an Android platform and currently trying figure out why things work this way: If I create GLSurfaceView and add it using the setContentView or addContentView to an activity everything works fine (Renderer.onDrawFrame is called as expected). However if I add my GLSurfa...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520832", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Magento - how to declare multiple helper classes in the same config Could someone please tell me how I can declare multiple helpers within the same config file for the same module? I've been using helper utility files for awhile now, but as my utility method is becoming increasingly long, with many functions, I'd li...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520838", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Make spreadsheet save in human-readable format for version control Apparently Gnumeric's native file format is compressed xml. Diffing binary files isn't easy, so you lose many of the advantages of version control. Is it possible to get it to save (and load) its files in straight xml (or any other human readable for...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520843", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Is this a good structure for my jQuery scripts? I want to keep my scripts organized in one .js file for all my site (I have a mess right now), something like namespaces and classes in C#... (function ($) { //private variables $.divref = $("#divReference"); //Namespaces window.MySite = {}; wind...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520844", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: Event Handling with Timer to Poll Hardware I need to request values using functions in a DLL provided by the manufacturer of my particular piece of hardware (a weather station). I'm new to C#, and the concepts of delegates/events are tough to wrap my head around. Nonetheless, I've managed to pull the functions fro...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520847", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Getting the current price of a stock symbol I would like to write a java program or method that simple gets the current price of a given stock symbol. I have scoured through the Google and Yahoo finance APIs and do not think these have what I am looking for. Does anyone know how I can accomplish this or a good pla...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520849", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Is there a way to query for action instances? In the beta of the open graph, I see how you can access action instances if you know their IDs: http://developers.facebook.com/docs/beta/opengraph/actions/ How do you find the action instances in the first place? I don't see any new collections in the graph api that asso...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520862", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: socket connection in j2me using GPRS I am trying to open a socket connection in j2m2 on Nokia C5 device using my Airtel GPRS connection. I am using following lines of code. SocketConnection connection=(SocketConnection)Connector.open("socket://www.cse.iitd.ernet.in:80"); It stucks here and never proceeds, no error ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520864", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: popViewController works on one view, not another I have a couple of UIViewControllers and related nib files. I can call either of them from another UIView controller ("StartController") by pressing a button for each one. Each of the called UIViewControllers had a button which I've connected up to a related method wh...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520869", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Can WinRT application use obfuscation? All Metro applications must be inspected before distribution through Windows 8 AppStore. Does this mean it will not be allowed to use code obfuscation? Or it is still possible, and only some specific aspects are going to be monitored during such inspection? A: This is an armch...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520871", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Emulator vs Phone which one to rely on? I am almost done with my app..when i run it on the emulator ,at certain points, it is very slow and what i see is undesirable..when I run the same on my phone (xperia X8) it works fine. I really tried understanding why this is happening but of no avail! What should I do now? ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520872", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Quirky Google Chrome Beta/Dev channel behavior persists even after uninstalling and reverting to stable We have several FogBugz customers who have reported an error in Chrome where if the user presses Enter in an edit box, the edit box will lose focus and they'll have to click back in to the box for it to gain focus...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520873", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Is it bad practice to depend on the .NET automated garbage collector? It's possible to create lots of memory-intensive objects and then abandon references to them. For example, I might want to download and operate on some data from a database, and I will do 100 separate download and processing iterations. I could de...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520881", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: 'ascii' codec can't decode byte (problem when using django) I wrote a simple html parsing class in python and it seems to work fine and then I try to use it with django and I get this error: 'ascii' codec can't decode byte 0xc2 in position 54465: ordinal not in range(128) which is strange because I added this: # en...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520882", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: C++ simple threading question I'm writing a simple producer/consumer program to better understand c++ and multithreading. In my thread that ran the consumer i had these first two lines: pthread_cond_wait(&storageCond, &storageMutex); pthread_mutex_lock(&storageMutex); But the program got stuck, probably a d...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520883", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Importing a subversion repository I'm having problems: I create a new repository in Subclipse that points to a URL. When I check out the code and it creates a Flex Builder project, I am getting errors that relate to issues with the .actionscriptProperties and .flexProperties files. So, I was told to just create a n...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520886", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to generate QR codes using library in .Net I am planning to explore on QR code generation . I saw the google api http://chart.apis.google.com/chart?cht=qr&chs=75x75&chl=test and its pretty impressive. But it works only for URL's and small data's. So i am thinking about writing a .net app to generate the QR code....
{ "language": "en", "url": "https://stackoverflow.com/questions/7520897", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Detect anytouch inside subView (other than a button) touchesEnded I have a subview, which also contains a UIButton. Now, once I enter the touchesEnded, I want to execute some instructions only if the main subview was touched (and not the UIButton). Is there a way to do this?? Thanks in advance. ezbz A: Use write y...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520901", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: JNI and UnsatisfiedLinkError I'm doing my first steps with JNI and tried to write a simple Hello Java program, but it fails with this error: Exception in thread "main" java.lang.UnsatisfiedLinkError: HelloJava.dostuff()V at HelloJava.dostuff(Native Method) at HelloJava.main(HelloJava.java:12) This i...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520904", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Ajax post works in chrome but no data recieved on server with ie and firefox I need to retrieve and process a image (png) generated by a flash application. When a user clicks a link I : var dataImgBase64 = document.getElementById("flashApp").getThumbnail(); So the flash app sends me a image in base64. Then I: var p...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520910", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to find the code that creates a memory address in Xcode? I am trying to find the source code that causes some leaks reported in Instruments, but all I get is the Address. Is there a way to take this Address, or use some other feature in Instruments, to then locate where the offending object is located in the act...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520911", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: CakePHP Extending Controllers and Overriding Methods I'm working on an Application, and most of the code will be returning in future project. So my idea was to create a structure such as this: App/ - controllers - models - ... Cake/ My_Custom_Folder/ - controllers - models - .. Basically I want to add another fold...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520913", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: localized routes solution I built a french/english app and I would like to use the same controller/view for both language but to have a different route that is map to the current language. Let say I have website.com/Account/Register that return to my Account controller and Register action, I would love to have a rou...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520917", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Get realtime updates from database into ajax based asp.net web page from sql server database.. like facebook I am trying to solve a problem. I have a asp.net repeater that shows a User friends that are obtain from sql server database with their statuses. Some of the friends could be online and some of them could be...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520918", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Class CSS property return How would one return a class computed CSS property/property array? Like, if I have a class defined in CSS: .global { background-color: red; color: white; text-shadow: 0px 1px 1px black; } It's applied on the go with javascript to an element. Now I want to change this elements c...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520921", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Configurable Resource - Design patterns First of all bit of background. We are developing an application which receives messages from n number of sources. The source may be a messaging queue, an FTP location, a webservice call to a particular service or any possible orchestration layer we can think of. I have been ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520922", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Y-axis labels for Bluff Javascript library So, I'm using the fabulous Bluff library to put up some graphs from a Rails app. I wanted to customize the Y-axis labels to display fewer decimal digits of precision. Anybody got a clue how to do that? I could try to analyze the "compressed" version of the library and hack ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520923", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How can I detect when any file changes under a directory in AIR? I've seen examples that use a timer, get the file list, and check each file for changes, but is there a simpler way to do this such as... <mx:FileSystemList id="fs" visible="false" /> private function onCreationComplete():void { fs.directory = Fil...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520925", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Where can I find the SimpleITK documentation and reference information? I am interested in trying to use SimpleITK to solve my imaging problem. Can you please tell me where the documentation and training materials are? A: SimpleITK is documented here, and has a tutorial that has been presented at the MICCAI 2011 c...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520934", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: CSS Images in Email With Rails 3 I'm trying to send out an email with Rails 3 and Action Mailer. The email goes out fine, but I want it to be HTML formatted with some basic styling which includes background images. I understand that the images might get blocked until the user allows them to be shown, but I still thi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520936", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: View Form Creation Code in Access VBA? Is it possible to view the form creation code in Access VBA? I don't mean the event listener code that is viewable in the VBE from View>Code in the form's Design View. I mean the code that is used to create the components, and add them to the form. I would like to programatical...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520943", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: textBox embedded in a ListBox initial focus I want to set the focus to the first ListBox item that is a textbox. I want to be able to write in it immedatelly without the necesity to click it or press any key. I try this but doesn't work: private void Window_Loaded(object sender, RoutedEventArgs e) { ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520945", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Strange behavior with doctrine_record::free() method on a loop Hie all, I loop in Doctrine_Query::execute() with many relations and i get a record on each iteration. No problem. To save memory, i would like free() record memory usage with Doctrine_Record::free(). The first iteration, no problem but at the next ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520950", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Strip a section out of a url in PHP I have the following URL that is being returned to me from the Vzaar upload api: https://vz1.s3.amazonaws.com/vzaar/vz8/2b5/source/vz82b51a36989c422abc4db1734208933a/test.mp4vz1vzaar/vz8/2b5/source/vz82b51a36989c422abc4db1734208933a/test.mp4"c9f4852682649c4a1c034af092b2938f" I ne...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520951", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to clear textfields after a ajax query using jquery? im using this jquery function to do a ajax query: $("#add").click(function() { val1 = $('#add_lang_level').val(); val = $('#add_lang').val(); listitem_html = '<li>'; listitem_html += '<span id="lang_val">' + val + '</span> <strong>('+ val1 + '/...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520954", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: LINQ 'join' expects an equals but I would like to use 'contains' This is a small scrabble side project I was tinkering with and wanted to get some input on what I may be doing wrong. I have a "dictionary" of letters and their respective scores and a list of words. My ideas was to find the letters that were in each ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520955", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "19" }
Q: The correct place to set the UINavigationController's back button title I'm a bit confused with setting the title of navigation item's back button. Usual this is done in the viewDidLoad but in my case the view controller is created without the view being loaded. On startup, I'm restoring the view controller hierarch...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520960", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: C#- Getting user input for Age.. but receiving error? I am trying to make improve my programming and getting things drilled into my head so I'm just quickly developing an application that gets user's input and prints their name. But also gets their input for "Age verification". I'm practicing IF & ELSE statements a...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520966", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: View current opened netNamedPipe channels? Is there any way I can determine which netNamedpipe channels are currently open? This will help me debug my WCF Client/Server and make sure I am closing my channels properly. This is similar to the netstat tool for network connections, but for netNamedPipes instead. A: You...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520967", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How can we safely lock down a Facebook development environment tunneled out to the public internet? We run a per developer development environment with each developer workstation ssh tunnelled out from our office to the public internet so we can test integration with Facebook canvas apps and facebook callbacks to ou...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520969", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Applications are expected to have a root view controller at the end of application launch I get the following error in my console: Applications are expected to have a root view controller at the end of application launch Below is my application:didFinishLaunchWithOptions method: - (BOOL)application:(UIApplication ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520971", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "390" }
Q: CSS display issue where border applied to div is stretching around other elements I have an issue where the css border applied to a div element is stretching around the span tag directly above it (a span tag which is NOT within the div tag). Now, I already have a workaround for this which can be found in the follow...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520976", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to get hudson's git plugin to clone repo with the name of the repo in the path? Let's say I have a repo called "stuff". git@github.com:mine/stuff.git when I do a git clone of this repo from the command line, it creates a directory called "stuff" and puts everything in that directory. When I set up hudson to use...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520979", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Making http calls from swing application to a servlet, session not saved I'm creating a Swing application that connects to a web server, running some servlets (created by myself). On the 1st time a user connects, he get a "playerID" that is saved on his session on the servlets. When I try to make another call from t...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520980", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Call NodeJS function by PHP (fsocketopen) I need call and pass parameter to NodeJS socket server. I confirmed the server works well. and now I need to create PHP script to call the function. My NodeJS code is like this, var user = {}; socket.sockets.on("connection", function(client){ client.on("messageToC...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520981", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Best way to implement a workflow based on a series of asynchronous ASIHTTPRequests in iOS? I've been fighting and fighting for some time with a decent way to handle a workflow based on a series of asynchronous ASIHTTPRequests (I am using queues). So far it seems to have eluded me and I always end with a hideous mes...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520986", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: PHP replace HTML elements with DIV I've been reorganising my code to be able to better support old IE browsers. I've put everything that is HTML5 only scripts in IF statements and it all works fine. I just have one last change I need to make. I've collected all my site into an using ob_start() ... and would like to...
{ "language": "en", "url": "https://stackoverflow.com/questions/7520993", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Why do Objective-c protocols adopt other protocols? I've seen Objective-c protocols defined in the following way: @protocol MyProtocol <SomeOtherProtocol> // ... @end Why do protocols adopt other protocols? I'm especially curious why a protocol would adopt the NSObject protocol. A: It is simply the same concept a...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521001", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "12" }
Q: linq insert not work I have this code: protected void Page_Load(object sender, EventArgs e) { if (Page.IsPostBack) { using (mesteriEntities myEntities = new mesteriEntities()) { var usern = Session["New"]; var UserID = (from Users in myEntities.Users ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521006", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: SHA1 hash binary (20) to string (41) I have a function that creates a binary sha1, but I need a result as a 40-byte string, (+1 for null-t). Is there a better way of converting it to string, than this? unsigned char hash_binary[20] = "\xFF\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x01"; char hash_string[41]; int i; for(i...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521007", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Event execution in JavaScript Say, JavaScript is in the middle of executing some method, and I'm pressing a button which has some event handler attached. Will the current method execution get paused and the click event handler start executing right away, or will js finish method execution and only then proceed with ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521009", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: How to Determine Optimal MySQL Table Indexes, When Contents of WHERE Clause Vary? I have the following 2 mysql_queries: Query 1 (this query is repeated twice more for imgClass, and imgGender): $imgFamily_query = "SELECT DISTINCT imgFamily FROM primary_images WHERE '$clause' "; Query 2: $query_pag_data = "SELECT img...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521010", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: PHP shell_exec() issue I am having an issue using the PHP function shell_exec(). I have an application which I can run from the linux command line perfectly fine. The application takes several hours to run, so I am trying to spawn a new instance using shell_exec() to manage better. However, when I run the exact same...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521017", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to auto start a a href="javascript:void window.open( open loading <a href="javascript:void window.open('website', 'pukarock', 'width=1018, height=715, scrollbars=yes, resizable=yes');">click me</a> How do you auto start this in HTML as onload? Other stuff I researched doesn't work. I only want my website to ope...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521018", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-2" }
Q: Ajax calls in Widgets in jQuery Dashboard I am using the jQuery Dashboard plugin to display MySql table information. I have within these widgets buttons for each mysql result to display a form. The button performs an ajax call to pass in the form id and then retrieve the styled form information to be displayed in ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521021", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Compounding switch regexes in Vim I'm working on refactoring a bunch of PHP code for an instructor. The first thing I've decided to do is to update all the SQL files to be written in Drupal SQL coding conventions, i.e., to have all-uppercase keywords. I've written a few regular expressions: :%s/create table/CREATE T...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521025", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: DCH class error with JavaMail I'm attempting to set up a simple logging test with JavaMail in Java EE 6, using the jar files provided with Glassfish 3.1. There seems to be a wealth of questions out there on this subject, but I haven't found any answers that have helped yet. My test code looks like this: import jav...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521027", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "12" }
Q: Make a textbox click a button if you hit enter So I have looked at some previous example online and it seems prettys strait forward <form:input path="searchParameter.instanceName" id="searchBox" onkeydown="if (event.keyCode == 13){ document.getElementById('btnSearch').click() return false }"/> And it works fine...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521037", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Javascript function returning fixed value from array I'm newbie with JavaScript, so I decided to develop a little application which is supposed to show the schedule of the streetcar of the place I live, because of the lack of the information on the official webpage. I have several arrays with the starting time of t...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521039", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Flickr image url suffix medium 500 It says to use a '-' but that doesn't work for me.. Size Suffixes The letter suffixes are as follows: s small square 75x75 t thumbnail, 100 on longest side m small, 240 on longest side - medium, 500 on longest side z medium 640, 640 on longest side b large, 1024 on long...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521040", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Ruby on Rails 3: How to override/change as_json serialization for ActiveSupport::TimeWithZone? When Rails3 serializes ActiveSupport::TimeWithZone to json that dates look something like this: "2011-07-20T23:59:00-07:00" ... it should be ... "2011-07-20T23:59:00-0700" That last colon is problematic when trying to conv...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521041", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: C# Extension method precedence I'm a bit confused about how extension methods work. If I'm reading this correctly http://msdn.microsoft.com/en-us/library/bb383977.aspx and this If an extension method has the same signature as a method in the sealed class, what is the call precedence?. Then the following should wri...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521047", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "13" }
Q: Tracking pixel (transparent GIF) as a background-image in a stylesheet? Anyone know if adding a tracking pixel (just a transparent GIF with some logging going on at the server that's sending out the GIF) as a background-image in a linked stylesheet will work the same as if it was a regular <img> on a page? From a s...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521050", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: sending frames using sockets I've been asked to make a JAVA application for sending frames using sockets, my question is simple, is there anything special with this "frames"? i mean, i know how to transport bytes through net, I have knowledge about sockets, but I really don't know what are this frames , should i ass...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521054", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Colorize grayscale image I have a grayscale image and a some color, represented in RGB triplet. And i need to colorize grayscale image using this triplet. The left image represents what we have and the right what i need to have. Now in program i have some function where in input is R, G and B value of source image ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521058", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to hide everything after a dollar sign in a String JQuery I have a string like this: string="Awesome Option +$399.99"; I want to remove the +$399.99 (and any other pricing details) from the string, how would you do that? Oh and the string could also possibly look like this: string="#4 Cool Option +$23.99" A: v...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521060", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to pass a Bash variable to Python? Eventually I understand this and it works. bash script: #!/bin/bash #$ -V #$ -cwd #$ -o $HOME/sge_jobs_output/$JOB_ID.out -j y #$ -S /bin/bash #$ -l mem_free=4G c=$SGE_TASK_ID cd /home/xxx/scratch/test/ FILENAME=`head -$c testlist|tail -1` python testpython.py $FILENAME pyth...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521061", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "14" }
Q: SQL Azure: SMO Exception when scripting objects in SSMS 2008 R2 I am using SQL Server Management Studio 2008 R2 to manage a SQL Azure database. When I try to right-click on any of the objects in the database, and do Script Table As -> CREATE -> New Query Editor Window, I get the following exception screen every tim...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521069", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Threadpool local variable concepts I am trying to multi thread my application using ThreadPool in c#. I have a 3D array in which I have to process for every row separately. I have spawned out threads equal to number of processors(cores) in the system and then dividing the task between the threads to process on the i...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521072", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: android animation starting new activities or dismissing an Activity Is there a tutorial or a code example of various kinds of View Animations available in Android. Basically what I am trying to do is say if start a new Activity, I am trying to get that activity start out like zoom in till it fills the screen or Fade...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521080", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: jQuery (or textOverflow) taking too long When we detect Firefox, we call jQuery('.trunc').textOverflow(); but if the page is long, Firefox puts up the "unresponsive script" alert. I believe the actual problem is in the initial jQuery call (when it finds all matching DOM elements by their CSS). I'm no jQuery expert ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521085", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: choose the selected value in a item template I have a method called BindItems() and this method gets the values to a DataTable and then a GridView is bound to it. Then I have an itemtemplate in that gridview which contains a drop down, this drop down gets populated from 1 -14 from code behind under Gridview_RowDataB...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521097", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Change label text before file read happens I haven't used java in awhile and I am trying to do something like this in one main class: // do stuff this.label.setText("Status: IDLE"); // do things this.label.setText("Status: LOADING..."); // set to loading right before file read // read and parse huge file this.label....
{ "language": "en", "url": "https://stackoverflow.com/questions/7521098", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: JAR Hell Hacks for Non-OSGi Developers Edit: After reviewing the play, the example I used below is a tad misleading. I am looking for the case where I have two 3rd party jars (not homegrown jars where I have access to the source code) that both depend on different versions of the same jar. Original: So I've recentl...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521100", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: In Team Build, how to checkout and checkin a file that is not on your workspace? I'm customizing my own Team Build workflow, and at some point within the "Run on Agent" sequence, I need to checkout a file that is not in the current workspace, edit and check in again. I started by creating a sequence that does more o...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521116", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Replace a character squence in java using regular expression I have the following text "This ball isn?t yours, this one is John?s" I want to correct this to be "This ball isn't yours, this one is John's" How can I do this in Java using Pattern and Matcher? A: string.replaceall String fixed = old.replaceAll("\\?([...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521118", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Loss of precision with very small numbers in Python arrays I have two arrays in float64 type and when I assign the value of the first to the second it rounds the value. The following simple code illustrates the problem and excludes the possibility of just a mere number representation thing. (I've schematized a fragm...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521120", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Problem Pushing Large File to Emulator/SDcard with Eclipse DDMS I am using Eclipse DDMS to push a file over onto my Android Emulator sdcard. I select the file and press Open, a dialog pops up and starts pushing the file. In the view "File Explorer" in the DDMS perspective I can see the sdcard directory and can see...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521122", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "8" }
Q: Looking for data storage... which to choose I have an application where users can define their own data sets (fields, fields types and such) and then store their data... very similar to them creating and managing their own tables. Doing this seems to present issues when trying to set it up on something like MySQL......
{ "language": "en", "url": "https://stackoverflow.com/questions/7521123", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Trying to encode an image in base64 after resizing In php, I'm trying to encode an image in base64 after a resize. When I encode it directly with no resize it's working fine $bitmapNode = $dom->createElement( "bitmap" ); $bitmapNode->appendChild( $dom->createTextNode(base64_encode(file_get_contents($url))) ); $roo...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521125", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Mysql, data spread over two tables, seperate rows I have data spread over two MySQL tables with different structures. One table has DVDs and the other has CDs. The DVD table is as follow: PUBLISHER STOCK DVD_INFO EXTRA_DVD_INFO The CDs table is as follow: PUBLISHER STOCK CD_INFO How do you get all the CDs and DVDs...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521129", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: rename xib file I started to create an app using tabbar app template provided in xcode. Then I wanted to change the names of the files: FirstViewController should become YellowViewControler and FirstView.xib should become YellowViewcontroller.xib. Changing the name of the xib wasn't done right. It became red as if i...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521132", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: ASP.NET Add column to Gridview I have a gridview that is displaying data from a database using LINQ to SQL. AssetDataContext db = new AssetDataContext(); equipmentGrid.DataSource = db.equipments.OrderBy(n => n.EQCN); I need to add a column at the end of the girdview that will have links to edit/delete/view the row....
{ "language": "en", "url": "https://stackoverflow.com/questions/7521136", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Can a SQL Server 2000 table have no PK, and therefore contain duplicate records? I have an audit table and instead of defining an identity or ticketed column, I'm considering just pushing in the records of the recorded table (via triggers). Can a SQL Server 2000 table have no PK, and therefore contain duplicate reco...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521137", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Java SWT Image background color I have a TableItem and i wish to add an image in it. I use this code : Image image = new Image(Display.getCurrent(), 400, height); image.setBackground(COLOR_RED); item.setImage(5, image); The problem is the background color is never setting in the image. My goal is to get a transpar...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521139", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Assigning database entries to web service entries Here's the scenario: * *I receive a JSON object comprising 140 events. Each event is one of six possible types and includes several details, except for 2 (description and contact name). *I have a MySQL database of the 6 descriptions and contact names. How can ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521142", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: asp.net postbacks won't fire I've made a simple ASP.net website and everything works fine on my computer. But on my colleague's computer no postbacks are fired although he uses the same OS (Win 7) AND the same browser as I do (IE9). I don't have any access to his computer right now which makes it kind of hard to deb...
{ "language": "en", "url": "https://stackoverflow.com/questions/7521143", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Why is my Float Variable Holding Whole Numbers? I've been glancing at this code for a while now, and I can't seem to figure out what the probably simple error is... In short, I have a float variable in Java that seems to only be storing the integer content (whole number) of what the value is actually supposed to be....
{ "language": "en", "url": "https://stackoverflow.com/questions/7521145", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }