Unnamed: 0
int64
65
6.03M
Id
int64
66
6.03M
Title
stringlengths
10
191
input
stringlengths
23
4.18k
output
stringclasses
10 values
Tag_Number
stringclasses
10 values
4,331,759
4,331,760
parse_str appending ampersand to elements?
<p>I've been playing around with cURL, and am trying to send an array through as POST variables. I've decided to use http_build_query to pass the string as expected: </p> <pre><code>curl_setopt($this-&gt;ch, CURLOPT_POSTFIELDS, http_build_query($sendParams)); </code></pre> <p>I have the receiving end simply <code>pri...
php
[2]
5,512,314
5,512,315
Can inetAddress be used with inet6/IPv6?
<p>Can inetAddress be used with inet6/IPv6?</p>
java
[1]
3,302,134
3,302,135
send parameters to given url from android using get method
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/13530030/how-to-send-parameters-to-given-url-from-android">how to send parameters to given url from android</a> </p> </blockquote> <p>Need to send parameters through a url to web server </p> <p>url ="http://ww...
android
[4]
3,053,308
3,053,309
makefile error for c++
<p>What is this error</p> <pre><code>:!make g++ -g -I../direc1 -I./ -c final.cpp make: g++: Command not found make: *** [final.o] Error 127 </code></pre> <p>?</p>
c++
[6]
1,038,570
1,038,571
returning code of function instead of result
<p>I saved a function created in jQuery in clean.js file..</p> <pre><code>jQuery.fn.singleDotHyphen = function(){ return this.each(function(){ var $this = $(this); $this.val(function(){ return $this.val() .replace(/\.{2,}/g, '.') .replace(/-{2,}/g, '-'); }); }); }; </cod...
jquery
[5]
1,441,952
1,441,953
Missing section declaration (system.web.extensions)
<p>I am encountering an issue wherein when I added the system.web.extensions on my web.config, I am getting the error saying, "Missing section declaration(system.web.extensions)".</p> <p>The main root of this issue comes from another issue, which says "System.InvalidOPerationException: Error during serialization or de...
asp.net
[9]
637,957
637,958
Equivalent is_file() function for URLs?
<p>What is the best way to check if a given url points to a valid file (i.e. not return a 404/301/etc.)? I've got a script that will load certain .js files on a page, but I need a way to verify each URL it receives points to a valid file.</p> <p>I'm still poking around the PHP manual to see which file functions (if an...
php
[2]
259,644
259,645
Which is better loading of images for ListView?
<p>I am wondering if which of the two is better in loading images in a listview from web, is it by batch through some number of threads that are running simultaneously or one by one through thread queue?</p> <p>I have noticed (but I don't know if that is really the implementation) from the youtube app that the images ...
android
[4]
3,135,699
3,135,700
Module API mismatch between PHP and SSH2 module
<p>I'm trying to install the ssh2 extension for PHP, and after hours of working on it, I've near figured it out. I think.</p> <p>It's compiled and the ssh2.so is in the correct directory and all. The problem, I believe, is version mismatches.</p> <p>Here's the error it's spouting for me:</p> <pre><code>PHP Warning: ...
php
[2]
4,530,432
4,530,433
how to set the softkeyboard to show german keys in android
<p>i have to make an application in german, and in one of the activities i have to searching.</p> <p>i have an edittext control for the same. but i want the user to input the text in german, how do set the softkeyboard to pop up with german keys?</p> <p>thank you in advance.</p> <p>EDIT: My application is using andr...
android
[4]
1,165,773
1,165,774
Internet Explorer innerHTML "Object doesn't support this property or method"
<p>I have a script that checks the value of a Div Id.</p> <pre><code> &lt;div id="hour" style="display:none;"&gt;2&lt;/div&gt; &lt;div id="min" style="display:none;"&gt;1&lt;/div&gt; &lt;div id="sec" style="display:none;"&gt;3&lt;/div&gt; hour = document.getElementById("hour").innerHTML; min = document....
javascript
[3]
1,186,302
1,186,303
forcing a variable to hold certain values only
<p>I am using vs 2012. I have a simple string property</p> <pre><code> string _someString; public string MyString { get { return _someString; } } </code></pre> <p>I want this property to hold only certain values. So that when the client uses this property only those certain values...
c#
[0]
1,899,999
1,900,000
How to do i need to implemnet paging for jquery grid
<p>I have a gird with user data around like 5000 users in the grid.. right now I am displaying all the users in the grid.. but I need to make it like only 500 user for page.. so i need to implement paging in the grid with previous and next buttong on the bottom of the page.. can any body tell me how to do this?</p> ...
jquery
[5]
912,710
912,711
Compare results of different php versions online
<p>There is a page where you can compare results of php code in different php versions but I just can't find it. Found it on Stackoverflow some time ago. It was nice because you did not select a version. It just runs the code in all versions and compares the output.</p> <p>Does someone know what page I am looking for?...
php
[2]
2,637,853
2,637,854
How to force a method to be overridden in java?
<p>newbie question.. I have to create a lot of very similar classes which have just one method different between them. So I figured creating abstract class would be a good way to achieve this. But the method I want to override (say, method foo()) has no default behavior. I don't want to keep any default implementation,...
java
[1]
1,714,124
1,714,125
jQuery -> Selected Element to HTML
<p>I am trying to wrap specific elements in a box if the visitor is using &lt; IE9 so I can apply a box shadow across all browsers.</p> <p>Unfortunately I cannot quite work out how to do it. Does anyone know how to convert the selected element back into HTML?</p> <pre><code>&lt;script&gt; $(document).ready(functi...
jquery
[5]
507,229
507,230
Best way to select n elements at a time in jQuery
<p>I have an <code>ul</code> of <code>li</code> elements, what I want to do is this:</p> <ol> <li>If there are 6 or less <code>li</code> elements, select them all and put them into a new <code>ul</code>.</li> <li>For any number greater than 6 elements, loop through, selecting 6 elements, put into new <code>ul</code>, ...
jquery
[5]
2,368,468
2,368,469
circularly linked list in python
<p>I am stuck implementing the add function of a circularly linked list in python. I have a head pointer that should be a reference to a node, but every time I add something to the list, head is always None. Here is the code I have so far:</p> <pre><code>class CircleList(): __slots__ = ('head', 'size') def _...
python
[7]
1,391,753
1,391,754
how to get indication of "success" from removeall
<p>i want to know if my function did remove from my list or not here is my code:</p> <pre><code> public int RemovePassenger(string name) { Passengers.RemoveAll(x =&gt; x.PassengerName == name); return //if the passenger actually been remove or not } </code></pre>
c#
[0]
4,585,184
4,585,185
function return two values
<p>I want to ask how effective is this function and if there are any situations when I can use it. Thanks for any answers.</p> <pre><code>function sum_and_dif(a, b) { var c = a + b; var d = a - b; return c +" " + d; } var result = sum_and_dif (200, 10); document.write(result +"&lt;/br&gt;"); var where_...
javascript
[3]
5,392,345
5,392,346
How do I append a page's URL to a social media 'sharing' URL in jQuery?
<p>How do I create a link that takes the static part of a 'sharing' link (of a social media site like LinkedIn) and appends the url of the current page? So that a user can share the page's URL on their social media account.</p> <p>I do not want to use Share This or any other such widgets.</p> <p>Thanks</p> <p><stron...
javascript
[3]
1,445,987
1,445,988
MS Studio 2008 plugin - Change icon in solution explorer
<p>I was exploring on the web but didn't find anything useful..</p> <p>I managed to read item's name but nothing more..</p>
c#
[0]
4,394,746
4,394,747
To pass values in a table as an array to javascript
<p>Is there a way that I could pass 5 values of a field from a table as an array to javascript function on onchange event of a dropdown box.</p> <p>The 5 values have to be fetched through sql query.</p>
javascript
[3]
951,248
951,249
Is there any way to check timer is runned at defined period?
<p>i developed an application which sends birthday wishes on facebook wall, but when i am calling someone at same time that i set for sending wishes, then wishes failed to post on facebook wall. I used Alarm Manager first. But i want to use timer class and in that timer class i want to check that message is posted to w...
android
[4]
3,125,032
3,125,033
The field that I set on an global array does not persist
<p>On my PHP web-page I have a global array:</p> <pre><code>$test = array(); </code></pre> <p>Then I invoke this function:</p> <pre><code>function f () { global $test; init( $test ); $test['foo'] // Error: undefined index "foo" } </code></pre> <p>which in turn invokes this function:</p> <pre><code>fu...
php
[2]
2,920,870
2,920,871
Animate a line drawn in CGContext
<p>Is there any way to animate a line or circle drawn using Core Graphics?</p> <p>Thanks in advance!!</p>
iphone
[8]
1,483,630
1,483,631
Change text color When something is Entered in text box
<p>i have form that has multiple input text boxes, Which has got some text message in light color. When User Types something That text should Become Dark. I got a jquery code which is working, but i cannot use that for multiple text boxes</p> <pre><code>&lt;html&gt; &lt;head&gt; &lt;script type="text/javas...
javascript
[3]
162,752
162,753
Getting content of a website via PHP
<p>How do I get the content of a page via PHP? How do i grab the text of a blog post because most RRS feed only give the link to the article so i cant use that. Is there a PHP function for this or anyway about doing this. Please offer some suggestions :).</p>
php
[2]
2,137,786
2,137,787
Jquery onClick but on Tab
<p>This code works fine when the user clicks a field. I want it so that when they tab (press the alt key) or ANY key.. no matter what happens, if this field is active, run this jQuery code. So far I only know .click()</p> <pre><code>jQuery(document).ready(function(){ $("#fullname").click(function(){ $("#no...
jquery
[5]
2,753,220
2,753,221
how to delete the dynamic uibutton
<p>Hello I have some codes to create dynamic button as below:</p> <pre><code>- (void)viewDidLoad { for (int i = 0; i &lt; 9; i++) for (int j = 0; j &lt; 8; j++) { forControlEvents:UIControlEventTouchDown]; UIButton *button = [UIButton buttonWithType:UIButtonTypeRoundedRect]; ...
iphone
[8]
4,849,256
4,849,257
Div left position change using animate function
<p>i have 3 div's &amp; one button</p> <pre><code>&lt;div id="Outer"&gt; &lt;div id="main" style='height:200px;width:300px'/&gt; &lt;div id="child" style='height:20px;'/&gt; &lt;/div&gt; </code></pre> <p>when some one will click on the button then child div left will be -20px and gradually its width will be increase ...
jquery
[5]
2,070,410
2,070,411
SP.ClientContext.get_current() returning undefined objects
<p>I am trying to get some information about the current context through the sharepoint javascript object model and am getting annoying errors.</p> <pre><code>$(document).ready(function () { ExecuteOrDelayUntilScriptLoaded(loadConstants, "sp.js"); }); function loadConstants() { var ctx = new SP.ClientContext.get_cur...
javascript
[3]
890,656
890,657
send sms programaticaly
<p>in my application i wan to send predefine smstext to one single number on certain event , it is possible to send sms like that! if yes please help me with sample code </p>
iphone
[8]
809,147
809,148
How can we custmize Check Box in Android?
<p>I want to display Check box like Radio button though is it possible to give our own shape to the check box if possible than help me please thanks</p>
android
[4]
102,232
102,233
How to build a single python file from multiple scripts
<p>I have a simple python script, which imports various other modules I've written (and so on). Due to my environment, my PYTHONPATH is quite long. I'm also using Python 2.4.</p> <p>What I need to do is somehow package up my script and all the dependencies that aren't part of the standard python, so that I can email...
python
[7]
5,020,463
5,020,464
What does delete[] do if given a pointer to the middle of an array?
<p>What would happen in the following code?</p> <pre><code> int *p1 = new int[100]; int *p2 = &amp;p1[50]; delete [] p2; </code></pre> <p>I've heard that some implementations of new store the size of the array in the (-1)th array index, but then wouldn't things go horribly wrong in the above?</p>
c++
[6]
2,563,295
2,563,296
Declaring 'long' over 'int' in Java
<p>In Java, if <code>int</code> is enough for a field, and if I use <code>long</code> for some reason, would that cost me more memory? Does that vary on types?</p>
java
[1]
1,717,948
1,717,949
Can't remove intent extra!
<p>I'm creating a notification for the notification tray. I'm specifying a click intent like this:</p> <pre><code>Intent intent = new Intent(context, MyActivity.class); intent.putExtra("foo", true); intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP); intent.addFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP); intent.setData(Uri.pa...
android
[4]
4,813,743
4,813,744
How do you stop reading integer from text file when encounter negative integer?
<p>Im trying to write a simple code in c++ to read in integer from a text file, the code should stop reading when it encounter a negative integer. The txt file contains 1 positive integer on each line, and the last line is a negative integer. </p> <p>My code right now using eof, and it reads in negative integer also, ...
c++
[6]
788,519
788,520
JavaScript Inheritance
<p>I am trying to implement inheritance in javascript. I came up with following minimal code to support it.</p> <pre><code>function Base(){ this.call = function(handler, args){ handler.call(this, args); } } Base.extend = function(child, parent){ parent.apply(child); child.base = new parent; ...
javascript
[3]
246,537
246,538
C++ how to write an operator that isn't a member function?
<p>Anyone got an idea on how to write an operator for a class that isn't a member function of the class?</p>
c++
[6]
3,043,857
3,043,858
How to merge the 3d transformed image?
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/12457047/how-to-merge-the-perspective-image3d-transform">How to merge the perspective image(3D Transform)?</a> </p> </blockquote> <p>How to merge the 3D transformed image with the background image? I am using th...
iphone
[8]
4,503,648
4,503,649
Java, declare variable with multiple interfaces?
<p>In Java, is it possible to declare a field/variable whose type is multiple interfaces? For example, I need to declare a <code>Map</code> that is also <code>Serializable</code>. I want to make sure the variable references a serializable map. The <code>Map</code> interface does not extend <code>Serializable</code>, bu...
java
[1]
1,288,762
1,288,763
Reverse a character array
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/1128985/c-reverse-array">C++ Reverse Array</a> </p> </blockquote> <p>How can I reverse a character array? Like this:</p> <pre><code>char word1[10] = "this"; char word2[10] = word1[10] // in reverse cout&lt;&l...
c++
[6]
885,417
885,418
Best way to use PHP to run another remote php script
<p>I am wanting to create a web-based cronjob system for my userbase, and would need to know the best way to open a php script on a remote server, and ensure the script runs (could take 3 minutes), and use the least ammount of resources on my own side. </p> <p>There is the possibility of having hundreds of connections...
php
[2]
4,157,991
4,157,992
Read response of HTTP POST sent from UIWebView
<p>Is it possible on IOS 5.1 sdk to read the response of an HTTP post sent from UiWebView in an iPHone app. So the user has browsed to a 3rd party site in the UIWebView and POSTED a form and the server responds to that. I need to know if it possible to intercept the response and then use the results in the app.</p> <p...
iphone
[8]
202,579
202,580
reference type size in java
<p>Why does a reference type in java take 8 bytes? Why not less or more than 8 bytes?</p>
java
[1]
2,289,568
2,289,569
Replace Symbols with jQuery
<p>Im looking for function that will allow me to remove (replace) all symbols in my body tag apart from a-z letter.</p> <p>Is there a simple way of doing this?</p> <p>Many thanks in advance.</p>
jquery
[5]
4,219,383
4,219,384
jquery error message place in div (jquery.validate.js)
<p>I have the following script which validates pages using jquery.validate.js through a quiz and works perfectly. Im looking to have the error message for required fields to be placed into a div called errormessage. jQuery validate usually returns a message "this field is required".</p> <p>Here is the script</p> <pr...
jquery
[5]
1,128,150
1,128,151
reading from stdin in c++
<p>i am trying to read from stdin using c++, using this code</p> <pre><code>#include &lt;iostream&gt; using namespace std; int main() { while(cin) { getline(cin, input_line); cout &lt;&lt; input_line &lt;&lt; endl; }; return 0; } </code></pre> <p>when i compile, i get this error..</p> <p...
c++
[6]
1,538,601
1,538,602
Why 1.-5 = -4.0
<pre><code>public static void main(String[] args){ System.out.println(1.-5); // -4.0 } </code></pre> <p>Can anyone explain why i got the above result, thanks in advance.</p>
java
[1]
4,945,518
4,945,519
How do I get OnSubmit to grab an external file?
<p>I have this </p> <pre><code> onsubmit="return validatePP(this); </code></pre> <p>I moved all of the validate function to an external file. How do I get it to call the external file?</p>
javascript
[3]
5,825,889
5,825,890
flash flyer image identification
<p>Hi Anyone know how can I access images from (adobe)flash flyer using PHP?.. let's say you have a weekly online flyer <a href="http://homedepot.shoplocal.com/homedepot/default.aspx?action=entryflash&amp;viewTaskName=ExternalDirectView&amp;categoryId=523472" rel="nofollow">http://homedepot.shoplocal.com/homedepot/defa...
php
[2]
4,051,595
4,051,596
os.walk and read file, having some problems with walking the path
<p>Here is the entirety of my code, I am trying to debug it, but it seems like I can't do any reading of files while using os.walk. The problem is that without changing directories, I am hit with a error that 'out.csv' cannot be found, so i put in a chdir(), to move to that directory to read that file, but now it will...
python
[7]
715,384
715,385
Difference between == and === in JS
<blockquote> <p><strong>Possible Duplicates:</strong><br> <a href="http://stackoverflow.com/questions/523643/difference-between-and-in-javascript">Difference between == and === in JavaScript</a><br> <a href="http://stackoverflow.com/questions/359494/javascript-vs-does-it-matter-which-equal-operator-i-use">Javascr...
javascript
[3]
4,360,442
4,360,443
C# Outputting the reference of an Object
<p>in what way can I output the reference of an object in memory. Like:</p> <p>Console.WriteLine("Object at Memory Location " + object.Reference);</p> <p>thanks in advance, I need this to do some debugging.</p>
c#
[0]
3,693,317
3,693,318
How can empty JavaScript function actually do something?
<p>While trying to understand how a web server worked, I came accross this:</p> <pre><code>//myfile.js function donothing(){}; //myfile.html javascript:donothing(open('http://www.acme.com/whatever.jpg','','left=100, right=0, top=100, scrollbars=no, status=no, titlebar=no, resizable=no, toolbar=no, menubar=no, width=2...
javascript
[3]
4,800,400
4,800,401
how to run application on Samsung galaxy tab GT-P1000
<p>I just finished developing an application and i want to run and test it on Samsung Galaxy Tab GT-P1000. i followed the steps on this link. <a href="http://developer.android.com/guide/developing/device.html" rel="nofollow">http://developer.android.com/guide/developing/device.html</a></p> <p>and I turned on USB debu...
android
[4]
4,968,784
4,968,785
add image in treeView
<pre><code>TreeNode desktop = new TreeNode(); desktop.Text = "Desktop"; desktop.Tag = "Desktop"; Mycomputer.ImageIndex = 1; Mycomputer.SelectedImageIndex = 1; desktop.Nodes.Add(""); treeView1.Nodes.Add(desktop); TreeNode Mycomputer = new TreeNode("My Computer"); Mycomputer.ImageIndex = 1; Mycomputer.SelectedImageIndex...
c#
[0]
325,371
325,372
Stoping other services like receving call and media player when my application opens?
<p>When i open my application , i should not receive any phone call or sms i should stop the media player also. can any one tel me is there any API is available to disable and enable them again once after my application ends.please help me..</p> <p>Thanks RAM</p>
android
[4]
4,949,937
4,949,938
How to retrieve data from an object in a simple way?
<p>I have an object, which contains 2 name parameters - see the example below. I understand that to reach the data I need to loop through the object, but I feel this is too annoying. Is there a better way to get the data in simple way?</p> <pre><code>var obj = {[[[{name:'one'},{name:'two'}]]]}; $.each(obj,function(i,...
jquery
[5]
1,414,780
1,414,781
I need some help concerning using 2 jar files in Java
<p>Well I have 2 .jar files. The main jar file is the jar file for my whole project and the other .jar file being the MySql JDBC Connector.</p> <p>Well basically whats happening right now is that when I build the project I have the one main .jar file with everything but the MySql JDBC Connector .jar file is inside the...
java
[1]
1,371,547
1,371,548
Javascript calculation not correct
<p>i have a weird problem in my javascript, take a look at my code below:</p> <pre><code>dateParts = document.getElementById('date').value.split('/'); newDays = 14; year = dateParts[2]; month = parseInt(dateParts[1]) - 1; day = parseInt(dateParts[0]) + parseInt(newDays); alert(dateParts[0]+" + "+newDays+" = "+day); </...
javascript
[3]
429,185
429,186
Search a list of objects in Python
<p>I have a list of Item objects that have a date attribute. I also have a a single date I am grabbing from the database. </p> <p>I want to search through the list, find all of the list items that are greater than the date I have returned from the database. </p> <p>My list of Items objects has over a thousand obje...
python
[7]
379,139
379,140
What does Java do when we import packages multiple times in the same class?
<p>Try this piece of code. It compiles. </p> <pre><code>import java.io.*; import java.io.*; import java.io.*; import java.util.*; import java.util.*; import java.util.*; import javax.swing.*; import javax.swing.*; import javax.swing.*; public class ImportMultipleTimes { public static void main(String[] args) ...
java
[1]
2,934,872
2,934,873
Why is TYPE_ORIENTATION deprecated since API 8.0 ?
<p>Why is TYPE_ORIENTATION deprecated since API 8.0 for ANdroid? There's a cross in eclipse but the code runs perfectly fine. </p>
android
[4]
3,452,531
3,452,532
Handling events of HTML elements inserted by jQuery
<p>I currently have an anchor tag that, when clicked, appends another anchor tag to the DOM. This is all done via jQuery. I know what the "id" attribute of the anchor tag to be added will be. However, when I try the following code, it fails to handle the newly added anchor tag's click event:</p> <p>$("#id").click(fu...
jquery
[5]
5,078,238
5,078,239
JavaScript rewrite/replace text into href (link) on page
<p>I need simple JS code(pure JS,no frameworks) to rewrite piece of text into linked anchor(hyperlink) when visitor load page.</p> <p>Or to be more precise, something same like many advertising services using: - put JS on existing page - when JS is fired it connect to my servers, find some data and rewrites certain p...
javascript
[3]
1,170,509
1,170,510
problem in user location coordinate in mapview
<p>I am trying to find the user location coordinate from following code:</p> <pre><code>- (MKAnnotationView *)mapView:(MKMapView *)mapView viewForAnnotation:(id &lt;MKAnnotation&gt;)annotation { MKAnnotationView* newAnnotation = [[MKAnnotationView alloc] initWithAnnotation:annotation reuseIdentifier:@"annotation1...
iphone
[8]
5,694,972
5,694,973
No overload for 'pnlArr_Click' matches delegate 'System.EventHandler'
<p>Just starting out on C# and I keep getting stuck on this particular piece code (more precisely the <code>lblArr[i, j].Click += pnlArr_Click;</code> line):</p> <pre><code>public void CreateLabelArray(int height, int width, int nrofShips) { pnlBase.Controls.Clear(); lblArr = new Label[height, widt...
c#
[0]
5,983,941
5,983,942
Getting a category list to stay displayed on my drop down menu
<p>Everything works great here but What I'm trying to do is have the list under the Rock category stay displayed until you click on the blues category. I want the Rock category to start off being displayed until another category link is clicked on. Any help would be appreciated since i'm new to javascript. Here is my c...
javascript
[3]
3,430,079
3,430,080
Why blank(empty file) java do not not show any error?
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/2467723/what-happens-if-you-compile-an-empty-java-file">What happens if you compile an empty java file?</a> </p> </blockquote> <p>I tried to compile a blank file(.java file)hoping it will show an error.But Java ...
java
[1]
4,077,417
4,077,418
Application Crashes when annotation bubble clicked
<p>I am creating annotations from database. But when I click on annotation to show bubble application crashes. But when I hardcode the coordinates and create placemarks on map the bubbles popup successfully. below is the code I am fetching from database and loading annotations.</p> <p>-(void) mapView:(MKMapView *)imnM...
iphone
[8]
4,521,676
4,521,677
Android TextView update
<p>Hi I am trying to update a textview to notify the user when the GPS coordinates have been logged. My problem is that I need to access the location infomation from another class and I cannot directly edit the textview from anything apart from the onCreate class.</p> <p>here is my code:</p> <pre><code>public class L...
android
[4]
3,529,059
3,529,060
Java Grouping Images
<p>I'm working on a game and had someone propose a challenge for me that I am having trouble solving so I am now turning to the stack overflow community for some help. I am trying to create a game similar to Tanks. I currently have two images (the tank body and tank arm) that I move based on two lines of code. They cha...
java
[1]
1,853,859
1,853,860
Javascript: How to determine the screen height visible (i.e., removing the space occupied by the address bar etc)
<p>As asked in the question, how do I find out the screen space available for the webpage through javascript?</p>
javascript
[3]
885,404
885,405
click listeners for dynaically added imageview
<p>I have an activity in my app which displays rss feeds and next to each rss feed arrow image is attached.</p> <p>I am new to android any help will be appreciated.</p> <p>i shall explain what i am doing to display rss news ...</p> <p>i have a seperate dummy xml layout for a single rss.. i have set id for arrow imag...
android
[4]
1,154,670
1,154,671
How might a List<T> be reset?
<p>I have an object I create and stick in a collection:</p> <pre><code>public class Level { private string id; private List&lt;LevelTypes&gt; usableLevelTypes; // LevelTypes is an enum private List&lt;BlockTypes&gt; levelMapping; // BlockTypes is also an enum public Level(string id, List&lt;Lev...
c#
[0]
4,801,464
4,801,465
How to append some object arrays in C#?
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/1547252/how-do-i-concatenate-two-arrays-in-c">How do I concatenate two arrays in C#?</a> </p> </blockquote> <p>How do I append some object arrays into one big object array?</p> <p>For example, I have 3 elements...
c#
[0]
297,588
297,589
Best practices for creating an application which will be upgraded frequently - C++
<p>I am developing a portable C++ application and looking for some best practices in doing that. This application will have frequent updates and I need to build it in such a way that parts of program can be updated easily.</p> <ol> <li>For a frequently updating program, creating the program parts into libraries is the...
c++
[6]
979,720
979,721
Check whether a connection exists to a remote host using paramiko
<p>I'm using single object of <code>paramiko.SSHClient()</code> for executing a command on a remote machine. When I use <code>ssh.exec_command(cmd)</code>, and the connection to remote host is lost, <code>ssh.exec_command</code> hangs up.</p> <p>Is there a way to check for connection existence before <code>ssh.exec_co...
python
[7]
4,482,404
4,482,405
Javascript object is not function
<p>I'm new to Javascript and am confused about the error messages I get:</p> <p>I have the JavaScript Code:</p> <pre><code>function tile(x,y) { return ((worldw * y) + x); } alert(tile(5,5)); </code></pre> <p>But I get the error message in Chrome that "Object is not a function".</p> <p>How can I fix this and what d...
javascript
[3]
1,531,747
1,531,748
How to save images in a server path folder from iphone application?
<p>Right now I am saving the images in a photo album, but I want to save the images in some server path like that can be used in a website. How can I do this?</p>
iphone
[8]
4,981,339
4,981,340
android toast a Chinese message to user
<p>Basically I need to toast a message written in Chinese to user. However I don't know how to achieve such thing. Any solution that can help me?</p>
android
[4]
632,351
632,352
Are these really different functions? jQuery.extend()
<p>The jQuery documentation covers the function jQuery.extend()s twice, giving it different definitions. The first relates to extending the jQuery object itself: <a href="http://docs.jquery.com/Core/jQuery.extend#object" rel="nofollow">http://docs.jquery.com/Core/jQuery.extend#object</a>. The second relates to exten...
jquery
[5]
3,790,672
3,790,673
Style for PrefenceScreen
<p>I'd like to be able to customize the view of a <code>PreferenceScreen</code>, and so I'm interested in knowing how to set a style for it. </p>
android
[4]
1,035,142
1,035,143
Android - How to get the mobile nunber when not stored in the SIM card
<p>I want to get the mobile number related with a SIM card. But I know that some celular operators doesn't store the number into the SIM card.</p> <p>So use the code below will not return anything,</p> <pre><code>TelephonyManager tm = (TelephonyManager)this.getApplicationContext() ...
android
[4]
3,988,397
3,988,398
android.net.http.RequestQueue not found in andorid.jar
<p>I am developing Android Twitter application. I downloaded TwitterClient Demo deom net. But there is a class file "android.net.http.RequestQueue" that is not available in sDK component in android.jar. Please advise on the same.</p>
android
[4]
3,021,052
3,021,053
Optimization of UI (.xml files) and java codes in android
<p>when I am going to develop an android application. For better performance of my application what are necessary steps. In another word how to optimize my codes and .xml files, in best way. And what are steps to remember when I am going to use huge set of variables. </p> <p>Thank you!</p>
android
[4]
1,359,789
1,359,790
PHP exceptions thrown in error handler are not caught by exception handler
<p>I use the following function to set my own error handler and exception handler.</p> <pre><code>set_error_handler set_exception_handler </code></pre> <p>The error handler transforms errors to exception. (throws a new exception)</p> <p>But these exceptions are not caught by my own exception handler.</p> <p>error h...
php
[2]
4,304,210
4,304,211
HelloAndroid]emulator-5554 disconnected! Cancelling 'com.example.helloandroid.HelloAndroid activity launch'!
<p>I am new to Android. Follow the HelloAndroid Tutorials by use Eclipse. After run HelloAndroid, the AVD 'xian_avd2' lunched, but stop there, no " Hello, Android" displayed on AVD. Looks like Waiting for HOME ('android.process.acore') to be launched...</p> <p>Not know how to resolve this, please help. Thanks wang813...
android
[4]
1,432,010
1,432,011
ANDROID: on Notification received, I want to refresh the listView with the new data
<p>Ths activity it's call from TabActivity.</p> <p>And I want: if I receive new notification , I want to refresh the list of the current Activity.</p> <pre><code>public class TestListActivity extends ListActivity { @Override public void onCreate(Bundle savedInstanceState) { ListView lv = null; super.onCreate...
android
[4]
1,947,125
1,947,126
get the field names straight from the db table
<p>I’m building a database driven website using WAMP</p> <p>I have database with table called userinfo with the following field names DateTime DomainName ComputerName UserName NetworkSettings.</p> <p>And I have a PHP script with a HTML table</p> <pre><code>echo "&lt;div id='tableheading'&gt;\n"; echo "&lt;table...
php
[2]
5,127,574
5,127,575
How to calculate distance from cellID?
<p>I want to calculate distance using 2 cellID (i am getting cell id from GsmCellLocation class).</p> <p>Please help me.</p> <p>Thanks</p>
android
[4]
1,903,489
1,903,490
Learn about a javascript object
<p>I have an <code>[object Object]</code> being passed as an argument through a jQuery function and I want to learn more about it. I don't want to know anything about this specific situation (unless there is no solution) but how to replicate something like php's <code>var_dump()</code>.</p>
javascript
[3]
4,414,905
4,414,906
how to save multiple bitmap images to internal storage and read into a list activity
<p>How can i write a bitmap image to internal storage, (prefer if i can save the bit map in my Own Directory ex "/data/data/com.myapp/myfolder/img1.png") i need to save the multiple images into this directory.after saving multiple images to above directory i need to show the saved images in a list activity,</p> <p>Met...
android
[4]
3,783,898
3,783,899
Calling Javascript Factory Method
<p>I am learning Object Oriented Java Script. I have below code for Factory Method.</p> <pre><code>function Foo() { var value = 1; return { method: function() { return value; }, value:value } } Foo.prototype = { bar: function() {} }; new Foo(); Foo(); </code></pre> ...
javascript
[3]
4,862,116
4,862,117
For what argument is std::vector<void*>::reserve an O(1) time operation?
<p>I am interested in at least an approximate answer to:</p> <pre><code>int n; ... std::vector&lt;void*&gt; vectorOfPointers; vectorOfPointers.reserve(n); </code></pre> <p>For up to which number <strong>n</strong> does the above mentioned program run in <strong>O(1)</strong> ? </p> <p>Let us suppose that for a lapto...
c++
[6]
3,339,458
3,339,459
How do I convert "1.20E+07" to a float?
<p>I can't convert the text, "1.20E+07" to a float.</p> <p>I've tried:</p> <pre><code>info = CultureInfo.GetCultureInfo ("en-US"); float.TryParse ("1.20E+07", NumberStyles.AllowExponent, info, out cellValue); </code></pre>
c#
[0]
5,638,274
5,638,275
NSTimer to update label
<pre><code>self.timer = [NSTimer scheduledTimerWithTimeInterval:1 target:self selector:@selector(updateTimerDisplay) userInfo:nil repeats:YES]; [runLoop addTimer:self.timer forMode:NSRunLoopCommonModes]; </code></pre> <p>This code-snippet is copied from my viewDidLoad method, so it is runned from the main-thread. All ...
iphone
[8]