text stringlengths 8 267k | meta dict |
|---|---|
Q: Why doesn't this Java enum code compile? enum itProfs {
private int sal;
DEVELOPER(30), ANALYST(20);
itProfs(int sal){
this.sal = sal;
}
public int getSal(){
return sal;
}
}
What is the reason?
A: You should put enumeration values first.
enum itProfs {
DEVELOPER(... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509324",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Regular expression to match everything between first occurrences of two words, both of which appear more than once I want to parse this json and pull out everything that appears between the first occurrence of the word feed and the first instance of the word widget_standard.
I figure that this should be easy enough ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509325",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: Repeat output x amount of times to the right and down I am almost on track here. I need to output if the user enters 5 or any number, the program should display the following:
xxxxx
xxxxx
xxxxx
xxxxx
xxxxx
5 to the right going down 5 times.
I have the right idea so far. But i am not sure how to specifiy it to repea... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509332",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Differences b/w Intent dispatch system and Foreground dispatch system Can anyone tell the differences between Foreground dispatch system and Intent dispatch system? when should i go for Foreground dispatch system?
A: The intent dispatch system is to launch a program from scratch. For instance, you turn your phone ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509340",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: document.write() and Ajax - Doesn't work, looking for an alternative I recently asked a question here, and received a great response (which I will shortly be accepting the most active answer of, barring better alternatives arise) but unfortunately it seems the of the two options suggested, neither will be compatible... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509341",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Performance tuning-Should i use loop or 'OR' to query a bunch of stuff For example, I have a table with 2 columns (int)id and (varchar)name. And I have 10 id to get each one's name.
Considering performance, Shall I query them one by one in a loop or query them with statement like WHERE ID= N OR ID= M... OR...?
A: Y... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509344",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Making a non-child div appear as a child div I want to place 2 divs on my page such it looks that the 2nd div is inside the 1st one. Also the 1st div should react to the growing size of 1st second.
But in the code they shouldn't have parent-child relationship(i.e, 2nd div not really inside the 1st div tags).
I don't... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509347",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to draw an oval speech bubble programmatically on iPhone? The technique shown in a similar question is a rectangular bubble. How to draw one in an oval shape? i.e.:
A: I would do it in two iterations.
First get the context and begin a path. Fill an ellipse and then a custom path that encloses a triangle wi... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509348",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "6"
} |
Q: IClassFactory failed due to the following error: 8001010a This is working fine with Visual Studio's server but when the server is changed to IIS, it throws:
Creating an instance of the COM component with CLSID {00020906-0000-0000-C000-000000000046} from the IClassFactory failed due to the following error: 8001010a.... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509349",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-1"
} |
Q: Need help with implementing Railscast 198 in Rails 3 I have been trying to implement Ryan Bates Railscast 198 into rails 3 for like 4 days... at least at night if you know what I mean. Anyway, here is the code I have right now:
User controller actions (Devise setup to show the different states of approved):
def ind... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509356",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: C# Mainform Button Navigation childform filled in panel mainform I have a main form with main panel and filling child form in the main panel.
I want some buttons in toolbar to navigate records based on Data Table created in the child form.
Problem is I do not know how to accomplish this.
Any code or guide to would ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509368",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to use cluster and node.js to run both an HTTP and HTTPS server So I have the following code in my app.js file:
http.createServer(function(request, response) {
// code
}).listen(80);
// var options = ...
https.createServer(options, function (request, response) {
// code
}).listen(443);
How do I use cl... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509372",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Maintaining state between pages in seam I have a xhtml page with Search criteria and search results. Clicking on search button will dynamically update the results on the same page. I have a controller for search/results xhtml in Page Scope.
There is an edit button in every record in the search results. Clicking on t... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509376",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: database for google type searches We need to be able to perform fast searches against 10 million tweets we have stored off. Any suggestions for a good database to use for this? We'd prefer to be able to do regular expressions searches but it's sufficient to be able to find all entries that contain a given word.
than... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509377",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Test email piping locally I'm using email piping to parse messages and handle them appropriately in my app.
I'd like to figure out a way to test this locally on my Macbook Pro. I use MAMP for development.
Any ideas how I can send an email to my local machine that gets piped to a script?
Thanks!
A: If the thing you ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509380",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Identifying sequences of repeated numbers in R I have a long time series where I need to identify and flag sequences of repeated values. Here's some data:
DATETIME WDIR
1 40360.04 22
2 40360.08 23
3 40360.12 126
4 40360.17 126
5 40360.21 126
6 40360.25 126
7 40360.29 25
8 40360.33 26
9 40360... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509381",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "10"
} |
Q: Insert image into SQL Server 2008 Express database without front end application I am working with test data in Visual Studio's server explorer. How would I put images into the database just as test images? I have no front end component built to take care of image uploading.
A: You can upload an image into a db (an... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509384",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Sweave doesn't seem to get .Rnw file encoding right This question arose out of the following question on tex.sx: Sweave generating invalid LaTeX. The problem seems to be that Sweave is not recognizing the encoding of the file, despite the locale being set to UTF-8, and the .Rnw file being saved as UTF-8. The end re... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509395",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: How to I make my custom mySQL query to in rails 3? Im trying to display recently added comments from tattoos a user has posted. So If I posted a tattoo, and then user_b posted "hey I like your tattoo" then Im trying to get just the comment.
First of all Im using the acts_as_commentable_with_threading gem which doesn... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509397",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: How do I get the arguments for any python method? Normally I would use inspect.getargspec, however how do I get the arguments of a method that has been bound?
Eg, how do I get the argument names for the method 'foo' as follows:
class Foo(object):
@memoized
def foo(self, arg1, arg2):
pass
Note that ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509400",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: how to optimize my sql query I want to optimize my sql query which i have written earlier (please see below attached sql query). This query is straight forward and very simple but this needs to be modified as it is failing at performance test, and I know the query is slow. My team lead did mention to me to use 'Pi... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509401",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Help with user defined sort function function sort_searches($a, $b)
{
return
(
(isset($b['Class_ID']) && !isset($a['Class_ID']))
||
($b['Results'] && !$a['Results'])
||
(is_array($a['Results']) && !$a['Results'] && !is_array($b['Results']))
);
}
I'm using this ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509403",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Rails helpers causing input placeholder to not work I have some jQuery in my app that removes/shows a placeholder depending on the presence of input in the input field. Here it is below:
$(document).ready(function() {
$('input').keyup(function() {
if ($(this).val().length) {
$('label[for='+$(... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509404",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Parse SQL field into multiple rows How can I take a SQL table that looks like this:
MemberNumber JoinDate Associate
1234 1/1/2011 A1 free A2 upgrade A31
5678 3/15/2011 A4
9012 5/10/2011 free
And output (using a view or writing to another table or whatever is easiest) th... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509406",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Using MediaPlayer and AVFoundation Framework simultaniously in XCode I'm an inexperienced XCode use and programmer in general so keep that in mind. I'm trying to use the microphone on the iPhone while at the same time allowing the user to play audio while using the "iPod music picker", but when the user selects m... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509409",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Why can you not throw and catch an Object in Java?
Possible Duplicate:
What can you throw in Java?
Why can't I take an Exception in a reference of Object.
I mean consider the following code:
try{.......}
catch(Object ex){.......}
It shows an error, where as we knows that it's possible for all the objects of any ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509410",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Is it possible to get the AM/PM from the date picker iphone Hi all im using a date picker and priting the time taken from picker in a label.It is working fine.and i want to print the AM/PM selected from picker.is it possible.Can anyone help me..Thanks in advance
I used the code below:
NSDateFormatter *dateFormatter ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509411",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Specifying DTD to be used by DocumentBuilders for XML parsing? I am currently writing a tool, using Java 1.6, that brings together a number of XML files. All of the files validate to the DocBook 4.5 DTD (I have checked this using xmllint and specifying the DocBook 4.5 DTD as the --dtdvalid parameter), but not all of... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509418",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Objective-C - Directly call method from array of objects I'm new to Objective C, and I'm trying to call a method on an array (NSArray) of objects directly like this:
[[myPeople objectAtIndex: 0] setName: @"Shane"];
But this doesn't seem to work, and returns a warning saying "Multiple methods named 'setName' found"
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509419",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Need help getting sbt 0.10 to choose a local copy of scala 2.9.1.final on Ubuntu What I have so far:
.bashrc
2 PATH=/opt/scala-2.9.1.final/bin:$PATH
3 PATH=/opt/sbt:$PATH
So my scala-2.9.1.final version is in the /opt folder. The same goes with sbt 0.10.
I'm trying to get it to pick my 2.9.1.final instead of 2.... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509422",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: String encodiing Conversation in JSON response I have a problem of string encoding. Actually I have a application, which is in 5 languages swedish, norwegian, english, finnish and danish. In one of section of my app, I get the review of user so it's possible to come in different language format like the word in swed... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509427",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Tab output behavior within a JTextArea I try to be as punctilious as possible in researching before I ask a question, especially one so simple, so bear with me.
I have a String that's tab delimited, and when I output it to a JTextArea in Java, I get behavior that looks like this:
FirstName LastName PhoneNumber ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509429",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Issue with Django template 'ifequal' The Below code:
{% ifequal username AnonymousUser %}
<p>Welcome</p>
{% else %}
<p> Welcome {{ username }}. Thanks for logging in.</p>
{% endifequal %}
Shows This:
Welcome AnonymousUser. Thanks for logging in.
What the? I'm more than a little miffed. I'm pretty sur... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509435",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-3"
} |
Q: Rails 3 Devise - Getting " No route matches "/users/sign_out" " No route matches "/users/sign_out" When I am logged in. I just followed ryan bates tutorial to get devise working. My rake routes looks like this.
new_user_session GET /users/sign_in(.:format) {:action=>"new", :controller=>"devise/sessio... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509437",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: C++: placing an array randomly inside a 2D array I am making a Battleships-like game and need to place a battleship objects into a battlemap array randomly. Except when I do this, the ships are never placed in the bottom right quadrant (but they are successfully placed in the other 3 quadrants), and I don't know why... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509438",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Why does the click function not work after I change the class of a button? I have a set of buttons(previous & next) that the user clicks.
<a id="prev_btn" class="prev_1" href="#">Previous</a>
<a id="next_btn" class="next_1" href="#">Next</a>
When the user clicks on the next button(.next_1), it changes the class nam... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509439",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: Ninject, binding un-bound types to methods I have an interface ISettings. Many classes will implement this interface. I want to be able to kernel.GetService(typeof(MySettings)) and have it call the type be created from a method.
I want to avoid using a type finder to pre-bind all ISettings implementations. I would l... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509442",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to add a b2Vec2 to a class I have a class that I want to contain a b2Vec2 and an integer. I keep getting an error that says expected specifier-qualifier-list before 'b2Vec2'. I can't figure this out. Please help.
@interface mTouch : NSObject {
b2Vec2 touchPoint;
int cannonNumber;
}
-(void)setTouchPoint:(b2... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509443",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Smalltalk runtime features absent on Objective-C? I don't know well Smalltalk, but I know some Objective-C. And I'm interested a lot in Smalltalk.
Their syntax are a lot different, but essential runtime structures (that means features) are very similar. And runtime features are supported by runtime.
I thought two la... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509449",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "5"
} |
Q: Running Javascript after an MVC Ajax..BeginForm partial postback I've got the following scenario using ASP.NET MVC2
I have a partial view that uses an Ajax.BeginForm to allow a partial postback, with the OnSuccess property of the AjaxOptions pointing to the js function onPartialReloadSuccess. The updateTargetId is h... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509454",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "5"
} |
Q: Deserialization of ArrayList GWT In my application I'm getting some data from a file located in the server. The data is stored in a text file (.obj), so I'm using an rpc to read the file and get the data. The file is read using a third party library http://www.pixelnerve.com/processing/libraries/objimport/ I'm sendi... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509457",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: GITHUB setup - no address associated with name I'm trying to setup GitHub on my system and I have done all the installation and key setup process:
But during test everything phase getting the following error by command:
$ ssh -T git@github.com
ssh:github.com:no address associated with name
A: It means it doesn't f... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509462",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "14"
} |
Q: How to move a subtree to another subtree in org-mode emacs I'd like to perform one simple task but there seems to be no clear solution for it:
I have a structure of subtrees like this:
* Tree A
** Subtree A1
** Subtree A2
* Tree B
** Subtree B1
** Subtree B2
I'd like to set up one key shortcut to move subtrees from... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509463",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "19"
} |
Q: update data based on another table I have a user table with following fields
id int
name varchar
dob date/time
Now, I have another table called user_map table, with 2 fields
oldid int
newid int
user_map table is used for storing user id mapping, field 'oldid' is user's old ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509467",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: EF4.1 Code first one to many self reference I'm trying to make a one to many self reference using EF4.1 code first. My entity looks like this
public class Site
{
public int Id { get; set; }
public int? ParentId { get; set; }
public string Sitename { get; set; }
public virtual Site ChildSite { get; s... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509468",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: Drawing maps in WPF I want to draw a map in WPF without using any third party controls.
I need each and every state of all the countries, and based on certain conditions I want to color them.
How can I get the polygon shapes of each state of all the countries?
A: Here is an SVG file with all the states as separate ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509471",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How to store user activities in mysql database? Consider a simple websites with lots of user activities (like stackoverflow). What is the best way to store user activities such as votes, adding to favorites, etc. To my knowledge there are two possible ways:
De-normalized: Storing user IDs of members who has voted fo... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509476",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: iPhone App to transfer message over bluetooth but device is not getting connected I am working on this iPhone app with which you can send message to other connected device. I have gone through following tutorial
http://vivianaranha.com/apple-gamekit-bluetooth-integration-tutorial/
Everything seems to be fine. No mem... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509479",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: System wide right click context hook **Hello..
i am creating English To Gujarati Dictionary WinForm Application.
I need to set a system wide hook to the right click context menu on for text selection.
it means when this application is running,and if user selects word from any program and right click ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509483",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Where is the best place to write the error to the log from? (BLL or ExceptionConstructor) I want to throw some custom exception and write it to the log.
What is the best practice in regards the correct place to write the log from: BLL, or the Exception constructor itself?
class TaskDataValidationFailedException : ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509484",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: pass an array in jquery via ajax to a c# webmethod I'd like to pass an array to a c# webmethod but don't have a good example to follow. Thanks for any assistance.
Here is what I have so far:
My array:
$(".jobRole").each(function (index) {
var jobRoleIndex = index;
var jobRoleID = $(this).attr('id');
va... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509485",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "4"
} |
Q: How to acess the WCF service if the is service is authenticated i am using the visual studio 2005 in that i want to get some methods from the WCF service.
i called the WCF service but i cant to able to access it because it is authenticated by the
client credentials so i am getting error as like "PERMISSION DENIED T... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509486",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How can I unregister my user from my application? I am using facebook C# SDK in my application and using Graph API. Everything is working fine. However, I didn't get how to unregister my users from my application meaning revoke the rights given to my application.
I didn't get how to do this using SDK. Any help would... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509490",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How to use form.submit with jQuery validate and overlay windows I have figured out how to submitHandler and do some tasks before submitting the form. Now I need to show a few overlay windows (jQuery Tools) and onClose, submit the form. But its not working, Im getting a ton of errors in Firebug.
Anyone have any ideas... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509495",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: System.Net.Browser.ClientHttpWebRequest.EndGetResponse throw System.ArgumentException when header contains non-ascii content I have a function that written in my Windows Phone 7 project. It is going to trace the content header of each HttpWebRequest and if the content-type is document(like a pdf attachment in Web ma... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509498",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: How to configure mod_deflate to serve gzipped assets prepared with assets:precompile When running the assets:precompile rake task, gzipped versions of your app's assets are created. According to the Rails guide for the asset pipeline, you can configure your web server (in my case Apache 2.2) to serve these precompre... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509501",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "11"
} |
Q: How can I create an Rx observable which stops publishing events when the last observer unsubscribes? I'll create an observable (through a variety of means) and return it to interested parties, but when they're done listening, I'd like to tear down the observable so it doesn't continue consuming resources. Another wa... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509503",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "6"
} |
Q: How do I line up input fields and their labels in a grid like manner with css? I'm trying to do something that must be relatively easy, but I've spent hours mucking around with this and I'm no getting to the answer.
I need to layout some input fields and their layers on a grid (or like a table I guess) with
lable ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509504",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: How to release a view when it's not visible in a tabbar controller? I have a simple app with a tabbar navigation interface.
It has three view (A, B and C) and a modal view. Each view has its own view controller and nib . They are all designed and connected in the interface builder.
I'd like to release views which ar... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509506",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Installing bluecloth - configuration options? I tried installing the bluecloth gem by typing
gem install bluecloth
But when I do that I get the following error message:
checking for random()... *** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of
necessary libraries and/or heade... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509507",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Encoding a binary tree to json I'm using the sqlalchemy to store a binary tree data in the db:
class Distributor(Base):
__tablename__ = "distributors"
id = Column(Integer, primary_key=True)
upline_id = Column(Integer, ForeignKey('distributors.id'))
left_id = Column(Integer, ForeignKey('distributors.... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509513",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: GWT designer size limitation I am designing a home page by using the GWT designer.But when I reached the height of more than 600 the images are not displayed.I have placed some images and run the application then it will show.But in the design mode it is not visible.Is there any such limitation in the size ?.I am un... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509514",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Reusing the main activity I have a main activity from where I will be switching from one activity to
another..So i don't want to re initialize every time..After the first time
of creation , the same activity should be called without having to create it
over and over again..how do I do this? #newbie-android
A: Wha... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509516",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Reloading a page inside of a with $_GET The following page loads inside of on my index.php. I initially call it using the following link: Import Mutuals
This part works dandy. The problem I'm having is with the refresh code at the bottom: var auto_refresh = setInterval(function(){\$('#import').show('fast').load... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509517",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-1"
} |
Q: MAMP Pro 2.0.3 doesn't work in OS-X Lion see https://superuser.com/q/338471/98725
When I start MAMP Pro 2.0.3 on Mac OS X Lion I get the following error:
Apache wasn't able to start. Please check log for more information.
When I look at the Console it says:
kernel: nstat_lookup_entry failed: 2
Anyone know what I ne... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509519",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Java pass by reference vs pass by value trouble why am i getting an error in the pass by reference example obj1.add200really is underlined
public class Test {
private int number;
Test(){
number = 1;
}
public static void main(String[] args) {
Test obj1 = new Test();
System.o... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509521",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Connection between windows service and sql database I am trying to establishing a connection between a Windows service written in C# and a SQL Server Express database. But when connection.open is called I get this exception
System.data.sqlClient.sqlexception:
{"Failed to generate a user instance of SQL Server due ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509522",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: How to package a Ruby application? I've got an application in Ruby that uses the Qt 4 bindings. I want to be able to package and release it.
I've looked at other applications such as rake and puppet to see how they're packaged. Both rake and puppet are packaged as gems. I started going down this route when I realiz... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509527",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "6"
} |
Q: does my opengl es draw(); call draw objects not currently seen on the screen? In Android. If im drawing objects off screen, it would be a big performance boost to disable these objects assuming they arent already disabled from being drawn when off screen.
A: I assume your question is how to cool the invisible objec... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509528",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: PHP - Zend Framework - Using static methods for data access I've been reading online about the pros and cons of using static methods for accessing data from the database. I have a LAMP based site built on Zend framework.
Some say in terms of performance - there is hardly any difference as quoted here by Greg Beech'... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509532",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Hook into the end of an asynchronous javascript call I'm calling a javascript function provided by a third-party. This function fires off a few ajax/asynchronous requests before returning, and (impolitely) neither allows me to pass a callback, nor returns any references to the asynchronous calls it is making.
Is th... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509534",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: How do I check the return value of an SQL query in PHP? So if I have the code:
$result = mysql_query("SELECT password FROM users WHERE username = '$username'");
$return = mysql_fetch_assoc($result);
I then want to check the returned value, namely, the value of "password". Therefore, I tried this:
if ($return['passw... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509535",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-1"
} |
Q: Apache Problem, phpinfo gives following arror Simply calling phpinfo(); gives the following info..
Fatal error: Using $this when not in object context in /var/www/phpinfo.php on line 2
It is a fresh Ubuntu + Apache install on Amazon EC2.
A: not possible, there has to be something else in the file.
<?php
phpinfo();... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509539",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Join tableA.column1 to tableB where tableA.column1 is between tableB.column2 and tableB.column3 I have two tables: user, zone
# user table
CREATE TABLE `customers_users` (
`userid` INT(10),
`username` VARCHAR(12),
`homePhone` VARCHAR(10)
)
# zone table
CREATE TABLE `zone` (
`id` INT(10),
`range_f... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509541",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Missing Integration Services option in SSMS I installed SQL Server 2008 R2 Express edition on a box that already had SQL Server 2008 Developer Edition installed in it.
Now Integration Services will not show up in the connect drop-down menu in the object explorer.
Any ideas why this is happening? Thanks.
A: 2 Possi... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509549",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "3"
} |
Q: dynamically resizable div jquery my Proplem is when i creat div use
var toprint= "<div id='any' class ="resizable sort">content</div> <div id='any2' class ="resizable darg">content</div> ";
then add to page use this code
$(ui.item).html(toprint);
it be sortable only not resizable too
$('.sort').sortable({
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509553",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "-1"
} |
Q: Canvas with Zoom Animation i am developing a small app in WPF and trying to set up an animation of zoom (using ZoomSlider) for a canvas but without good result ,do you have any suggestion how do a nice animation meantime is zooming the Canvas?
Thanks so much for your attention .
Cheers
A: Jossef Goldberg posted a V... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509556",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Binary addition/subtraction I am having a bit of trouble understanding Carry Flag (CF) and Overflow Flag (OF).
Here are some sample problems I am working on:
1. 1011 1111 2. 1111 0111 3. 0111 1110 --> 0111 1110
+ 1011 0111 + 1101 1101 - 1011 0000 --> + 0100 1111
___________ __________... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509559",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: BinarySearch - Replace a string element with another string element once found How do I make a binary search replace an element of an array of strings with another element of an array of strings? This is the final part of my program and I don't get it...I know with char's you use strcpy, or .replace, etc.
I have a ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509563",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: how can i break the line in JOptionpane message box
<script language="javascript">
<![CDATA[
importPackage(javax.swing);
importPackage(java.lang);
System.out.println("Hello from JavaScript!");
var optionPane = JOptionPane.showMessageDialog(null,'Deployment instruction = ' + Deployment_Instrution);
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509564",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Mysql Distinct function nested within other function in select Is there a way we can use disctinct for below cd.date_id? It's getting concatenated but I would also like distinct function aswell so it's like GROUP_CONCAT( CAST( distinct(cd.date_id) AS CHAR ) ) As date_id but it does not seem to work...
SELECT b.bar_i... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509566",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: rails devise plugin has created a users table. How can I add to it? I created the following with the devise rails plugin. How do I go about adding a username string and unique user_id integer to the users table? Also is it necessary to create a users_controller when using devise? Or is that not necessary?
class Dev... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509569",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Not able to import the another project as a library? I am going to licensing my Application. I know all the process for licensing application.
But for that I have to load the Library Project in My Workspace.
I have loaded the Library Project in my WorkSpace then i have imported it into my Original project. It works ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509570",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: alternative to php to perform data mining computation i'm working on a website that performs a lot of data mining and machine learning calculation thus very computationally expensive
i'm using zend framework, redis and mysql to build the website and so far everything works perfect because the traffic isnt that huge... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509572",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: string as parameter in a function i wrote a function to search if its parameter is in a given table obtab1.txt....the optab table has two columns out of which the parameter can only be in the first column....in the aviasm.h file i wrote this code....
class aviasm
{
public:
aviasm(char *,char *);
~aviasm();
... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509573",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Python IDLE won´t start I´m a noob in python and about a week ago IDLE stop working, I have readed some other people questions about this, but none of them had the same error that I´m getting, which is:
Traceback (most recent call last):
File "c:\python26\Lib\idlelib\idle.py", line 21, in <module>
idleli... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509579",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Creating a PowerShell Connection String I have been trying to create a ConnnectionString that will allow me to connect to my local database using PowerShell. Below is my code:
$conn = New-Object System.Data.SqlClient.SqlConnection
$conn.ConnectionString = "Server=localhost;Database=test;Uid=<username here>;Pwd=<pass... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509591",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: Creating a dialog in new thread Suppose if i create a thread using CreateThread, and I want a modal or modeless dialog in that thread. Do i need to use a seperate message loop for that like I have here,
while(GetMessage(&msg, 0, 0, 0)) // Get any window messages
{
TranslateMessage(&msg); // Translate the message... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509593",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: how does facebook push their changes to the live site From this video https://www.facebook.com/photo.php?v=778890205865 I understood that Facebook moves their changes to their live site on a daily basis.
Some changes are visible, whereas most of them are not visible to the end user. With a userbase of just over 700 ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509595",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Alternating Threads Could you point me in a direction for discovering how threads are being alternated in the Linux kernel?
A: Although I do not possess in depth knowledge about the kernel, but AFAIK to the kernel threads (& processes) appear as tasks. The switching between tasks is known as context switch. Conte... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509599",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: Dont remove(just hide) the previous data when ajax updated a page ? In case I have a need to revisit the previous data , while updating webpages through ajax is it advisable to keep caching the visited data in hidden tabs or hidden divs(instead of just replacing it with new data) so that when the user needs the same... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509600",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: jquery-ajax: pass values from a textfield to a php variable (same a file) jquery-ajax: pass values from a textfield to php file and show the value
i made a variation of the link above this time using only one file and no div tag.
test.php
<html>
<head>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/j... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509604",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Conversion of binary to octal or hex. Which one is easy (C language compiler) I was going through some questions related to C programming language. And i found this question to be confusing. http://www.indiabix.com/c-programming/bitwise-operators/discussion-495
The question is "is it easy for a c compiler to conver... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509612",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Q: MPMoviePlayerController bug or feature: Setting initialPlaybackTime to t seconds hides the time-slider upto t Say a movie is 10 min long and I am setting initialPlaybackTime to the 1 minute mark, like thus:
NSString *urlStr = @"http://<ip>/vod_movie.m3u8"; // 10 minute long video
MPMoviePlayerController* playerContr... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509618",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Gorm vs. Hibernate Mapping in Grails? I know that Gorm uses Hibernate under the covers to achieve what it does. As of yet I have not found a way to use the hibernate mapping strategy for inheritance with a per-table-subclass with Gorm and therefore I am not sure that I should use Gorm.
I want a base class for most ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509620",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "2"
} |
Q: how to modify Request.JSON to satisfy cross domain security I'm using mootools to request json from my web handler and this is working fine from the same machine. I've read in places about need for a callback to satisfy cross domain issues but unsure how to apply this. I'd like to run this code from another domain. ... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509623",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Function counting characters of a string class being skipped? I was trying to count the number of characters in a string class but for some reason the program is skipping over my function completely. This is just the test code from the main program, it still was giving me the same results. How come the counter funct... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509625",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: Access user's text messages on iphone Is there a way to access a user's text messages (without an internet connection, obviously...not trying to take the client's messages) and analyze the text within an app?
Totally understandable if there isn't (for security reasons), but I figured i'd ask anyway.
A: Nope, you ca... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509626",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: On Android, How do I display html in ListView? I am feeding a ListView from a database in this way (nothing special), except
COL_TXT_TRANSL2 contains html formatting:
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
Bundle extras = getIntent().getExtras();
mCurrBookI... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509627",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "1"
} |
Q: how to populate the state and city in my project without using AJAX and refresh page? I am looking a sample for the functionality where there are 2 drop downs. One is 1 is State/Province and the 2rd is City. Based on the state drop down selection, city drop down values should be populated.
I need sample database de... | {
"language": "en",
"url": "https://stackoverflow.com/questions/7509630",
"timestamp": "2023-03-29T00:00:00",
"source": "stackexchange",
"question_score": "0"
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.