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
2,567,752
2,567,753
Pagination: make current page bold
<p>The following pagination works but does not make the current page, bold and unclickable (no href)</p> <p>Whats wrong?</p> <pre><code>$totalcount = mysql_query("SELECT COUNT(*) as 'total' FROM $table"); $row = mysql_fetch_assoc($totalcount); $pages = ceil($row['total'] / $perpage); for ($i = 1; $i &lt;= $pag...
php
[2]
1,875,251
1,875,252
Android: using framework drawables in custom button selector
<p>I'd need to create custom button, but I'd want to use framework's default button highlight colors for pressed and focused states. My question is similar to <a href="http://stackoverflow.com/questions/3686430/android-use-default-highlight-colors-in-a-custom-button">this one</a>.</p> <p>My selector code looks like th...
android
[4]
2,855,934
2,855,935
Spinner data sorting in Android
<p>I have spinner with array list thats work fine, but i want to sort out the datas from a to z (example: apple,ball,cat,dog...)order. I submit my code below </p> <pre><code> ArrayList&lt;String&gt; SourceArray = new ArrayList&lt;String&gt;(); Spinner Sourcespinner;// = new Spinner(this); Sourcespinner = (S...
android
[4]
4,456,006
4,456,007
How to play video after onClick on "Show Video" button?
<p>Can someone tell me what is the specific code i should add into my current codes to play the video?</p> <pre><code>public class ViewVideo extends Activity { private String filename; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); ...
android
[4]
671,915
671,916
Sharing a bitmap image
<p>In my app I want to get the encrypted image from a folder and display it in a gallery, when I click on the image I want to send the decrypted image, I am using the code for sharing the image is.</p> <pre><code> boolean share = false; share = true; if (share) { try { ...
android
[4]
760,455
760,456
Addin a Button on keylock screen ANDROID
<p>For my application., I must add a button to start my appl. on key lock screen between unlock button.How can I do this? Thanks</p>
android
[4]
3,152,415
3,152,416
How can i send latitude and longitude every 15 minute to php web service?
<p>I am new to android. I want to send latitude and longitude every 15 minute to web service .Ho can i do this? How can i use Alarm Manager to send data every 15 minute? </p> <p></p>
android
[4]
1,061,274
1,061,275
Shortcut for a = b + a;
<p>So I've realised that <code>a += b;</code> is actually <code>a = a + b;</code>. (Try replacing <code>a</code>, <code>b</code> with strings.)</p> <p>Is there a shortcut for <code>a = b + a;</code>? I've tried <code>a =+ b;</code> but that doesn't seem to work.</p>
javascript
[3]
1,805,971
1,805,972
Copy selected option value to another text box but just for some options
<p>HTML excerpt </p> <pre><code>Selection: &lt;select name="no_exam" id="no_exam"&gt; &lt;option value="" selected="selected"&gt;===select option===&lt;/option&gt; &lt;option value="A+"&gt;100-75&lt;/option&gt; &lt;option value="B+"&gt;50-74&lt;/option&gt; &lt;option value="C+"&gt;0-49&lt;/option&gt...
jquery
[5]
3,755,288
3,755,289
Jquery count characters
<p>I'm having problems to figure out why jquery string counter won't show me the expected result.</p> <pre><code>&lt;html&gt; &lt;head&gt; &lt;meta http-equiv="Content-Type" content="text/html; charset=UTF-8"&gt; &lt;script src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"&gt;&lt;/script&gt; &lt;sc...
jquery
[5]
3,765,800
3,765,801
github API, fork a repo
<p>I'm trying to use the github API with python, but got stuck when wanting to fork a repo. My script so far is:</p> <pre><code>#!/usr/bin/python import json import getpass from restkit import Resource, BasicAuth, request from socketpool import ConnectionPool user= raw_input( "Github user:" ) password=getpass.getpas...
python
[7]
2,108,813
2,108,814
Android merge two images
<p>I have these two images, which I basically merge on canvas. Now i want to save that canvas into an image. How should i do it or if there is any other way to merge two images.</p> <p>My sample code is - </p> <pre><code> Bitmap bmp1 = BitmapFactory.decodeResource(getResources(), R.drawabl...
android
[4]
3,510,629
3,510,630
How to Close a Form on Button Click?
<p>How to close a form on the click event of button? I have used the <code>Close()</code> function but it's not working.</p>
c#
[0]
4,316,059
4,316,060
Python: Why would float.__new__(cls) work when cls isn't float?
<p>I'm a little confused by the following example from the python documentation <a href="http://www.python.org/download/releases/2.2/descrintro/#__new__" rel="nofollow">here</a>.</p> <pre><code>&gt;&gt;&gt; class inch(float): ... "Convert from inch to meter" ... def __new__(cls, arg=0.0): ... return fl...
python
[7]
233,555
233,556
What is the difference between session variables & Global variables in php?
<p>What is the difference between session &amp; Global variables in php?</p>
php
[2]
2,984,687
2,984,688
How to append new columns on the side not the bottom
<p>I made a python script that takes a file with a lot of columns and extract and copy (into a new file) the two columns that I need. However, once or twice a month I will need to add additional columns to the same (new) file, but I need to add them to the side of the current columns, not to the bottom. how can I modif...
python
[7]
3,360,330
3,360,331
Is Portable C# Express Edition available?
<p>I have heard of Portable Editions of Visual C# Express Edition (2005 or 2008)</p> <p>Are any of them available?</p>
c#
[0]
4,387,907
4,387,908
HumaneJs notifications bound to DIV
<p>I am using HumaneJs <a href="http://wavded.github.com/humane-js/" rel="nofollow">http://wavded.github.com/humane-js/</a> to display notifications. Everything is working well except that I cant seem to specify a DIV where my notifications should appear. The discussion in this link <a href="https://github.com/wavded/h...
javascript
[3]
2,749,434
2,749,435
Python mutable default argument: Why?
<p>I know that default arguments are created at the function initialisation time and not every time the function is called. See the following code:</p> <pre><code>def ook (item, lst=[]): lst.append(item) print 'ook', lst def eek (item, lst=None): if lst is None: lst = [] lst.append(item) print 'e...
python
[7]
5,949,006
5,949,007
How to overlap two Views which are located one below another?
<p>I have two <code>View</code>s which reside one below another and I need to slightly overlap their edges so the bottom one was slightly under the top one.</p>
android
[4]
4,351,723
4,351,724
jQuery --> click = get (any) element ID --> PROBLEM: returns ID of container div
<p><strong>I prepared a demo</strong> <a href="http://jsbin.com/udeha4/11/edit" rel="nofollow">HERE</a></p> <p>My problem: I'm trying to get the ID of the clicked element. It returns always the ID of the element that CONTAINS other elements: the 'first' DIV.</p> <p>Interesting that if I add the <code>alert(...)</code...
jquery
[5]
4,680,864
4,680,865
Interactive drawings in webapp
<p><br> For a web app I am designing, looking for a graphics library (java script based or not) to display in the browser. The application requires to map a production layout, so may only need to draw shapes (rectangles, cubes etc) and interactively modify the size of them. Any suggestion would be helpful. I am aware ...
javascript
[3]
2,360,840
2,360,841
python Home work
<blockquote> <ol> <li>define a string </li> <li>define string's len </li> <li>print true if the string len is even and the right half identical to the left half, else - print false.</li> </ol> </blockquote> <p>I need to do it only in 3 lines and it has to work for every string len without change the conditio...
python
[7]
941,362
941,363
how to genarate Json for jsTree
<p>i found yestarday the jsTree plugin, it's great. Have sombody a SQL sample to create the json for it?</p>
jquery
[5]
2,302,119
2,302,120
How to cast a ReadOnlyCollection<T> to T[]?
<p>I have a class with a ReadOnlyCollection property. I need to convert that ReadOnlyCollection into a int[]. How can this be done? Is it possible to do this without iterating over the collection?</p>
c#
[0]
870,828
870,829
Are escape sequences and escape characters the same thing in PHP?
<p>I was wondering if escape sequences and escape characters the same thing in PHP?</p>
php
[2]
5,566,537
5,566,538
Create one php variable from several
<p>Basic question but I've searched and can't quite get this nailed - how can I create 1 variable from several others? I then want to get that into an array.</p> <p>Something like this (obviously the syntax is wrong!):</p> <pre><code>$name; $address; $post_code; $full_address = $name, $address, $post_code; $address[...
php
[2]
798,790
798,791
Application Error:while retriving messages from MSMQ to application
<p>I am getting following error. This is related to HUB. I mean i am trying to retrive messages from MSMQ to application. But i am getting following error in that application log.</p> <p>Timestamp: 7/27/2012 12:35:26 PM<br> Message: Publish exception<br> Category: Service, Service<br> Priority: 5<br> EventId: 0<br> Se...
asp.net
[9]
585,247
585,248
how can i make my own map in iPhone ( not using google map)
<p>i've got the trouble when developing iPhone apps. i want to make my own mapkit, (include annotation, title, and subtitle) with my own map too, i mean without using google map, i have my own map. it's possible to doing like that.??? if yes, how it could be.?? please someone explain about it, i've been confused with t...
iphone
[8]
117,780
117,781
Reg: Counter Variable in Thread
<p>I have a requirement that should assign a counter variable for each thread that gets invoked. But I am not getting the expected results, actually the counter is duplicating in the threads. I created a dummy table and a proc to insert the counter value into the table. Is there anyway that the code can be changed so t...
java
[1]
3,540,015
3,540,016
Site hacked, who wants to figure out what this encoded string says (ROT13, eval, base64_decode, and gzinflate used)?
<p>In several files, I found injected code in my PHP files. I attempted to Pastebin the code, but Pastebin actually wouldn't accept the code. I tried various Pastebin alternatives as well, none of them would accept the code as-is, not even StackOverflow.</p> <p>So what I've done is uploaded the to my own personal ser...
php
[2]
2,931,240
2,931,241
Cheapest way to copy an IEnumerable<T>?
<p>I've got an <code>IEnumerable&lt;T&gt;</code>, and I need a copy of it. Anything that implements <code>IEnumerable&lt;T&gt;</code> will do just fine. What's the cheapest way to copy it? <code>.ToArray()</code> maybe?</p>
c#
[0]
4,777,588
4,777,589
jquery get attribute value when property is not set
<p>I simply want to get the current value of a field's attribute.</p> <p>This field has a default value like:</p> <pre><code>&lt;input validation="defaultValue" /&gt; </code></pre> <p>When i want to get the validation attribute, i don't know if it has been updated before or if this is still the default value.</p> <...
jquery
[5]
4,993,902
4,993,903
Writing a library, what structure?
<p>I'm writting a library. Right now, I have everything written in a single .js file that goes like:</p> <pre><code>function doThis() {} var thisVar = 5; </code></pre> <p>I was not sure if that was right, so I considered:</p> <pre><code>function Lib() { this.doThis = function() {} this.thisVar = 5; } var lib = ...
javascript
[3]
4,295,590
4,295,591
javascript appenchild
<pre><code> for(var i=0; i&lt;myJSONObject.model.length; i++){ var create_div = document.createElement('div'); create_div.id = 'model_id'+i; create_div.innerHTML = myJSONObject.model[i].model_name; var assign_innerHTML = create_div.innerHTML; var create_anchor = docu...
javascript
[3]
1,179,161
1,179,162
Unable to get options of a widget control after save the control in file
<p>i am creating html controls in client side using jquery widgets, getting properties of html control through options. everything is fine but once i save the control in html file and try load options of that control is not possible. help me to get the options of saved controls using widget. </p>
jquery
[5]
2,015,890
2,015,891
C++ Error "expected initialiser before '[macroname]'"
<p>I'm trying to make a program run with the eclipse IDE but I get the above mentioned error.</p> <pre><code>#if defined(__cplusplus) || defined(c_plusplus) extern "C" { #endif tCRU_BUF_CHAIN_HEADER *CRU_BUF_Allocate_MsgBufChain ARG_LIST((UINT4 u4Size,UINT4 u4ValidOffsetValue)); [some more macros where this error co...
c++
[6]
4,566,965
4,566,966
how can access the database of wikipedia by using C#?
<p>i want to access the database of Wikipedia to get the information of any thing by using C#</p>
c#
[0]
5,426,673
5,426,674
mb_substr as a solution for � works sometimes
<p>Hihi,</p> <p>I used to get the symbol � at the end of a string which ended with special character...</p> <p>I found the solution by adding mb_ to the "substr" which become (mb_substr)</p> <p>It worked but every now and then it still appears and vanish in some cases if I refresh.</p> <p>It there a permanently fix...
php
[2]
4,501,008
4,501,009
Issue trying to bind rss feed to repeater
<p>I am trying to bind a datatable to a repeater. To do this, according to a code sample, I need to call dataview() when choosing the datasource property of the repeater and then write databind().</p> <p>When I do this, I still get the exception that the source to databind to is not derived from IDatasourceControl.</p...
asp.net
[9]
4,891,055
4,891,056
nsinputstream to string?
<p>Is there anyway to view the values in a nsinputstream such as converting it to a string?</p>
iphone
[8]
295,562
295,563
display same table data in multiple times on click of add button using javascript
<p>I am having 3 text boxes in a table if i click add button the same text boxes need to append in the same page using javascript.Please help me</p>
javascript
[3]
3,955,122
3,955,123
Sort items in datatable
<p>I have a datatable with one column that contain names.I want to load combobox with datatable such that names should be in alphabetic order for eg:first name starts with a. second name starts with b.How can i sort data in datatable.Can anybody help?</p>
c#
[0]
3,630,892
3,630,893
Using same XIB for new/edit action
<p>I am making an app which among other things has the oppertunity to add new items or edit(show) existing ones by tapping a row in the tableview. The "detailed" view will be the exactly the same on both actions however with the edit(show) view will ofcourse be in the state of whatever the user has chosen. So my questi...
iphone
[8]
876,245
876,246
Verify that clicks are coming from own website
<p>I have a file go.php on my website that tracks the clicks on certain links and I want to count only the clicks that are made on my website and not on other sites that copy that link (site.com/go.php?id=). I have tried with this code</p> <pre><code>if($_SERVER[HTTP_REFERER] &amp;&amp; !preg_match("/site\.com/", $_SE...
php
[2]
2,420,974
2,420,975
Want to create EPUBReader
<p>I am new in android. I have seen many pdf reader for android. Now I want to create a EPUBReader by Myself. I downloaded the epublibrary but still not getting that how to do that. Every help will be appreciated.</p> <p>Thanks </p>
android
[4]
1,457,431
1,457,432
How to get JComboBoxes that are high enough for touchscreen selection
<p>I have a touchscreen interface that I have adjusted the tab, button, and scrollsize but I am uncertain if it is possible to make JComboBox easier to select individual items. Is there someplace that I can find a list of all the UIManager attributes that can be changed with put?</p>
java
[1]
650,625
650,626
strlen on 2 strings
<p>if (strlen($title) &amp;&amp; strlen($message) > 3)</p> <p>This returns true if $title is over 3 chars, I only want it to return true if BOTH is. Whats the correct way? Tried a bunch. FNYS.</p> <p>Help please.</p>
php
[2]
5,031,468
5,031,469
Do Java listeners need to be removed? (In general)
<p>Imagine this sample java class:</p> <pre><code>class A { void addListener(Listener obj); void removeListener(Listener obj); } class B { private A a; B() { a = new A(); a.addListener(new Listener() { void listen() {} } } </code></pre> <p>Do I need to add a final...
java
[1]
2,131,922
2,131,923
controlling broadcast from activity
<p>I am doing an android application. In my project I am checking phonestates using broadcast receiver.Using the folowing code I am checking my phonestate.</p> <pre><code>@Override public void onReceive(Context context, Intent intent) { // TODO Auto-generated method stub Bundle bun=intent.getExtras(); if(b...
android
[4]
2,354,792
2,354,793
C# - Killing a process by a part of it's name
<p>I'm searching for how to do it in C#, like this :</p> <pre><code>foreach (Process proc in Process.GetProcessesByName("cheatengine-x86_64")) { proc.Kill(); } </code></pre> <p>I am using this statement, but there are different versions of the program, like just cheatengine or cheatengine-x86, I'd like to close a...
c#
[0]
4,463,083
4,463,084
unsetting a variable
<p>I have some code here wich looks as following:</p> <pre><code>if (isset($_SESSION['addToCart'])) { foreach ($_SESSION["addToCart"] as &amp;$value){ if ($value['titel'] == $titel){ $value['aantal'] = $aantal; if($value['aantal'] == 0){ unset($value); }...
php
[2]
2,259,675
2,259,676
Returning an XmlDocument from XPathNodeIterator
<p>I need some help in returning an XmlDocument object from XPathNodeIterator.</p> <p>Here is what I was trying to do:</p> <pre><code>public XmlDocument GetFilteredXML(XmlDocument baseXML, int codeID) { XPathNavigator nav = baseXML.CreateNavigator(); string xpath = /*some expression based on codeID*/; XPa...
c#
[0]
4,332,805
4,332,806
Can I give default value to parameters or optional parameters in C# functions?
<p>Can I give default parameters for C#?</p> <p>in C</p> <pre><code> void fun(int i=1) { printf("%d",i); } </code></pre> <p>We can give parameters default value? Is it possible in C#. If so, can we avoid overloading functions? Thanks in Advance </p> <p><strong>EDIT</strong></p> <p>Its always a bad practice t...
c#
[0]
5,693,269
5,693,270
Java - printing two dimensional array
<p>I have a [20][20] two dimensional array that I've manipulated. In a few words I am doing a turtle project with user inputting instructions like pen up = 0 and pen down = 1. When the pen is down the individual array location, for instance [3][4] is marked with a "1".</p> <p>The last step of my program is to print ou...
java
[1]
3,349,742
3,349,743
Android ListView with CheckBox and a selectable item
<p>I have seen plenty of samples which support a checkbox for each item in a list but this seems to be about as far as they go. My problem is that I have two lists of items which interact.</p> <p>The first list displays Method Statements - when the user select a method statement the second list displays a list of Ris...
android
[4]
3,122,033
3,122,034
javascript - get all anchor tags and compare them to an array
<p>I have been trying forever but it is just not working, how can I check the array of urls I got (<code>document.getElementsByTagName('a').href;</code>) to see if any of the websites are in another array?</p>
javascript
[3]
780,877
780,878
Can parentheses take arbitrary identifiers as arguments? C++
<p>For example, is</p> <pre><code>(const int)* someInt; </code></pre> <p>valid code?</p> <p>If so, is that statement different than</p> <pre><code>const int* someInt; </code></pre> <p>?</p>
c++
[6]
5,477,542
5,477,543
jQuery slide up/down on hover
<p>I need to do, div "change" wait for the end, slidedown the div "username" and started slideup and same on out hover</p> <p>demo: <a href="http://jsfiddle.net/2jHBQ/3/" rel="nofollow">http://jsfiddle.net/2jHBQ/3/</a></p> <pre><code> &lt;div id="avatar"&gt; &lt;div id="username"&gt;Madona&lt;/div&gt; ...
jquery
[5]
5,164,285
5,164,286
Difference between arguments and parameters in Java
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/156767/whats-the-difference-between-an-argument-and-a-parameter">What&#39;s the difference between an argument and a parameter?</a> </p> </blockquote> <p>I was going through some interview questions. I wasn't ab...
java
[1]
4,580,170
4,580,171
Copy & Paste, 2011 Edition
<p>How can I copy and paste text using JavaScript?</p> <p>Most of the methods I've found via Google don't seem to work with newer browsers/versions of Flash. Are there any methods that still work?</p>
javascript
[3]
5,351,891
5,351,892
Where to create singleton instance if I don't need this instance in my program?
<p>Assume I have some singleton that just need to be instantiated. In constructor it starts timer, and updates some model data each second.</p> <p>To execute singleton constructor I just need to reference it. I don't need resulting instance because I don't need to do anything with singleton it should exist during enti...
c#
[0]
1,530,617
1,530,618
PHP function, a little help
<p>I need a function which searches a dir for UP TO 5 files (only MAX 5 files in the dir). The files have the same names almost, an ID nr ending with <code>'_1'</code> for <code>file</code> 1, <code>'_2'</code> for <code>file 2</code> etc. It simply ends with a underscore, and then the file-nr. Example:</p> <pre><code...
php
[2]
4,298,988
4,298,989
how to generate sound program for capctha in php
<p>I am making API like recapctha.I am hanging to make coding for sounde system for this API.</p> <p>What is the concept behind to make this code? Id it possible to make this is javascript ?</p>
php
[2]
1,821,405
1,821,406
Why am I able to manipulate UI elements from a background thread?
<pre><code>@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); mTextView = (TextView) findViewById(R.id.text); new Thread(new Runnable() { @Override public void run() { mTextView.setText("Hello"); ...
android
[4]
2,630,586
2,630,587
ValidateRequest not working
<p><strong>Here's the scenario:</strong></p> <p>I've got a regular hyperlink on my .ascx. (no I have decided NOT to use an asp.net control) That hyperlink when clicked sends over the querystring an ID of an object to be deleted so in the code-behind of my page, I grab that and if it's there call a RemoveSomeItem meth...
asp.net
[9]
5,147,674
5,147,675
Which Array did value come from
<p>I have multiple arrays shown below.</p> <pre><code>&lt;?php $arrLayout = array( "section1" =&gt; array( "wXBMCLibrary" =&gt; array( "title" =&gt; "XBMC Library", "display" =&gt; "" ), "wRecentMovies" =&gt; array( "title" =&gt; "Recent Movies", ...
php
[2]
498,212
498,213
Android Keyevent injection requires system permissions
<p>hi i am using key event injection using window manager but when i tested this application it gives me error </p> <pre><code> 04-12 18:19:35.794: WARN/WindowManager(58): Permission denied: injecting key event from pid 6290 uid 10039 to window Window{45034880 com.android.launcher/com.android.launcher2...
android
[4]
20,619
20,620
jquery load function not working
<pre><code>function newPage(pagenum) { /* load page default from server - pass product name */ $('#data').html("&lt;div id='response'&gt;Loading.....&lt;/div&gt;").load( '/college/college_change.php', { product:'college', city:"&lt;?php echo $city ?&gt;", university:"&lt;?php echo $university ?&...
jquery
[5]
2,947,761
2,947,762
jQuery: event that tracks click in browser autocomplete
<p>I have a keyup event on an input. This event works fine for auto complete when you select a value and press enter. But it doesn't work when you click at an auto complete value.</p> <p>Is there an event that i can use in such case?</p> <p>I already tried the change one but it doesn't work.</p> <p>Thanks!</p> <p><...
jquery
[5]
5,335,061
5,335,062
How to access an integer named object
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/7443605/accessing-numerical-property-in-a-json-object">Accessing numerical property in a json object</a> </p> </blockquote> <p>Using the facebook graph api, i have returned the JSON:</p> <p>"message": "A3Media ...
javascript
[3]
1,879,343
1,879,344
Visual studio web
<p>How do I host a silverlight web application so other people can just go on the internet and type the URL address to access the application.</p> <p>Is it free?</p>
c#
[0]
152,131
152,132
how could I capture keyboard input and write it to file?
<p>I couldn't find any article that would help me. I want to make an application (console, winforms, wpf, really not important) that runs in the background (have it in startup or something) and writes to a file every key that is pressed (in any textbox or stuff like that). For example the computer starts and I open IE ...
c#
[0]
4,486,384
4,486,385
Providing EXTRA_AUTHORITIES when showing the ACTION_ADD_ACCOUNTS in order to show restricted account types to the user
<p>The description for EXTRA_AUTHORITIES in android.provider.Settings says :</p> <p>"This can be passed as an extra field in an Activity Intent with one or more syncable content provider's authorities as a String[]. This field is used by some intents to alter the behavior of the called activity.</p> <p>Example: The A...
android
[4]
2,515,485
2,515,486
jQuery: use of wrap() on <img> element
<p>html:</p> <pre><code>&lt;img src="http://webmuseum.mit.edu/mobiusicons/no_image.jpg" /&gt; </code></pre> <p>css:</p> <pre><code>div.border { border: 2px solid #ccc; width: 500px; height: 500px; } </code></pre> <p>js:</p> <pre><code>$("img").wrap('&lt;div class="border" /&gt;'); </code></pre> <p>This is my firs...
jquery
[5]
450,562
450,563
UIview while loading didFinishLaunchingWithOptions
<p>I have an application in which the didFinishLaunchingWithOptions of my app delegate register for push notifications. This registration is taking little time, so at launching the app. i need to wait with a blank screen till it register. This waiting time i need to show a "please wait..." message, how can i do this? I...
iphone
[8]
4,042,900
4,042,901
ListView column highest value
<p>I don't need to sort listView I only need to get highest value from column, all values in that column are numbers.It would be nice if I could cast it to <code>IEnumerable&lt;int&gt;</code> somehow then I could use LINQ.</p> <p><strong>Update</strong></p> <p>My existing code: DrawArray is array with random numbers...
c#
[0]
3,305,573
3,305,574
Strange javascript behavior of `map` in Firefox
<p>Here's some strange javascript behavior of the <code>map</code> function in Firefox.</p> <p>During an error condition of a web-app (when firebug pauses on the error) typing the following into Firebug console:</p> <pre><code>["a", "b", "c", "d"].map(function(val, i, arr) { return val + " " + i + " " + typeof ar...
javascript
[3]
1,425,709
1,425,710
What is a better way to save the items of the playlist?
<p>In my music player if you add songs to the playlist , program first creates a directory by the name of playlist and then a <code>.txt</code> file. In this file , it adds the path or name of the song added in the playlist.Each entry is on a new line.So if i create a playlist named "Ghazals" and add 100 songs into tha...
java
[1]
1,010,466
1,010,467
Test if a certain div is present in another
<p>This might be easy but i get a problem, </p> <p>How to test if the div comWF if present at least one time in comW ?</p> <p>eg :</p> <pre><code>&lt;div class="comW"&gt; &lt;div class="comWF"&gt;&lt;/div&gt; &lt;/div&gt; </code></pre> <p>if i make :</p> <pre><code>if($(".comWF").length&gt;=1)) doSomething; </c...
jquery
[5]
1,310,339
1,310,340
Dynamically add properties to a existing object
<p>I create the person object like this.</p> <p>Person person=new Person("Sam","Lewis") It has properties like this. person.Dob person.Address</p> <p>But now I want to add properties like this and set the values at the run time after creating the object. person.Age person.Sex</p> <p>How can I add those extra proper...
c#
[0]
2,853,961
2,853,962
Unsure of a Declaration in C++
<p>I am currently reading some C++ source code, and I came across this:</p> <pre><code> double **out; // ... lots of code here // allocate memory for output of each neuron out = new double*[num]; </code></pre> <p>Not entirely sure what it does, or what it means. Is it a pointer... is at an array?</p> <p>There i...
c++
[6]
4,185,613
4,185,614
how to modify Datagram raw TCP IP?
<p>I'm modifing a Datagram raw TCP IP, because I want to change the cookie of a web page, when I modified the datagram the browser hangs, So I think that could be, maybe because I´m not updating all TCP IP necessary Headers, I updated the PAYLOAD SIZE, IP Total length, IP Checksum, I dont see if I need change another o...
c++
[6]
2,323,634
2,323,635
How to convert hashmap to json object in java
<p>How to convert or cast hashmap to json object in java and again convert json object to json string can anybody tell how to do?</p> <p>Thanks in Advance</p>
java
[1]
2,170,517
2,170,518
how to make live video streaming and some controlls on it
<p>I have developed a php website for an e-learning system, l want to stream live sessions on it so only my users can access and show it, in addition, I want to control how many minutes can users watch the video depend on there balance (for example if user has one dollar in his balance he can watch 10 minutes of a vide...
php
[2]
1,186,620
1,186,621
How to access a variable state from before an ajax request in the call back function
<p>EG</p> <pre><code>for(i in an_object){ $.getJSON("http//www...." + "?callback=?",'', function(data){ // do something using what the value of i from when the JSONP request was sent // but i is always the last value in an_object because the loop // has finishe...
javascript
[3]
4,999,768
4,999,769
How to make ActionBar tabs always display narrow mode on tablets (In portrait mode)?
<p>I have an application that I am supporting for both tablets and mobile devices that both use a tabbed design (using ActionBar tabs). On my mobile device the tabs work fine, however on my tablet the tabs get automatically put into the ActionBar. The devices are only in portrait mode, I am not supporting landscape. ...
android
[4]
5,173,400
5,173,401
Is it possible to build application using Javascript on Linux platforms?
<p>Javascript is widely used to create apps in the web. How about desktop, etc? Gnome Shell is made of it. I'm just curious if there's a way or something which allows devs to access Gnome/Clutter graphics libraries? </p>
javascript
[3]
385,502
385,503
how to start and stop sensor android
<p>I am working on the sensor action in iphone and I was wondering if anyone would know how to implement the start and stop sensor actions in android. I have searched this forum but not been able to find something definitive. Does anyone have and clues?Maybe an example I could look at?</p>
android
[4]
4,355,866
4,355,867
How can I find which element was clicked
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/7130232/javascript-find-out-which-element-was-clicked-without-attaching-any-eventlisten">Javascript: Find out which element was clicked without attaching any eventlistener to it?</a> </p> </blockquote> <p>If I h...
jquery
[5]
5,712,528
5,712,529
jQuery set var where n is ID for tabindex order?
<p>How to combine the two scripts below, into one, with the goal to get a script to generate a tabindex order feature for input/select fields in a form (where 1, 7, 3 are ID (#) of fields)?</p> <pre><code>$(function(){ var tabindex = 1; $('input,select').each(function() { if (this.type != "hidden") { var $...
jquery
[5]
3,377,847
3,377,848
Block sending sms in android
<p>Hi i've found many related threads , but no one has given answer ... can any one help me out in finding the way to <strong>block the outgoing sms</strong> </p>
android
[4]
2,027,146
2,027,147
What should I install in order to be able to use GTK in Python on Ubuntu?
<p>In my source code I have:</p> <pre><code>import gtk </code></pre> <p>But when I run the script with python3 script.py command I get the following error. What package should I install to get it working?</p> <p>Edit: my bad. here is the error:</p> <pre><code>ImportError: No module named gtk </code></pre> <p>Edit2...
python
[7]
2,065,351
2,065,352
cut html content and keep the format?
<pre><code>$str = "&lt;div&gt;blahblahblah&lt;b&gt;foofoo&lt;/b&gt;&lt;i&gt;barbar&lt;/i&gt;&lt;/div&gt;"; </code></pre> <p>I separate two part </p> <pre><code>1-presentation_text 2-full content when click on read more. $presentation = substr($str,0,23); &lt;div&gt;blahblahblah&lt;b&gt;foo $detail = substr($st...
php
[2]
695,295
695,296
how to use onlocationchanged method in locationlistener
<p>hello i'm pretty new to android.. i'm making an application which needs exact(approx 50m accuracy acceptable) user location.. i'm using locationmanager and locationlistener.. whenever i start the application i need user location returned. problem is that onlocationchanged method in locationlistener returns the latit...
android
[4]
3,652,628
3,652,629
Determine free ports
<p>I was looking at the API, and Ive tried to determine this:</p> <p>On a given port, check if it's available or already some application listens to it.</p> <p>Thanks,</p> <p>ray.</p>
android
[4]
4,683,167
4,683,168
Java Date conversion
<p>I want to convert this incoming date "962409600000" to date.I first tried to convert it to datetime format "2000-07-01T05:45:00.000+05:45" and then convert it to 2000-07-01.But I am successful to convert to datetime format.Please help me how ca I do that.</p> <p>Thanks </p>
java
[1]
1,272,451
1,272,452
Python book to learn
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/457757/what-is-the-best-python-book-for-experienced-programmers">What is the best Python book for experienced programmers?</a> </p> </blockquote> <p>I have seven years in programming with C and C++, and now I wa...
python
[7]
3,827,554
3,827,555
tracking download from Android Application
<p>I need to do following thing from my android application please give me idea to make it possible.</p> <p>I want to give the Google play link of client Application In my application, And when user will download the Application, We have to give some reward to user. </p> <p>Now problem is how My client will know that...
android
[4]
2,361,704
2,361,705
Sliding through divs at interval - jQuery
<p>I have a list of around 30 divs (see below.) and would like to hear any suggestions on the best way to rotate through them by sliding in one at the top and removing one from the bottom at a set time. Something like every 5-10 seconds. Also even though there are 30 on the page I would only like to show a list of 10 a...
jquery
[5]