text
stringlengths
8
267k
meta
dict
Q: Group array items based on variable javascript I have an array that is created dynamic from an xml document looking something like this: myArray[0] = [1,The Melting Pot,A] myArray[1] = [5,Mama's MexicanKitchen,C] myArray[2] = [6,Wingdome,D] myArray[3] = [7,Piroshky Piroshky,D] myArray[4] = [4,Crab Pot,F] myArray[5]...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596794", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "11" }
Q: Why Augment Reality does not work well in Portrait orientation As above, I need some help on AR for my windows phone. The below code is what I used: Orientation : Portrait XAML : <Rectangle Margin="0,44,0,178"> <Rectangle.Fill> <videoBrush x:Name="videoBrush" /> </Rectangle.Fill> </Rectangle> ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596795", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: setattribute in javascript This is my code to dynamically set the onclick attribute to links, but without me clicking the links itself, the alert is triggered. window.onload = function() { var links = document.getElementsByTagName("a"); for(var i=0;i<links.length;i++) { elm = links[i]; elm.se...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596798", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: django filter depeding on character count of the related model's fields I have two models such that class Employer(models.Model): code = models.CharField(null=False,blank=False,default="") class JobTitle(models.Model): employer = models.ForeignKey(Employer,unique=False,null=False,default=0) name = model...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596799", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Odd behaviour when doing LIKE with wildcards searching for backslash in MySQL I've encountered a very unusual problem with MySQL, involving backslashes. Basically when I do a wildcard match with LIKE for \n which is in the database as text rather than an actual newline, it will only return a match if I have just a r...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596801", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: Can somebody explain clearly what this code does? - OpenGL & SDL In general I want to find out what the opengl functions do in this piece of code such as glOrtho();. I have searched around trying to find out in good detail what they mean and do but I have trouble finding any good explanations of the code. The SDL c...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596802", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to increase rows in NSMutableArray? NSString *categoryStr = categoryName.text; NSLog(@"Category Name:--->%@",categoryStr); appDelegate.categoryData = [[NSMutableDictionary dictionaryWithObjectsAndKeys: categoryStr, @"name",image ,@"image", nil] mutableCopy]; [appDelegate.categories addObject:appDelegate.catego...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596811", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-2" }
Q: do not remove leading whitespaces when enclosing text in an environment using vim's latex-suite I am using vim with latex-suite plugin. I have a piece of text, that I want to enclose in verbatim environment. Let's say it looks like this: <?xml version="1.0" encoding="UTF-8"?> <errors> <error>Record not found</...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596814", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: free speech recognition engines for iOS? I am looking for some free speech recognition engines to use in my iphone application... can you suggest any? A: Nuance just opened the doors for developers to the Dragon Mobile SDK (they are industry-leaders). have a look at NDEV Mobile A: There are a couple of wrappers o...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596816", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Android-jquerymobile: how to define css for button onclick I'm using jQueryMobile pages inside my Android's WebView. For my jQM page buttons, i have css like.. jQuery(".pm_btn").css("background-image", "url(bluebutton.png)"); jQuery('.pm_btn').mousedown(function() { jQuery(this).css("background-image", "url(redbu...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596817", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How can you put span tag inside anchor tag in Html.ActionLink? Can anybody tell me how do I put span tag inside anchor tag? This doesn't work: @Html.ActionLink("<span>Home</span>", "Home", "Home",new { @class = "active" }) I get Html encoded output if I do like that. A: Use Url.Action insted of Html.ActionLink. T...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596827", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: calculate the arithmetic elements of php array? this i my array $arr = array(1,2,3,4,5); How to get the result that calculate the value of this expression ((((1-2) -3)-4)-5)? A: 2 times the first entry minus the whole sum - looks pretty quick. echo (2 * reset($arr)) - array_sum($arr); A: Just substract the sum of...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596830", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: lastchild for Internet Explorer I know there are some ways to get the "lastchild" work for Internet Explorer. CSS doesn't seem to work that well. I read about a jQuery version, but am not sure how to do that exactly. I only need this because I use list styles with border-top and border-bottom to create "shadow-effec...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596834", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Rails 3 - ERROR Errno::EINVAL: Invalid argument when testing the page Hio, i need help. I developed application in Ruby on Rails 3. Its simple application witch some scadfolds and only CRUD operation on mysql database. Because I am Windows 64-bit user i have sometimes problems with some gems(for example mysql2 gem e...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596837", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Caching database query results on webserver in a database using .net cache provider classes I have an e-commerce like site to build and given the frequency and volume of request that we would have to handle, its best to incorporate caching in our code base from the beginning itself. I read about .net 4's system.runt...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596840", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: ORACLE and Entity Framework. Error:the specified store provider cannot be found in the configuration or is not valid In my project I am using oracle and entity framework together.Both of my machines my developer machine win7 and my server win2008r2 I installed oracle beta entity framework and .net 4.0 framework. H...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596850", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Hiding icefaces autocomplete list when there are no matches Friends! I use icefaces ice:selectInputText item to represent input box with autocomplete hints list. Backing bean is returning list of suitable hints (it selects hints from one big list on condition that they contains characters already entered by user int...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596851", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Move branch start in Mercurial My problem is similar to Mercurial move changes to a new branch, but is not exactly the same. A colleague of mine started working on a new feature and issued a few local commits. Then he noticed "Oh well, that should go into a named branch" and thus created one. The problem is, the com...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596854", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Qt: OSX: Where to put (both file manager and exec accessible) resources? im a bit confused about the most proper way to manage resources (files and folders) needed by the application. I make it clear: I have an executable ( developing on mac osx with qt ), and a i have a fixed folder hierarchy, where a bunch of con...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596856", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: can getJSON be used to get a value from an html tag id already rendered by a page?? json_decode? what i mean by this is after an html page is rendered, how can i get the value by using the html tag id?? ex: get the value of date by using td_date in my JS function?? below the code that puts the data on the page: lis...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596859", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-2" }
Q: Stored procedure exception handling SQL> DECLARE 2 TotalUpd NUMBER(36) := 0; 3 BEGIN 4 dbms_output.put_line ('Job Start time............... : ' || to_char(SYSDATE, ' hh24:mi:ss')); 5 UPDATE Asset SET _status = 'PROGRESS' WHERE status is null; 6 TotalUpd := SQL%ROWCOUNT; 7 dbms_output.put_l...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596860", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Regex to find inner if conditions I had a regex to find single if-then-else condition. string pattern2 = @"if( *.*? *)then( *.*? *)(?:else( *.*? *))?endif"; Now, I need to extend this & provide looping if conditions. But the regex is not suitable to extract the then & else parts properly. Example Looped IF condit...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596861", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Input Validation Silverlight i have a textbox which is not bound. <TextBox x:Name="inputBox" Grid.Column="1" Grid.Row="1" /> The textbox is to only accept numbers (doubles) and show a warning at once something else(letters or symbols) is written in to the box. On the TextChanged event, i do some calculations depe...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596865", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Smaato and iAds combined i am willing to implement iAds by default in my application which is now correctly showing, and also I have properly implemented Smaato's SDK. Is there any method to show by default iAds and when this don't serves me an ad, then pull from Smaato? Thank you A: There is an example for this wi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596874", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: LINQ (Dynamic): OrderBy within a GroupBy using dynamic linq? I had the following query using normal linq and it was working great (using anonymous type), var result = from s in Items group s by s.StartTime into groupedItems select new {groupedItems.Key, Items= groupedItems.OrderBy(x => x...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596878", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: selecting rows from table which have distinct values for a column In my thread based messaging system, the table schema is > messages table id(int auto incr primary key) body(varchar) time(datetime) >message_reference table id(int auto incr primary key) message_id(forgain key from message table) sender receiver H...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596879", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: RSA encryption/decryption using java API is generating BadPaddingException:Data must start with zero public class RSAAPI extends JFrame implements ActionListener{ JButton encrypt,decrypt,clear,exit; JLabel plainlbl,encrlbl,decrlbl; JTextArea plainText,encrText,decrText; static KeyPair kp; static KeyPairGenerator ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596882", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: Cross-domain jQuery.getJSON from a Node.JS (using express) server does not work in Internet Explorer This is an annoying problem, and I don't suppose that it's only IE that has this problem. Basically I have a Node.js server, from which I am making cross-domain calls to get some JSON data for display. This needs to ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596885", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Resorting an NSMutableArray How does one resort an NSMutableArray using an index? I would like to take an index e.g. 9 and everything up to 9, 0 - 8, needs to be put at the end of the array so the array would look something like this. 9, 10, 11, 12, 13, 0, 1, 2, 3, 4, 5, 6, 7, 8 in terms of the positioning. How is ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596887", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Android - AES decryption failing with strange content lengths i am trying to decode an AES encrypted data that i get from a webservice. The encrypted length is: 4256 bytes The decrypted length is: 4247 bytes Baiscally i think that would be ok because of some padding or something... BUT. the data actually decrypts fi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596888", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Turn on the network provider Is it possible to turn on the phone radios (3G/Data connection) from an android application, without navigating to the settings page? How? A: This question is similar to: how to turn internet connection (GPRS/EDGE/3G) on/off Have a look at the project mentioned in the answer: http://cod...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596892", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Windows Authentication using roles for CRUD restrictions I am a student who is working on a website that has some things in common with SharePoint. I use ASP.NET MVC 3 to create an intranet site so people can be authenticated by Active Directory. I have trouble implementing these requirements: * *Users can define...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596894", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Unable to instantiate subclass of WakefulIntentService as a receiver I'm implementing a datalogger service using WakefulIntentService and AlarmManager. I'm having trouble instantiating the receiver, however. Here's what I'm getting when I try to run the app. ERROR/AndroidRuntime(3181): java.lang.RuntimeException: U...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596898", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Bind unbound Services in Android I'm developing a Android Service. I would like the service to run even when the application not is active. So I start it without binding it: startService(new Intent(Service.class.getName())); Now it will run continuously until I choose to stop it, right? If I, from another activity,...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596908", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: MySQL query to return an avg price per month(get the month out of the date formated 2010-03-30 for example) I have three tables... Given the following tables I would like to know how to write a query to return all the book sorted by month and with a average price per month table (that would be something like SUM(i...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596914", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Should meta tag fb:admins include the app:id number as well? I developed an application which produces many open graph instances. Each of these instances has a like button and a connect forum. In my meta I specify my app:id and fb knows I am an admin for every forum. I can store the facebook ID of each of the open g...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596916", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: WinRT - TCP clients? I am building an IRC client in the new WinRT (.NET 4.5) framework for Windows 8 Metro applications. However, I have some issues. I've already figured out that I need to use a StreamSocket to read TCP data, but I may be doing something wrong. The reason I believe this is because I am not receivin...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596919", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "8" }
Q: Sorting based on one of many related entities Entity B (Book) has a one-to-many relationship with the entity D (Description). The idea is that a book has different descriptions for different languages. I want to sort books based on their titles (D.title) for a given language (D.languageID) If B had one-to-one relati...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596920", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Deploy / build application for OSX I have created my first XE2 FM HD application. I have my OSX machine connected and running debug builds on OSX works fine, but I don't have a way to create a release version and copy it to another computer. I tried just copying over the Package made by the debug but that's missing ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596923", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Simple GWT RequestFactory crashes Used this http://code.google.com/webtoolkit/doc/latest/DevGuideRequestFactory.html tutorial to understand the basic concepts, but having problems running my app from Eclipse: 15:48:04.384 [ERROR] [Main] Uncaught exception escaped com.google.web.bindery.event.shared.UmbrellaException...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596926", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: CASE query clarification New to SQL and I've just created a SQL query with assitance: SELECT CASE WHEN exists (SELECT CLIENT_CODE FROM STG_DM_CLIENT WHERE CLIENT_CODE NOT IN (SELECT CLIENT_CODE FROM DM_CLIENT)) THEN 'A' else WHEN exists (SELECT STG.CLIENT_CODE AS TRAN_TYPE ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596928", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How can I start the next matching activity if my app is the default one I have an activity that works as a hook for various intents. Specifically, the VOICE_COMMAND and CALL_PRIVILEGED. (It is a requirement to use these.) <activity android:name=".MyActivity" android:enabled="true"> <intent-filter> <a...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596929", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: iPhone simulator - simulate 3G connection I am testing the Reachability api, but my physical device only has WiFi access, as I don't have a phone contract. My code needs to distinguish between being connected to 3G/2G or WiFi. Is it possible to simulate a 3G connection on the iPhone simulator? Clarifications: I am...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596930", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "21" }
Q: Compare multi dimentional arrays in javascript I would like to compare 2 "multidimensional" arrays (arrays nested in arrays). var old_dataArray=new Array(("id-2", "message", "user"), ("id-1", "message", "user"), ("id-0", "message", "user")); var new_dataArray=new Array(("id-3", "message", "user"), ("id-2", "message"...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596934", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Problems with Qualcomm Scorpion dual-core ARM NEON code? I am developing a native library for Android where I use ARM assembly optimizations and multithreading in order to get maximum performance on the dual-core ARM chipset MSM8660. While doing some measurements I noticed the following: * *The single-threaded li...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596936", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Getting URL in Javascript Ok, I'm new to JavaScript and need some help here. Working on forward/backward buttons on a page. Essentially, the url looks like this http://webaddress.com/details?id=27 So, my two functions are meant to extract the url and forward to the same page decrementing or incrementing the details ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596940", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: jQuery filtering & sorting of tables - how to look "inside" html tags I am making use of a tablesorter library. My issue is that every item in a cell inside of my table is a link, and the library starts sorting things incorrectly because it's looking at the HTML inside the cell, instead of the text. In other words...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596949", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Android Heap memory increase I am developing an application on Android 2.2 which takes extensive memory and my most operation cannot be complete because of low memory. Could anybody give me solution that how can I increase my application heap size. I have tried android:largeHeap="true" but it is not supported in And...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596950", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Batch File using sed in windows - unexpected append instead of replace I've been tasked with migrating a group of batch scripts to Windows 7 (from XP) and have had a few problems using sed for substitution. What i need the line to do is find LogPath and anything inside the double quotes should be replaced with ABC (...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596954", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: A use case for retry function? I read this snippet, and I am trying to understand how I can use retry, and I am unable to think of a use. How are others using it? #!/usr/bin/ruby for i in 1..5 retry if i > 2 puts "Value of local variable is #{i}" end A: There are several use cases. Here's one from the P...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596966", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Animation while switching Activity in Android? I want an animation while switching from one activity to another in Android. The animation I'm aiming for is a bottom to top like animation. How can I do that? A: Yes it is possible. check out this question. You have to define animations in anim folder than you can ov...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596976", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "17" }
Q: Redirect to created invoice after it's saved I need to tweak magento admin so after a new invoice is created at a link like this: admin/sales_order_invoice/new/order_id/550/ to redirect to /admin/sales_order_invoice/view/invoice_id/384/order_id/550/ Right now, after an order is created magento redirects to admin/...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596980", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Change dynamic part of an snippet that is included via JSF-2.0 templateing I have a problem with the JSF-2.0 templating mechanism. I implement some snippet that are included to template file. But one of my snippet contains dynamic content. I do not get an error. But nothing is replaced in my snipplet! The result d...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596982", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: animate() & fadeTo() both synchronous I have a problem with the following two methods. $(this).fadeTo(200, .8).animate({bottom: 130}, 200); Both are synchronous, therefore first it fades to, then it animates. Is it possible to use fadeTo with animate? (CSS option 'opacity' is not cross-browser compatible and therefo...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596983", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: returning boost list from exposed class I exposed a c++ class to python, one of its methods is something like: boost::python::list getList() { boost::python::list l ... return l; } it works perfectly, and I dont get any compiler warning.. since I heard that working with containers is a mess with c++/pyt...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596993", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Best way to programmatically create dial images? I'm working on a website that uses a lot of different sized and styled dials. These are used as progress indicators, so the more filled a dial is, the closer to 100% complete that item is. I'm looking for a cross-browser, abstract solution so I can use the same soluti...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596995", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Best way to design shopping cart domain model on C#? Google can`t help me. I find only this link: http://flylib.com/books/en/2.522.1.56/1/ So, once there is the question - why do we need divide Product and Item? A: Product is too complex to use it on your Cart. We can imagine that Product holds data about: Manufact...
{ "language": "en", "url": "https://stackoverflow.com/questions/7596997", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to get muli-language (human language) intellisense in .Net I'm creating a library (C#, .Net), but I need to distribute it to customers in multiple countries. When you add XML comments to your classes, intellisense picks up the comments out of the assembly and gives you a nice description of your methods, proper...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597006", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Mongodb match empty object in nested document I'm just wondering if this is possible to do in a single request? Given { _id: 1, foo: { fred: {}, // <- I want to remove empty keys like this barney: { bar: 1 } // <- But keep these keys } } Expected { _id: 1, foo: { barney: { bar...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597013", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "14" }
Q: Changing mercury color in thermometer in JFreeChart I have created a thermometer chart with JFreeChart, but I want to change the mercury color in thermometer. How can I do this? Here is my code so far; please explain where to change this code: final DefaultValueDataset dataset = new DefaultValueDataset(new Double(10...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597015", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Passing Image between servers for remote saving My Spring application passes image file to Jersey application to get rid of all image manipulation tasks. On receiving image, the Jersey application should save the image after several manipulations (crop, resize etc) and return image url. For this, the Spring applicat...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597024", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: difference between stdint.h and inttypes.h What is the difference between stdint.h and inttypes.h? If none of them is used, uint64_t is not recognized but with either of them it is a defined type. A: See the wikipedia article for inttypes.h. Use stdint.h for a minimal set of definitions; use inttypes.h if you also ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597025", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "96" }
Q: Adding UISearchBar programatically - Bar is Off Screen at Launch - iPad I have added a UISearchBar to a table in my iPad app using the below code. The table is on the left hand side of my split view controller. The problem is that when the app starts the search bar is strangely off screen to the left - you can just ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597026", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Returning a string containing valid Json with Nancy I receive a string that contains valid JSON from another service. I would like to just forward this string with Nancy but also set the content-type to "application/json" which will allow me to remove the need for using $.parseJSON(data) on the client side. If I use...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597035", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "50" }
Q: Styling ASP.NET file uploader for different dimensions Is there any way to change the width of ASP.NET file uploader. I tried adding the CssClass but unable to change the width. I just wondering is there any other way to achieve this. Thanks A: you can't change it directly some tricky solutions available like http...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597038", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: MFMailComposeViewController in the delegate The question deals with an application which uses many views in a UINavigation controller Style. I have a simple function in my delegate which can be used by all views to plot-out error message // In Appdelegate.m -(void)popErrorWindow:(NSString *)theError { UIAlertVie...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597039", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to extract all the IUPAC names mentioned in the data available from Pubchem(NCBI) into a text file? I want to build lists of prefixes and suffixes of some length from all the IUPAC names mentioned in Pubchem Database,so that I can use them further in my project as a feature.So I want all the IUPAC chemical names...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597049", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Select rows with same value and then insert a null record i have written an query but it inserts alternate null columns. I want the null column after different orderids. Suppose i have two orderids 100 and 101. i have only one record for orderid 100 and two records for orderid 101 so it should insert null column aft...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597050", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: How to programmatically add calendar subscriptions on iOS? Via the settings panel of your iPhone, you can add a subscription to a remote .ics calendar format. I have a Dutch iPhone app that does this from within the app (see the screenshot below, "abonneren op de agenda" means "subscribe to the calendar"), but there...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597051", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: ORA-22813: operand value exceeds system limits I'm having an issue with an oracle object I created. The goal of the stored procedure is to either retreive all wires contained on an airplane or compare the list of wires with another one (past airplane wire configuration). You will understand that this can be quite bi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597053", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Javascript in browser IS able to use sockets/get info from web by itself? Is it possible to open sockets and get data from web in JavaScript. My aim is: to work with web data using JS. I have looked for XmlHttp/AJAX solution, but I have found one note, that AJAX can be used only for calling localhost programs, which...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597056", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: Android set(get) environmental variables in Java I have experimented little with Android OS and I tried to call System.getenv() to get environmental variables. It works e.g. for $PATH, but I was not able to define own variable, which can be accessible in this way... Is it possible? I have tried to set and export va...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597058", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "18" }
Q: Add a language in the Stanford parser I would like to use the Stanford parser in another language not already implemented. I looked on the website but found nothing that could help me with that. I guess what I have to do is "just" create a new languagePCFG.ser but to do that? Also, if anyone knows if French and Span...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597061", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Qprocess messes my linux command up (i think). how to fix? I need to force my c++ QT4 application to read results from a linux command. I am trying to use Qprocess but as soon as my command gets complicated it get messed somehow (just guessing) and does not work. Here i try to make for yu a small example: QProcess p...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597062", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: is it considerably faster to query different tables than having a where clause imagine that we have this table: create table Foo( id int, name varchar, k int --can be 1 or 2 or 3 ) or we could have 3 tables for each value of k create Fook1( id int, name varchar ) ... create table Fook2 ... createa table Fook3 is i...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597063", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: QMainDialog become modal if has modal QDialog as parent on Mac OS X I create QMainWindow with parent widget which is modal QDialog. QMainWindow created as modl window ontop of dialog and doesn't has active close, minimize buttons and has grayed(unaccessable) menu. I suppose access to QMainWindow's menu restricted s...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597065", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Can we ON or OFF the device programatically? I know there is a way where we can reboot the device. And it shows immediate result. But my need is as :- I want that when I will be in my class-room my phone automatically goes to OFF. (Lets say at 2:00 PM), and when I will end my class, my phone will automatically ON (...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597066", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: preg_match: trying to identify number formats I'm trying to identify not only "numbers" in a string, but tag what type of number it is, such as General, Fraction, Percentile, Ratio etc. Now if I use a tool like http://rubular.com/, my patterns appear to work fine. Rules? ([-+]?)([0-9]+)([,+]?)([.]?) //General ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597069", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Spring jdbc templates : What is the best way to keep sql statement out of code There doesn't seem to be a named query support in Spring JDBC Templates. By named query I mean the facility to reference sql statement by name in java code and keep the actual statements in some configuration file. In the absence of out-o...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597074", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Relationship Using Code first with Existing database When defining a relationship between two types is it important to include a navigation property on both types, such as in the following example: public class Product { public int ProductId { get; set; } public string Name { get; set; } ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597076", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How can I set Ant to copy specific files to output? I am developing in eclipse websites in php. I want to create a build configuration using Ant, to copy files from the project folder to a specific output path. How is this possible using eclipse builders? A: Ant copy task: http://ant.apache.org/manual/Tasks/copy.ht...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597079", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Combining vector and bitmap graphics in a pdf When plotting images or heatmaps to pdfs as in the example below they are saved as vector objects where every pixel in the image or cell in the heatmap is represented by a square. Even at modest resolutions this results in unnecessarily large files that also renders ugli...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597081", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Ruby - No gem to load in cronjob I use rvm. and ruby 1.9.2 is installed in rvm. I have a script and it runs fine in terminal. I have wrote a cron job for the same script: 27 * * * * su - sayuj -c 'cd /path/to/dir; /home/sayuj/.rvm/rubies/ruby-1.9.2-p136/bin/ruby script.rb >> /var/log/script.log 2>&1' Then it show...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597085", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Why StreamReader.EndOfStream property change the BaseStream.Position value I wrote this small program which reads every 5th character from Random.txt In random.txt I have one line of text: ABCDEFGHIJKLMNOPRST. I got the expected result: * *Position of A is 0 *Position of F is 5 *Position of K is 10 *Position ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597089", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Is it posible to get all the values of the text boxes with the same name? I have a doubt in javascript. Is it posible to get the values of text boxes with the same name ? for example <INPUT TYPE="text" NAME="inputbox" VALUE=""> <INPUT TYPE="text" NAME="inputbox" VALUE=""> these text boxes have same name, how can ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597092", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to check the exist value Using VB.Net and Sql Server I want to check the user Entry Value. The User is entering the code in the textbox, before saving to the table, i want to check whethere code is already exist in the table or not. Tried Code cmd = New SqlCommand("Select code from table where code = '" & textb...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597095", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How do i set my cookies to a specific domain? I have www.mysite.com and static-cookieless.mysite.com. My www site seems to be setting cookies on mysite.com thus my static site is no longer cookieless. How do i set cookies to only my www site? I am using plain javascript (well, jquery.cookie but i know how to edit th...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597096", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: MYSQL SELECT QUERY where column is the same Hi I am trying to query a table in my database, basically I need to select the driver_id from the table where the team_id is the same as the users driver id, stored in a variable $user_driver_one. So pretty much selecting the other driver with the same team_id. column driv...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597097", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Eclipse create java executable with external libraries I've seen this topic in this forum but it I need a more basic explanation on how to do this. I've done a program in Java with some external libraries (LWJGL and Slick). So this is what I've done and my program won't start anyway, tell me where I've done wrong. I...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597099", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: XSLT to call secondary XML based on first XML element/attribute love the stuff - newbie Æthelred here I have a XSLT 1.0 file pulling in a secondary XML (to a variable) to build a table <xsl:variable name="table_values" select="document('./table_variants/external_table.xml')/xml/channel_1"/> I then get the values...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597101", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Generate PDF based on HTML code (iTextSharp, PDFSharp?) Does the library PDFSharp can - like iTextSharp - generate PDF files *take into account HTML formatting *? (bold (strong), spacing (br), etc.) Previously I used iTextSharp and roughly handled in such a way (code below): string encodingMetaTag = "<meta http-equ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597103", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "25" }
Q: Go to a specific directory in Java Servlet i have a app folder in tomcat webapps named BankApp, and there is a temp directory in it. I want to get all the files in temp folder I tried this : File file = new File(path + "/temp/"); File[] list = file.listFiles(); for(int i=0;i<list.length;i++) { out.println...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597104", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: C# Asynchron call with Named Pipes in WCF I have a WCF host created with named pipes binding: using System; using System.ServiceModel; using System.ServiceModel.Description; namespace Microsoft.ServiceModel.Samples { // Define a service contract. [ServiceContract] public interface ICalculator { [OperationContra...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597108", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How to use NSUserDefaults to store a row property I have a tab bar based application, with a TableViewController on a tab. When i update my app, i add a new row to my Table. What i want to do is store the highlight color of a row of my TableViewController as soon as i insert a new one, for at least 3 sessions. I kn...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597111", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: iOS: How to Backup a Project? What's the best way to backup a project? To be more specific: I have a DropBox account and I prefer to have a copy of the project over there. I assume I should copy all the h+m files. Can I copy all the xib files? does it make any sense? Can/Should I copy all the jpg/png/mp3 files that ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597114", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: htaccess line - 500 error I have a htaccess file: <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> I want to add the line below, but it gives me 500 error. Options ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597118", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Android: Handling tap event on an ImageView inside of a HorizontalScrollView I have a bunch of ListViews inside of a HorizontalScrollView. I would like to have a "tap" event when the user taps on the image. Currently I am using the OnTouch event but this is a problem. If I swipe the HorizontalScrollView to view more...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597119", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: MatchTemplate in OpenCV with Python I'm using opencv with python bindings. I'm trying to use the template match, but it's not performing exactly as I need it to. If there is no image matching the template I supply it, I don't want it to return a match. It seems to always return a match whether the actual template...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597120", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Regarding Oauth 2.0 & https from October 1st I want to know several things about new changes that will be applicable from October 1st that are Oauth 2.0 & https. Will it be compulsory to provide https link when creating new application? I have enabled https on main domain and my applications are on subdomain so do...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597121", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to create a Magento 1.6 shipping module? I'm trying to create my own Magento shipping module in Magento 1.6. Since I have no experience making Magento modules, I'm trying to find a blank custom shipping module to add stuff to. There are a few tutorials online, but they all seem outdated or loaded with bugs. Can ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7597123", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }