text
stringlengths
8
267k
meta
dict
Q: Java: inheritance, instance variables and this I understood that this is a reference to the currently executing object. If that is the case can you explain the behaviour of the following code? public class Inherit { public static class ClassA { private String privateInstanceVar = "Private"; ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598174", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to rescale widgets in a layout? I have a widget (lets call it a main widget), which should display another two widgets. I am using QGridLayout to position these two widgets in the main widget. (This is just simplified. I really got 5 widgets in the main window) Initially, these two widgets are of the same size, ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598178", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: pygtk popup executes out of order I have pygtk menu, in which a function is called on menuitem click, in this function i am showing a popup to user saying wait while checking internet connectivity and then calling a function which checks internet connectivity, My problem is the my programs is first calling the inter...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598182", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: What other options do I have to streamline WordPress memory utilization? So I've run into a wall trying to crack why this WordPress install hogs so much memory. I upgraded my server from 512 to 1 gb ram on a MediaTemple DV 4.0 account, and this single install is using 60% on average, which jumps to 118% if anyone fi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598185", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Returning validation errors as JSON with Play! framework I want to build an application where forms are submitted via Ajax without a complete page reload. To display server-side validation errors the server should return validation errors as JSON and an appropriate HTTP status (400). How can I accomplish this with ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598186", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "8" }
Q: Can I get Entity Framework to work only part of a table? I need to connect to an existing database table and allow users to update a few columns. The thing is, this database table is part of our 3rd party software and contains over 150 columns, and I only need to access about 5 of them. Is there a way, without using...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598194", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Saving images as pdf sharepoint I have some images in a asset library of sharepoint server 2010. i want to convert and save them as PDF files. Is there any service available within sharepoint server 2010 for this just like word automation service is used for ms office documents conversion. A: I was working with a C...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598198", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: What guarantees are given by SMB and EXT3 regarding order of file writes? From my (Linux-)application, I am watching a hotfolder for specific sets of files. For example, I am waiting for this set: * *example-1.xml *example-2.xml *example-3.xml The hotfolder is shared over the network via SMB. Now, to be sure ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598199", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to preempt a ProgressDialog? App I'm building is carrying out a task, ProgressDialog is on the screen circling 'round and 'round. How can I provide the user the ability to break out of that Dialog at any given time, immediately disappear the Dialog and stop the task from being carried out mid run? A: Try this ,...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598202", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Navigation bar not displaying well in IE6,7,8 but works on 9 and all other browsers [www.tdeltd.net][1] [1]: http://tdeltd.net is my site. The navigation bar is broken in all versions of IE except 9. All other browsers display the site properly. After two days of searching I am posting here as I cant find the soluti...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598204", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Including demo database in installation pack I have a C# program which is using Sql Server 2008 R2 to store data. I have a problem with deploying the application, because I want to include a demo database in the installation pack, so that its easier for users to test. Is there a way to do this? A: This is not simpl...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598209", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: UISearchBar, UITableViewController and UINavigationController, Got a SIGSEGV while executing native code I have a simple test application with a NavigationController that extends UINavigationController [MonoTouch.Foundation.Register("NavigationController")] public class NavigationController : UINavigationController ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598210", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How would I get text from an input 'type=text' element using jquery? Provided I cannot edit the HTML code at all how would I do this? <input type="text" id="Identifier" class="inputControlFlexWidth" value="" tabindex="9" size="25" name="texthole"> I'm guessing this has to be a timed event such as setInterva...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598214", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Drupal live and staging image path I have 2 version of my drupal site that are the live and staging. My live site is http://www.mysite.com/ and the staging is http://mystaging.com/site/www.mysite.com/. In live site, the path of images is displaying but on my staging the images are not displaying. It’s because of the...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598216", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to set enable=false to a item template inside a grid in asp.net I want to set enable = false according to the role I have an if statement to check for the role page load() { if(role == "something") { // I want to set imgbtn.enabled = false; } } How to do that. <Columns><asp:TemplateField Hea...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598219", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: iOS camera, torch intensity control is there a way to control the iPhone 4 torch intensity. I did a lot of looking around and the documentation says there are only 3 states : off, on, auto. Any kind of workaround is welcome. A: No, there is not a way to do this as of iOS 5.0.1.
{ "language": "en", "url": "https://stackoverflow.com/questions/7598221", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Fill continental areas in geographical maps created with R I try to get into creating geographical maps using the maps-package in R. I'm not sure if this is the "package of choice". I tried to draw a map of the world with a bluish background, white continental areas and red country borders. But it seems, that it is ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598223", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: OOP : Naming a class In my application I have a Market with a bunch of Levels. Each level has Goods and Supply Chain Operations. Now, I'm stuck figuring out how to name a family of classes that populate Levels with these entities. I know that a name is important in a sesnse that a proper one makes code self-commente...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598225", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to perform server-side validation before submit Form contains input element. Entered value is validated using server callback from blur event andler. If wrong value is entered and submit button is pressed, form is submitted with wrong value: Validate method is not completed but form submit action method is execu...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598227", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Check the possibility of allocating a certain amount of memory on the x64 platform I have an application that uses a lot of memory, but it is a normal situation. I need to inform user if there is not enough memory to perform an operation. I know that x86 process can allocate less then 2 GB user memory. But x64 proce...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598230", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: String format compare in objective c hello all i have one NSString in this format +1-123-123-1234 (phone number US base style) , my question is How can we compare that my string is formted in +1-123-123-1234 format . on the basic of String compare formatted i have to done another task ..so any one have any idea reg...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598240", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: XAML Stop List Box Text Style Changing on Defocus I have an issue with a .NET 4 XAML program which contains a ListBox. When a the list box looses focus the text turns to grey rather than the set white colour. The background did do this but I resolved that with <Style.Resources> <SolidColorBrush x:Ke...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598241", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Entity Framework Code First DbContext Checks the ConnectionString During Compile? It seems that the Code First DbContext really uses the given ConnectionString during compile? I don't even know how that is possible but to me it seems to be so. If I turn OFF my local SQL Server, I get the error stating "Failed to get...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598242", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Immutable in java In Effective Java, Bloch recommends to make all the fields final in making an object immutable . Is it necessary to do so ? Won't just not giving accessor methods make it immutable. For example class A { private int x; A (int x) { this.x = x; } } The above class is immu...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598245", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: UIVideoEditorController know the start and end point I am trying to use the UIVideoEditorController to be a UI so user can choose the place to split the video into 2 pieces. The problem with the UIVideoEditorController is that I cannot know where user chooses the start position and end positions. Does anybody know h...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598254", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: generate a patterned numpy matrix Is it possible to generate a numpy matrix with a circular pattern of "1"s in a rest matrix of "0"s? So basically a generate(ysize, xsize, ycenter, xcenter, radius) Should look something like [000000000] [000000000] [000001000] [000011100] [000111110] [000011100] [000001000] [00000...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598264", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How I can Save WebView Contents to show even when no network available? I am creating a app and using WebView for open URL. I see some apps offer "Save Page"(A web page) option to user. I want to know how to Save a page from my WebView so that I can show it to user when it request. A: Maybe using a cache is the b...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598273", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How to do Spring.NET DI injection in action filters (ASP.NET MVC 3) Tried to search but no specific answers (I am very new in this)... With Spring.NET supporting ASP.NET MVC 3, how can I do dependency injection inside action filters? Studied around but I have no clue at all! :/ On Spring.NET documentary, it appears ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598279", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: JSON object parsing into a TRY, CATCH block I would like to check for a condition which if true should goto the next statement. The problem I am facing is that I've put the code in a try, catch block. Every time I check for its value I need to initialize it, but once initialized if found untrue, as normal execution ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598283", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: objective-c: Webservice, How to get two elements after parsing through NSXMLParser? I am using the below code which gives me the string of one element after parsing, while I want to get another element's text on the base of first element's result. e.g. I am getting bool value from ResponseType and now on the base o...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598288", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Linq projection of flattened table into parent and child object graph I have a enumerable list that contains a flattened parent-child relationship: ParentGuid1, ParentName1, ChildGuid1, ChildName1 ParentGuid1, ParentName1, ChildGuid2, ChildName2 ParentGuid2, ParentName2, ChildGuid3, ChildName3 ParentGuid2, ParentNam...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598291", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Android How to get First Activity's Handler data into third activity? I have three activities A,B,and C. I go from Activity A -> Activity B -> Activity C Now currently Activity C is displaying and Activity A is bottom on Activity Stack then I provide some inputs to Activity C through which the another thread send ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598295", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Jquery mobile - How to dynamically create content on pre-existing pages using XML First time posting here so take it easy with me, lol. I'm currently trying to load content into my "pages" that I have already written the html out for. My jquery script is reading the data in from my xml file content.xml. My first pag...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598297", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: What's more difficult to reverse engineering: Application or jar containing Applet? What's more difficult to reverse engineering: Application or jar containing Applet? I know it's easy to reach the source code of a java application but is that possible for a jar containing applet like this one in this html? <HTML> ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598299", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Google API 2 legged Oauth : "Token invalid - Invalid AuthSub token." I've based my code on http://gdatatips.blogspot.com/2008/11/2-legged-oauth-in-php.html. Here's my code, I want to work with the Google Doc (Document List) API : $endpoint = 'https://www.google.com/accounts/OAuthGetRequestToken'; $co...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598301", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: newb Qu, themerolling jQuery UI - how to get border thickness and background fade I'm using jQuery UI which seems great but I'm trying to customise it with it's themeroller app. http://jqueryui.com/themeroller/ I'm using a dialog to popup a modal window I can see that I can control the color of borders but I can't s...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598303", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Programatically intercept and/or manipulate check-in comments in TFS / Visual Studio 2010 is there a way to intercept a check-in comment during check-in operation on Team Foundation Server Version Control in order to enrich it with additional information? Another option would be to intercept it and ensure that it's ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598307", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: if the user checks remember me on the asp login control, when will the user have to login again? just trying to get a better understanding of the concepts involved with this so i can make better decisions on implementing the login based on the requirements i've been given. in the case where the user checks the remem...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598310", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to correctly merge 2 branches I have a master-branch called trunk and a branch of it called prototype has been created. Since the branch happened, commits have been done in both trunk and prototype (sometimes even the same files). What's the best way to update the prototype so that it contains all new commits fr...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598316", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Hierarchy for developing several unrelated util packages I developed a Java library and the package is called com.rachum.amir.util.permutation. I also have a github repo called Permutations, and an Eclipse project. Now I want to add some more stuff to my library, e.g., I want to develop a com.rachum.amir.util.range ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598322", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Calculate Dates I have a monthly report that i run manually currently. So, the report runs from the previous month of 27th to the current month of 26th. For Example i'm manually using the following: declare @StartDate datetime = '08/27/2011 00:00:00' declare @EndDate datetime = '09/26/2011 23:59:59' for the next mo...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598326", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Can I save different-2 instance of an Activity in Android? I want to know can I save two or more instance of an Activity and can use those instances as per my requirements. For example I have two Activities say A & B. I go from Activity A to B by checking some condition. if condition meets first instance of Activity...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598330", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: HTML scraping with hpricot using Ruby 1.8.7 vs 1.9.2 Relevant snippet from test.html: <div id="seat_31F_vacant" class="seatVacant" onclick="UpdateHost(this);Common.DoPostBack('lbtPostBack','31F');" onmouseover="Seat_onMouseOver(this)" onmouseout="Seat_onMouseOut(this)">F</div> Now consider this ruby code: doc = Hpr...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598336", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Sign JAX-WS SOAP request I would like to write a JAX-WS web service that signs my SOAP messages using the http://www.w3.org/TR/xmldsig-core/ recommendation. With what I found on the internet I wrote a JAX-WS handler (SOAPHandler<SOAPMessageContext>) that manages to change a copy of the SOAP request: @Override public...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598338", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "27" }
Q: PHP PDO extension not available is command line I've moved from WAMP to EasyPHP and now there are problems using PDO. PDO works fine when I view the site in the browser, but doesn't work in cmd or when I run the test file via Netbeans. I get: "PDOException: could not find driver" In phpinfo() for Configure Command...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598345", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Python: variables by references (hack) Is there any way (hack) to push Python function (def) to return results by reference even for immutable types? A proposal application (swap as subroutine): def swap(a, b): .....a,b = b,a Note: def swap(a, b): .....return b,a works as function which is not the answer of the ques...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598346", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Linter reporting missing tags for OG proto - tags there - xml namespaces there - possibly bad admin The linter is reporting missing properties for the title, url, and type even though they're there. See this linted url for an example We're also getting behavior like this thread, where the like buttons loses it's cou...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598348", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Error when trying to select all items in listbox on button click event Error : Unable to cast object of type 'System.String' to type 'System.Windows.Forms.ListBox'. private void button3_Click(object sender, EventArgs e) { foreach (ListBox item in SelectTables_Listbox.Items) { item....
{ "language": "en", "url": "https://stackoverflow.com/questions/7598351", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Handling OnError events in a class library I am writing a class library that wraps different objects (mostly device drivers for USB hardware components) Some classes of these device drivers expose an event of kind "OnError": in short if a runtime error or other error occured in the device driver then the event is fi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598360", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Additional, non-Paperclip attribute ignores when updating model via accepts_nested_attributes_for I have a model, "Update" which has_many "Assets". An Asset has has_attached_file of :asset, using Paperclip. I can successfully create multiple assets through my update form (using fields_for), but when editing an Updat...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598364", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How to display open transactions in MySQL I did some queries without a commit. Then the application was stopped. How can I display these open transactions and commit or cancel them? A: How can I display these open transactions and commit or cancel them? There is no open transaction, MySQL will rollback the tra...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598373", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "112" }
Q: How to handle plugin settings over TCP I have an application which consists of two parts. A server and a client. The two communicate via TCP sockets. The server supports plugins which in turn can store settings of various complexity (anything from integers and strings to complex objects). I would like to build suppo...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598381", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: Load custom configuration file in WCF relative to Working Directory I have a WCF service library that reads a xml file that's located in the WCF publish location. The project is not client profile. When I debug in the WCF test client it works fine with: XDocument xDoc = XDocument.Load(@".\PaymentAvailability.xml"); ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598384", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: is there any function in c++ to check whether a file given in a specific path is a script(.sh) file or not there is .sh file in one of the directories for eg: path = /opt/WD/CD/SCD/temp.sh is there any function is c++ to check whether file in that location(path) is a script(.sh) file or not bool ValidCommand(const ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598385", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to configure an Element-collection to map an existing DB table in JPA orm.xml configuration? I have migrated an app from a full-Hibernate featured one to a JPA/Hibernate based-one and I have a problem with my JPA mapping. We have managed to use orm.xml to map our entities. Everything was working fine until I hav...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598390", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How to DIE all LIVE'S in a dialog when close? I have a dialog $('.dialog'), then a fill with an html of the form when I open it: $('.dialog').html(getForm()); Then I have a function named close(); When I click close I do: $('.dialog').html(''); $('.dialog').hide(); BUT, if in the form I put dynamic elements (new D...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598397", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: NHibernate mapping many-to-many lists not loading the objects right I am attempting a many-to-many list in one of my objects. I have three classes which I am attempting to save and load via NHibernate: Intersection, Vehicle and Zone. Intersection and Vehicle are both derived from Device. The Intersection class co...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598399", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Sencha Touch tabPanel using dynamic JSON data In my application the first page shows a tabPanel at the bottom. But number of tabs, their labels and icons are dynamic content coming from a json request. I am wondering how to do it. Here is what i tried. TMDemo = new Ext.Application({ name: 'TMDemo', launch: function(...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598402", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: ADO.NET Entity Data Model extension not working I want to develop a Visual Studio extension to add extra properties on entity types. As suggested in the answer to a related question I had asked before, I have installed the ADO.NET Entity Data Model Designer Extension Starter Kit as the first step. However I can't ge...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598410", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Using Session Scope in Spring Beans I'm using JSF 2 for the view and Spring for the business logic. I'm trying to set a session scope to one of my spring beans using annotations(@Scope("session")), but I'm getting this exception: SEVERE: Context initialization failed org.springframework.beans.factory.BeanCre...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598412", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: $.get not get HTML A: If js is off, you cannot call $.get or another js function, respectively method doesn't return noscript
{ "language": "en", "url": "https://stackoverflow.com/questions/7598417", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: What is the best way yo keep version on database? I need to develop a web application. A web shop that sell different product in different package in different region ... The admin need to modify thoses packages while end users wont be able to see his modifications. end user will be able to see those modifications o...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598418", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: jQuery .css, how to translate it into Javascript I have the following jQuery code: <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js"></script> <script type="text/javascript"> $(document).ready(function() { setTimeout(function() { $('.green.bar .inner').css('width', '...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598421", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Is it better to use the mapred or the mapreduce package to create a Hadoop Job? To create MapReduce jobs you can either use the old org.apache.hadoop.mapred package or the newer org.apache.hadoop.mapreduce package for Mappers and Reducers, Jobs ... The first one had been marked as deprecated but this got reverted me...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598422", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "47" }
Q: What are the common pitfalls when using Perl's eval? What are the common pitfalls associated with Perl's eval, which might make you choose to use a module such as Try::Tiny? A: In addition to the answers above, I would add... * *eval is affected by the global $SIG{__DIE__} handler causing action at a distance. ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598425", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "15" }
Q: Lost Session When Moving From Http to Https I am having an issue where moving from http://mysite.com to https://secure.mysite.com causes the user to lose their session information. What would be the best way to deal with this? Thanks A: I think you can use the SQL Server to keep your Session. This will be helpful...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598429", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Adding jQuery to Magento What is the recommended way to add jQuery (or any script) BEFORE the rest of the scripts that come with Magento using local.xml? I've tried to use (in local.xml): <reference name="head"> <action method="addItem"> <type>skin_js</type> <script>js/jquery-1.6.4.js</script> ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598431", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: How to remove a key from a minor-mode keymap in Emacs? I have globally assigned C-c/ to ace-jump-mode but reftex-mode (a minor mode for citations used with AucTeX) overrides this key with some function I never use. I tried local-unset-key but it only unbinds keys from the current major mode's map. How do I remove C-...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598433", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "43" }
Q: How to set long text in a textview with a continuation mark at the end of the textview I have a textview with fixed height. I want to set a long text, but text comes at the last line getting cut by half, I want to avoid it and want to show a continuation symbol. I am giving an image here, I wan to achieve it like in...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598437", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: When to use Runtime.maxMemory() and totalMemory() What is the exact difference between Runtime.maxMemory() and Runtime.totalMemory()? The javadoc is quite vague about this (for me). What are typical use cases for these two methods, that is, When would it be inappropriate to use the respective other one? A: The tota...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598438", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: @font-face works locally but not on live website I have a website in production which uses @font-face to render fonts, and this works fine in a local environment but fails when uploaded to the live website. The CSS file which links to the font files is in the root directory, and uses the following code: @font-face {...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598441", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Can you change a std::list while iterating through it? In the following functions, it it entirely possible for the IObserver's Process() function to try to remove itself from the notify list, using the this pointer's DeleteObserver(). This causes hell with the iterators (not surprisingly!), is there a way round this...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598443", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: MVC RedirectToAction() any way to pass object to the target action? The populated catList is always Count=0 when the code jumps to CreateProduct() so I take it it does not get delivered. Considering RouteValueDictionary does not do this ? Any other way? public ActionResult GetCats(int CatID) { L...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598444", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Detect DTMF Tones C# I have wav file in which using the naudio lib i have been able to get raw data out of the wav files. Does any one know how to loop though the data in chuncks detecting DTMF tones? A: The NuGet package DtmfDetection.NAudio provides extension methods and wrappers to detect DTMF tones in live (cap...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598445", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Can only one procedure within a PL/SQL package be run with AUTHID CURRENT_USER? I have a PL/SQL package that does not specify an AUTHID (effectively making it AUTHID DEFINER). However, there is precisely one procedure within this package that needs to run as AUTHID CURRENT_USER. Is this possible, or must I create a ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598446", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Storing password in database using hash with salt; not sure where/how to store salt I have a ASP.NET (MVC 3) web site where user will be able to login to perform certain actions. I need to store their password in backend SQL Server 2008 database. I will be using form authentication ( not windows authentication). I a...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598448", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: how to know from a Site B, if the user is connected on the site A? I have got a website and now i have to add a forum. The forum will be on a sub-domain of the site, but may be on an other server. The user must sign-in only from the website, to be connected on the forum. If the user try to see the forum without sign...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598449", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How to make a query with or condition in mongoid How can I make a query with or condition in Mongoid. A: Here is the solution for "OR" query in mongoid. if you want query like below select * from user where id = 10 or name = 'hitesh'; in rails with mongoid then you have to write query like this User.any_of({...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598450", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: swfLoader vs mx Image I have an application that I'm migrating from flex 3 to flex 4.5. In this application, there is some mx Image components that load a simple swf file (image). Spark image doesn't load swf files, so I was wondering, should I keep the mx Image, or should I change it to SWFLoader? Is there any adva...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598452", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Sorting nsarray by index I simply want to sort an NSArray by the index number i.e. The order in which the values are entered into the array. My problem is that I use this array in a uipicker, and therefore when reusing labels, end up with my values in the wrong order My values consist of fractions. 1/4,3/8,1/2,3/4,1...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598456", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: When can a cond var be used to synchronize its own destruction/unmapping? According to POSIX, It shall be safe to destroy an initialized condition variable upon which no threads are currently blocked. Further, the signal and broadcast operations are specified to unblock one/all threads blocked on the condition var...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598457", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Update a Dictionary value using Linq I will call AnalyseLinqUpdate() I think code itself clear.. I have to find behavior for each dictionary value and replace the value with the behavior I get from the method 'GiveBehavior' void AnalyseLinqUpdate() { Dictionary<string, string> rawCollection = new Dictionary<stri...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598461", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Rendering issues with Sencha Touch list on orientation change This is for a mobile web site rather than an app. Accessing the mobile site from my iPhone 4 using mobile safari. The site comes up in portrait mode and works fine (can get to all list items although there are only a panel full at this point) and my discl...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598464", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to update location only when button is pressed How can I make my application update location only when a button is pressed? I have a button named "REFRESH". Everytime this button is pressed, I want to show my user their location. For example, 51 Bourke Street, Victoria. However, I do not want to update my locat...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598466", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: jQuery select for element variable I haven't been able to find an answer to this: My HTML (simplified) looks similar to this (there are several different controls on the page: text fields, comboboxes, etc.): ... <input name="name" onfocus="showHint(this, 'Please enter your name')" onblur="hideHint()" ...> ... An in...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598470", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: MSXML loadXML won't load elements with namespace prefixes... Why? Hiho, i guess, it's a pretty stupid question, but i had to switch to C/C++ recently and haven't done this in years. And right now I'm stuck on the following: Given XML Element as a simple String: <myns:factor>1000</myns:factor> I have to parse the st...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598476", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Is returning a type pointer the same as 'newing a type'? in c# Instead of... Video v = new Video(); I want to do Video v = GetVideo(); public Video GetVideo() { return new Video(); } Are these two calls totally equal? A: Yes, they are. I have used this approach several times to return me an object prepopulat...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598481", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to get the array of RGB values for each pixel of the client area of a window Is there a way to receive the colour values for each pixel in the client area of a window, with gdi? A: As noted in comment by @JerryCoffin. Here's a simple example hDC = GetDC(hwnd); hBitmap = CreateCompatibleBitmap(hDC, width, height...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598484", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: C Graphics Library Error I have the following code : #include<stdio.h> #include<conio.h> #include<math.h> #include<graphics.h> void main() { int gd=DETECT,gm; int dx,dy,p,end; float x1,x2,y1,y2,x,y; initgraph(&gd,&gm,""); printf("\nEnter the value of x1: "); scanf("%f",&x1); printf("\nEn...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598490", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Jquery Cycle - how to use circle for pager? Am having a problem getting my pager to look right with jquery cycle. The following code $(document).ready(function() { $('#slider_container') .after('<div id="pager">') .cycle({ fx: 'scrollRight', speedIn: 400, speedOut: 200, timeout: 10000, ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598493", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How do I make my wcf services available for particular user? I'm using CustomMembershipProvider to validate the user for my WCF service. User will get a prompt for his credentials once he access the service. Note: I thought I could get the username and identify the user. But how to pass variable from CustomMembersh...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598503", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Case condition broken need assistance to fix New to SQL, so please accept my apologies. A query was created that when If HBL_CLNT_CAT._HS_EB_CODE1 = 'BF' then value = TBM_BILLGRP._HS_EB_DET1 If HBL_CLNT_CAT._HS_EB_CODE2 = 'BF' then value = TBM_BILLGRP._HS_EB_DET2 However of the _HS_EB_DET# exceeds 100 characters a...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598504", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to get an ACCESS_TOKEN from the new Add to Timeline Auth dialog I currently have the following situation. On my website, the user can access his settings page. This page features a tab called 'Facebook'. On this page, I have the following code that lets the user allow my website to post to his timeline when com...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598505", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: 500 error when querying yahoo placefinder with a particular character? I am using the Yahoo Placefinder service to find some latitude/longitude positions for a list of addresses I have in a csv file. I am using the following code: String reqURL = "http://where.yahooapis.com/geocode?location=" + HttpUtility.UrlEncode...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598513", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: "Symbol 'map' could not be resolved" in namespace Hello! I am currently developing an game engine. Even though I only just started, I have already run into a problem. I have this code: #ifndef INSTANS_H_ #define INSTANS_H_ #include <map> #include "Core/Version.h" #include "Core/Window.h" #include "Core/Component.h" ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598514", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: c# Trackbar increase/decrease I am really new to C# and do have a few problems with the trackbar. I am trying to increase/decreasing the volume by adjusting the trackbar up and down. I do have two commands that I can send with a protocol through serial cable, lets that it is "UP" for increased and "DOWN" for decrea...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598520", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Macintosh: Converting RAW files to dng using a shell script A while back I built a simple droplet app that took raw files and moved them from a desktop to a server location and did a DB update. I've now received a request from the photo dept. to have it also convert raw files to dng format. The app is built in XCod...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598522", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Django admin inline model for User I have model as class Employer(models.Model): create_user = models.ForeignKey(User,unique=False,null=True, related_name='%(class)s_user_create') update_user = models.ForeignKey(User,unique=False,null=True, related_name='%(class)s_user_update') and I would like to list all...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598524", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: GORM Mapping Manifesto :: To Long or not to Long Fairly basic problem but it's roots run deep in the framework (and there is little definitive information on the subject), so I am putting it out here so as to save others the pain (and to verify that I am correct or not in my thinking). What is the problem? Grails au...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598526", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: SsrsMsbuildTasks - Report image added using AddResource tasks renders as broken link in the report I'm using the following to add images during report deployment. The images are uploaded, and are valid (you can display them in the browser), but they are rendered as broken links in the reports. <Target Name="AddResou...
{ "language": "en", "url": "https://stackoverflow.com/questions/7598532", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }