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
3,068,449
3,068,450
How can I make my one pop up window appear at regular intervals
<p>I have created a popup which appear only once, when a button is clicked. However, I need it to appear repeatedly randomly again and again while having to press the button only once. Please see the code below:</p> <p>Method to create the pop up window</p> <pre><code> public void onWindowFocusChanged(boolean hasF...
android
[4]
5,971,916
5,971,917
How do i change the value of an object from an inner method?
<p>I need to change the value of <code>newiconid[0]</code> to <code>arg2</code> from method <code>onItemSelected()</code>. And I need to use that value in <code>onClick()</code>. The following code does not work, it just keeps the value of <code>newiconid[0]</code> as <code>0</code>. How to accomplish this?</p> <pre><...
java
[1]
2,010,099
2,010,100
how to clone inner div using jquery <= 1.4
<p>I have a situation where i am trying to use contents inside a div as template to create controls dynamically. So to explain with example: I have created a div element BaseControl as follows that will act as a template for my controls that i am going to create when user clicks on button. Then newly cloned (div) will ...
jquery
[5]
809,196
809,197
What is the effect of using targetSDKVersion in Android
<p>This is an abstract from the Android docs regarding the targetSDKVersion attribute of the uses-sdk element in the AndroiManifes.xml file.</p> <blockquote> <p>With this attribute set, the application says that it is able to run on older versions (down to minSdkVersion), but was explicitly tested to work with t...
android
[4]
4,867,825
4,867,826
clean project Mechanism Android
<p>what is advantage or magic or mechanisum behind clean project?</p> <p>some time we implement code which are not effect in final output and we are clean <code>(: from: project Explorer &gt;&gt; clean :)</code> it and as per expected output are in front of us.some time R.java are also not take resource and as we c...
android
[4]
800,637
800,638
How can I assign null value to an array element?
<p>I am facing too small problem, could you give me idea how to solve that.</p> <pre><code>for(var j=cArray.length-1;j&gt;=0;j--) { if(cArray[j]=='.') { cArray[j]=''; break; } else{ cArray[j]=''; } } </code></pre> <p>I wrote this for loop in javascript.NULL value is not assigning to array element....
javascript
[3]
1,308,731
1,308,732
Check if textbox has value then disable form element
<p>If my textbox has text in it, I want to disable the drop down list. The textbox id is "newAccessPoint" and the drop down list id is "selectAccessPoint"</p> <p>Jqeury :</p> <pre><code>if ($.trim($('#newAccessPoint').val()).length() != 0) { $('#selectAccessPoint').attr('disabled', 'disabled'); } </code></pre> ...
jquery
[5]
1,605,483
1,605,484
How to find in a string like '{$formLocation}' the 'Location' part?
<p>I created a file <code>.tpl</code>, which contains strings like <code>{$formLocation}</code>, then I put the file content in a variable <code>$content</code>. I have to get what's between <code>{$form</code> and <code>}</code></p> <p>(ex. the '<code>Location</code>' part from the <code>{$formLocation}</code>, )....
php
[2]
4,003,246
4,003,247
How to decide what will be the target android version?
<p>I'm new in the android developing. I need to write some simple application - and i need to decide what will be the target version. I don't know how to decide this - because i want to support the most newer version with all the new abilities - but i also want to support the maximum devices ( there are few devices ...
android
[4]
4,676,895
4,676,896
How can I reduce power usage in a location-based Android application?
<p>How can I reduce the power usage in my application? What code can I use to implement this?</p>
android
[4]
913,025
913,026
Response.write line of code in button click event handler is executed on page load
<p>I have some javascript on an asp.net page code behind, but whenever the page loads, the code (response.write, and in an asp.net button click event handler), is fired.</p> <p>Is this a bug? I want to only fire that response.write line of code obviously when the button is clicked, not on the page's load. How could I ...
asp.net
[9]
901,602
901,603
Saving iPhone Data Persistently
<p>I am making a fitness app that will save your weight, reps, and sets performed for each exercise you perform. I will also use this to track the progress made using this data. Does anyone have any clue how to do so? I've made apps before, but never required the saving of persistent data. Any info would be much apprec...
iphone
[8]
391,725
391,726
building a custom url
<p>i am building a asp.net web page where i will provide two text boxes where user can enter the <code>id</code> and <code>link</code> and once the user click the button i will generate the below ur </p> <p>i have a ur like this</p> <pre><code>http://www.hostname.com/controller.aspx?id=123&amp;link=abc123 </code></pr...
asp.net
[9]
394,245
394,246
Gather all Python modules used into one folder?
<p>I don't think this has been asked before-I have a folder that has lots of different .py files. The script I've made only uses some-but some call others &amp; I don't know all the ones being used. Is there a program that will get everything needed to make that script run into one folder?</p> <p>Cheers!</p>
python
[7]
62,883
62,884
Retrieving a filename for an ALAsset
<p>How can the filename be extracted from an ALAsset?</p> <p>Is there a way to get this via the url or some other way?</p>
iphone
[8]
401,748
401,749
Posting a url containing an underscore (_)
<p>I am posting a url with params containg an underscore (_).</p> <p>sample: <code>http://sdsdsds_asasasahjhd.com/dsdsdsd/login.json?</code></p> <p>I am posting it like this:</p> <pre><code> HttpClient httpclient = new DefaultHttpClient(); HttpPost httppost = new HttpPost("http://sdsdsds_asasasahjhd.com/dsdsd...
android
[4]
803,817
803,818
JavaScript Scope Query?
<pre><code>var my_var = 3; function doIt() { console.log( my_var ); //why undefined? var my_var = 7; return ++my_var; } doIt(); // returns 8 as expected </code></pre> <p>Why my_var returns <em>undefined</em> instead global value (3)?</p>
javascript
[3]
2,445,747
2,445,748
Where can I create, update and store my iPhone backend
<p>I have found a lot of sites that can store my data but I also would like a web service that can run my three php files regularly to update the data in my database. I have these files because I need to get data from another source and make it more suitable for my needs and then I save them into JSON files which I lat...
iphone
[8]
3,451,042
3,451,043
Android: Changing the start voice recognition of PochetSphinix
<p>Following the guide on the official website: <a href="http://cmusphinx.sourceforge.net/2011/05/building-pocketsphinx-on-android/" rel="nofollow">http://cmusphinx.sourceforge.net/2011/05/building-pocketsphinx-on-android/</a></p> <p>I managed to install the example on my device.</p> <p>Now I'd like to change the fol...
android
[4]
2,834,688
2,834,689
Updating Datagridview values into database
<p>I am developing an forms application where user can get tables data from database into gridviewcontrol which is editable so that user can update some data in the grid and when user clicks update buttonon the form the updated datagrid values should update in database. User can update more column values at a time...
c#
[0]
5,619,027
5,619,028
PHP coding standards for user entered data
<p>Recently we are facing lot of problems with user entered data</p> <p>like</p> <ol> <li>They are using different languages</li> <li>entering special characters like " ' </li> </ol> <p>How to deal with all these, after one problem..we are facing another.</p> <p>OR, are there any coding standard or advanced tutoria...
php
[2]
5,488,061
5,488,062
Android API Level 8 App Install Location Feature
<p>Does this feature allow you to upload an APK larger than 25MB? For example a 32MB apk?</p>
android
[4]
3,961,206
3,961,207
List Client Side Printers
<p>How to list a client side printer in asp.net using c#?</p> <p>My code: This will list the printers connected to the server.</p> <pre><code>ManagementScope scope = new ManagementScope(@"\root\cimv2"); scope.Connect(); ManagementObjectSearcher searcher = new ManagementObjectSearcher("SELECT * FROM Win32_Printer"); f...
c#
[0]
3,663,863
3,663,864
Get Image Height and Width as integer values?
<p>I've tried to use the PHP function <a href="http://php.net/manual/en/function.getimagesize.php">getimagesize</a>, but I was unable to extract the image width and height as an integer value.</p> <p>How can I achieve this?</p>
php
[2]
748,435
748,436
Android, how to replace slashes in path
<p>i have an image path : <code>"UploadFile\\/UserProfile\\/Female.jpg"</code>. How to replace <code>"\\/"</code> with <code>"/"</code>? i have tried :</p> <ol> <li><code>replaceAll("\\/","/")</code></li> <li><code>replaceAll("\\\\/","/")</code></li> </ol> <p>Code:</p> <pre><code>adapter_profilepic = objUser.getProf...
android
[4]
3,690,566
3,690,567
How to convert XY cartesian coordinates to degreeMinuteSeconds
<p>I have input like X = 4030817.581,Y = -90561.787 , Z= 4925687.823 (Geo Cartesian Coordinate)</p> <p>I want to convert X,Y Values into degree minute seconds. </p> <p>Please provide me a java mathematical application for this conversion.</p>
java
[1]
5,923,116
5,923,117
call recorder in android
<p>hi everyone i m trying make call recorder application.i have seen similar app in android market. any help will be appreciated. Thanks in advance. </p>
android
[4]
3,559,477
3,559,478
C# - FindControl by ID and modify some properties
<p>I'm creating some checkbox's from codebehind (adding through Panel.Controls.Add()). My question is: How can i modify the values?</p> <p>I've already tried creating the control, use the method FindControl and them change some properties but with no sucess.</p> <pre><code> CheckBox c = new CheckBox(); c.FindControl...
c#
[0]
4,262,438
4,262,439
Jquery contains multiple values
<p>Im using Jquery datepicker and also a PhP calender in my webpage. I want to use the same javascript array as in the datepicker function in my PHP calender to change the class of the "not available" dates. jquery contains works fine for a single date, but is it possible to do the same with an array?</p> <p>Code that...
jquery
[5]
2,059,248
2,059,249
What can I do about a privacy url?
<p>I am trying to put my android app on the market and the last thing I need is a privacy url. The problem is I don't have a website. I just created this app as my first project ever. Is there something I can do to get around this? Can I use a blog site or a facebook page or twitter page? I would really not have to pay...
android
[4]
2,713,015
2,713,016
Get the index value of an array in php
<p>I have an array:</p> <pre><code>$list = array('string1', 'string2', 'string3'); </code></pre> <p>I want to get the index for a given value (i.e. <code>1</code> for <code>string2</code> and <code>2</code> for <code>string3</code>)</p> <p>All I want is the position of the strings in the array</p> <ul> <li>string1 ...
php
[2]
1,515,438
1,515,439
how to show text right align
<p>this is my code for text view which space from left but i want to left allign text how i do that? how much name is long its align from right</p> <pre><code>&lt;LinearLayout android:layout_width="fill_parent" android:layout_height="40dp" android:background="#000000" android:orientation="vertical" &gt...
android
[4]
2,763,309
2,763,310
How passing in x.ToString() into a method which is expecting an object type as opposed to just x prevent boxing?
<p>I have a method called <code>OutputToScreen(object o)</code> and it is defined as:</p> <pre><code>public void OutputToScreen(object o) { Console.WriteLine(o.ToString()); } </code></pre> <p>In my main calling method, if I do something like:</p> <pre><code>int x = 42; OutputToScreen(x); // x will be boxed into ...
c#
[0]
5,850,300
5,850,301
performSelectorInBackground causes memory leaks on iPhone
<p>Why does methods that run in the background using performSelectorInBackground create lot of memory leaks?</p> <p>Thanks.</p>
iphone
[8]
1,692,486
1,692,487
javascript div container width resize problem
<p>hej guys, I've got a problem trying to resize the width of a div container. I really don't know why it's not working... Thx for responding.</p> <p>here's the code: It really works with Google Chrome. But with IE or Firefox just won't work.</p> <pre><code>&lt;div id="div1" style="position:relative; background-color...
javascript
[3]
1,776,348
1,776,349
Why is 2 /// 2 is 2 in Javascript?
<p>Does anyone know why <code>2 /// 2</code> is <code>2</code> in Javascript? </p> <p>What is this behavior called? Is it documented somewhere? Thanks.</p>
javascript
[3]
1,633,020
1,633,021
Creating an EnumMap with a generic type Enum
<p>If I have a bunch of classes that all contain an Enum and EnumMap and I want to create a superclass for those classes.</p> <pre><code>public interface ColorEnum { } class ColorMarbles extends Toy { enum MARBLE implements ColorEnum { BLUE, GREEN } EnumMap&lt;MARBLE, String&gt; names = new EnumMap&lt...
java
[1]
85,234
85,235
Compress code for multiple events in javascript
<p>Can this be done in any better way or must i type "object.event = function" for all?</p> <pre><code>namn1.onfocus = clearField; foretag1.onfocus = clearField; telefon1.onfocus = clearField; hemsida1.onfocus = clearField; meddelande1.onfocus = clearField; namn2.onfocus = clearField; foretag2.onfocus = clearField; te...
javascript
[3]
2,492,915
2,492,916
Send a variable to a variable of a function?
<p>Let's say I have a function and one of the parameters is for the name of the target variable.. Would it be possible for me to send a variable to the function like this:</p> <pre><code>function otherfunction(input){ ... } function test {target) { var x = 1; target(x); } test(otherfunction); </code></pre> <p>The p...
javascript
[3]
678,296
678,297
how to get soft keypad to write email id in edittext in android
<p>I am using android:phoneNumber to open soft keypad to get phone number in android.I want to open keypad which contains all key required to write email id in edittext.So is there any solution for this(email) like phone number. Thank you</p>
android
[4]
2,309,779
2,309,780
How to add button dynamically in UIActionSheet in iphone
<p>i need to add button dynamically in UIActionSheet in iphone.Please help me.</p>
iphone
[8]
582,370
582,371
Is there a way to check the API compatibility of my app for lower levels?
<p>I'm developing an Android app which will target 2.1/2.2 devices, so I have my project set up to use the 2.2 SDK (API level 8), but allow for installation on devices with at least API level 7.</p> <p>The problem is that during my daily development, I'm not always paying close attention to which API level of the meth...
android
[4]
2,790,582
2,790,583
remove first 5 letters <?php echo basename(__FILE__, ".php"); ?>
<p>How do I remove the first 5 characters of the file name while using ether of these codes. I know virtually noting about php so just explain it in detail please.</p> <pre><code>&lt;?php echo basename(__FILE__, ".php"); ?&gt; </code></pre> <p>or</p> <pre><code> &lt;?= basename($_SERVER['PHP_SELF'],'.php')?&gt; </...
php
[2]
4,570,467
4,570,468
parent package class accessible from child packge class in java?
<p>In java parent package class accessible from child packge class? please explain me any one?</p> <p>example package A.A1.A2 contains class sub package A contains class sup</p> <p>Is there anyway to access sup from sub?</p> <p>pls explain.</p> <p>i tried import it won't work Example: before the program Directory S...
java
[1]
5,859,610
5,859,611
Memory leak when application loads in iPhone
<p>I have a navigation based template, when I run my application using Instruments, the very first memory leak comes under:</p> <pre><code>Leak Object: Malloc 128 bytes Responsible Library: CoreGraphics Responsible Frame: open_handle_to_dylib_path </code></pre> <p>I don't know where this leak is coming from and how...
iphone
[8]
5,755,556
5,755,557
dynamically add textbox and dropdownbox when click on plus symbol in asp.net?
<p>i need to add columns one by one in asp.net by click on plus symbol then one textbox and dropdown will appear dynamically and when click on minus that will disappear .</p> <p>whenever user enter the data in textbox and dropdown and clickon plus symbol the that row will save in db and new empty textbox and dropdow...
asp.net
[9]
4,087,439
4,087,440
removing last 3 characters on a file (file extension)
<p>my file name are being stored in a variable <strong>$file_name</strong>... how can i remove the extension and just have the name only? is there something other than strcmp that i can use... that doesn't seem to do it</p>
php
[2]
2,715,407
2,715,408
Select particular line in paragraph w/ jQuery
<p>Is it possible to select a specific line in a text paragraph with jQuery? I do not have any specific text in mind, so I don't know if REGEX would help, but let's say I have a text that wraps into 5 lines, can I add a class, for example to line number 3? </p> <p>I've seen fancier things done with jQuery, and do hope...
jquery
[5]
5,663,221
5,663,222
How to easily filter from csv with python?
<p>Assuming I have the following CSV file:</p> <pre><code>User ID Name Application 001 Ajohns ABI 002 Fjerry Central 900 Xknight RFC 300 JollK QDI 078 Demik Central </code></pre> <p>Is there some easy way to (import this into some data structure)? an...
python
[7]
1,917,880
1,917,881
Name an id dynamically with javascript?
<p>How can I dynamically name id's using javascript?</p> <p>Something like this:</p> <p>js:</p> <pre><code>var idName = "fruit"; </code></pre> <p>html:</p> <pre><code>&lt;img id="javascript:idName" src="banana.jpg"&gt; </code></pre>
javascript
[3]
1,260,367
1,260,368
android: alarm statusicon like the original alarm app?
<p>I am making a alarm app and was just wondering how do I show a alarm icon at the right side of the statusbar like the original alarm app? normal notifications appear in the left side and I cant find anything about this....</p>
android
[4]
4,772,043
4,772,044
C# working with php array
<p>I am using API which return some array with many items: </p> <pre><code>s:7:"members"; a:37: { i:0; a:7: { s:4:"h_id";s:4:"9352"; s:6:"h_name"; s:6:"Name"; s:7:"h_level"; s:2:"14"; s:8:"c_status"; ...
c#
[0]
917,387
917,388
To obtain the previous page's URL in php
<p>i have got 5 php pages which are question papers (MCQ's).</p> <p>the user is provided with 1 of the papers...which he answers and submits...it then goes to <strong>AnsCheck.php</strong> ...in AnsCheck.php i need to understand from which page i.e from which of the 5 papers the request was received so that i can proc...
php
[2]
4,669,129
4,669,130
Programmatically click views in android
<p>Is it possible to programmatically send click events to a view? if so, how?</p>
android
[4]
1,763,277
1,763,278
Creating a menubar with 3 options
<p>In C# windows form I am having main menu.Suppose it has 3 buttons/links. named Home,ContactUs, AboutUs.When i click on Home(contains of home should be display with the main menu in the same window) similar is case with ContactUs and AboutUs link. Can any one help me with the code project.</p> <pre><code>private voi...
c#
[0]
1,263,730
1,263,731
C#: how to check and display the content of a folder?
<p>I'm not sure whether this topics has been disscussed before or not, but I'm not sure the exact word to search for it. What method/class should I use?</p> <p>The program has 3 buttons: <strong>1) for folder browsing, 2) scan for the selected folder content, and 3) open the file.</strong> When user browse the select...
c#
[0]
5,056,636
5,056,637
Windows Application .. Not working
<p>Hi after I did this application using visual C# ... Simply nothing on the form is working its like disconnected any ideas why ?</p>
c#
[0]
237,856
237,857
java- timing the execution of a block of code
<p>hi i want a block of code(certain lines of a function) that will run for a stipulated amount of time (say x milliseconds).Is is possible to do this in java?</p>
java
[1]
3,803,586
3,803,587
How to get the range of particular text from a doc file using Word interop and C#
<p>I want to create a doc file and copy some of the content to another doc file using word interop and c# .e.g</p> <p>This is my doc file.I will paste only this part to another doc file. Rest of the text will remain here only.</p> <p>I just want to paste the text "I will paste only this part to another doc file.Rest ...
c#
[0]
2,203,160
2,203,161
Select value from database based on dropdownlist value
<p>I have database table <code>leave_rec(name,date1,leave,ltype)</code>, a <code>Dropdown list</code> and a <code>gridview</code>.</p> <p>I want to do such that,when I select month(e.g. february) in dropdown list the gridview should display all table values for february <code>only(e.g.rohan leuva,2/28/2013,full,casual...
c#
[0]
2,560,173
2,560,174
PHP Array Removing Matching Values
<p>I built this function in PHP so far called removeAllValuesMatching, but I cannot seem to get it working. I am passing in two parameters $arr and $value. Not sure why this is happening. Any help would be greatly appreciated. This is what I have so far:</p> <pre><code>&lt;?php $arr = array( 'a' =&gt; "one", 'b...
php
[2]
4,138,572
4,138,573
jQuery event that fires when page is displayed on a viewport
<p>Is there any event in jQuery that fire when page is displayed on viewport? I want to perform some action once the content of an iframe is displayed on a viewport.</p>
jquery
[5]
991,165
991,166
c# is it possible to show a live webpage in a windows form application?
<p>I was wondering if its possible to show a webpage inside of a windows form application. I'm trying to create a livechat client,but it seems to hard for a c# beginner,since I have to code the server side also. So I was wondering if it's possible to show a php page containing the chat client into a window of my applic...
c#
[0]
5,636,084
5,636,085
JavaScript broken DOM
<p>Can I somehow load a "broken" DOM tree in JavaScript</p> <p>for example if someone forget to close a tag..</p>
javascript
[3]
3,370,077
3,370,078
Return a string and integer using one method
<p>Im trying to write a program which has a method Exam mark This contains objects of pupil class and a string that gives the pupils name. The method should return the pupils exam mark and their name. if there is a pupil called joe and their exam score is 32 then when joe is passes 32 should be printed.</p> <p>In the...
java
[1]
3,943,361
3,943,362
Disable web.config inheritance?
<p>I have a content management application in the root of my website, and I'm trying to use a different app (a billing application) under a sub-folder. Unfortunately, the web.config of the root site is interfering with the sub-app.</p> <p>Is there a way to just disable web.config inheritance for a sub-folder?</p> <p>...
asp.net
[9]
5,823,180
5,823,181
update the datagridview combobox, throws "Operation is not valid because it results in a reentrant call to the SetCurrentCellAddressCore function."
<p>when i try to update the content of the datagridview combo box it throws Operation is not valid because it results in a reentrant call to the SetCurrentCellAddressCore function at line ,node.Cells[(int)Parameters.eColumn.valueBySelectionColumn] = cboCell;</p> <p>How can i solve this problem?? THX</p> <pre><code> ...
c#
[0]
2,453,271
2,453,272
List all NAS server present in LAN using C#
<p>I want to List all NAS server present in LAN using C#. Any idea or code snippet is highly appreciated. Thanks in Advance.</p>
c#
[0]
2,886,449
2,886,450
Convert plain string date into required format and difference between two dates
<p>I am getting date from XML but date is in plain string format. I would like to create the difference from today's date and time and the date and time which i am getting from xml. </p> <p>For example i am getting date as a plain string in this format (2012-10-17T08:15:19.500-05:00).Now when i am doing difference wit...
javascript
[3]
3,975,927
3,975,928
Textbook claims can use age=age instead of this.age = age in ctor, when is this correct?
<p>For this class,</p> <pre><code>class Person { int age; public Person(int age) { this.age = age; } } </code></pre> <p>In my textbook, the author tells me that it's also OK to write age=age to replace this.age=age.</p> <p>He says, if the parameter and the data member have the same name, the left...
java
[1]
2,052,372
2,052,373
edit uitextview
<p>I want to edit part of the text within the uitextview text (italic bold , ...............) , how to mix between bold and italics and at which formate can I save this eidtable text </p> <p>I mean how to save the text with this format in txt file </p>
iphone
[8]
1,394,201
1,394,202
Using subclass of Input Method Service
<p>I extended InputMethodService hoping to use this Service for showing a soft keyboard even though a hard keyboard is connected(based off the following post <a href="http://stackoverflow.com/questions/11602209/show-soft-keyboard-even-though-a-hardware-keyboard-is-connected">Show soft keyboard even though a hardware ke...
android
[4]
2,748,957
2,748,958
Cannot fire the event of a hyperlink using jquery
<p>I am working with MVC3 technology with AJAX and jQuery in ASP.Net. </p> <p>As per my requirements I have created a table dynamically. There is a hyperlink along with the each last <code>td</code> of each <code>tr</code>, like: <code>&lt;a href = "#"&gt;edit&lt;/a&gt;</code>. </p> <p>I have encapsulated the code of...
jquery
[5]
5,442,562
5,442,563
Script to run at completion of Page Loading
<p>On the home page I a have 2 lines of code I would like to run in JavaScript.</p> <p>Where should I put these two lines of code.</p> <p>Does WP have a specific way to do this. Or should I just pick the last .js file that loads and add it there?</p>
javascript
[3]
1,443,622
1,443,623
Displaying directory/file list without server-side scripting
<p>It would be best if I could do it through just JavaScript and HTML, but I'm open to other solutions as well. I have a html file in a folder with a number of subdirectories and am trying to get a list of those subdirectories as well as the files within them. This needs to be able to run without server-side scripting,...
javascript
[3]
2,857,675
2,857,676
How do I implement this?
<p>I found this script but I don't know if I'm making a mistake or if it has an error. What do I need to do to make it work? Do I need to link to any extra files or anything? I'm using php. Thanks</p> <pre><code>&lt;a href=”JavaScript:login(user, pass, 'http://www.example_login.com')"&gt; Protected Web Site &lt;/a&gt...
javascript
[3]
2,919,971
2,919,972
create listview programmatically with no xml layout
<p>I found this example to create a custom listview:</p> <pre><code>public class UsersListActivity extends ListActivity{ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); String[] statesList = {"listItem 1", "listItem 2"...
android
[4]
2,921,468
2,921,469
What happens when when the start value of a python substring command is negative?
<p>Example:</p> <pre><code>mystring = " ... some string ... " mystring[-50:40] # &lt;--- what does this mean? </code></pre>
python
[7]
5,537,585
5,537,586
Calculating the area of a circle using php function
<p>I need to create a function to calculae the area of a circle. The function should take in two arguments (a number and a string). The number should be the radius or diameter of the circle. The string should be the word "diameter". The function should return the area of the circle or a -1 for an error. Finally, the sc...
php
[2]
737,814
737,815
How to add/remove text in between string(statement) using js?
<p>How to add/remove text in between string(statement) using js?</p> <p>For example:</p> <pre><code>var string = "&lt;html&gt; &lt;/html&gt;" </code></pre> <p>Now, the string should contain </p> <pre><code>&lt;html&gt; &lt;body&gt; &lt;/body&gt; &lt;/html&gt; </code></pre>
javascript
[3]
247,709
247,710
Call Method from Main Java
<p>I'm trying to call a method, WriteToFile, from The main method. Here is what I have so far:</p> <pre><code>public void main(String [ ] args) { String fileLoc = Environment.getExternalStorageDirectory() + File.separator + "AccelData.txt"; File AccelData = new File(fileLoc); AccelData.WriteToFile(fileLo...
java
[1]
3,966,921
3,966,922
How to clone tr in table using jquery
<p>Have a lot of tables on the page. I want to add new row with existing data after some one <code>tr</code>. So I have one of the table:</p> <pre><code> &lt;table&gt; &lt;tr&gt; &lt;th&gt;...&lt;/th&gt; &lt;td&gt;...&lt;/td&gt; &lt;/tr&gt; &lt;/ta...
jquery
[5]
4,959,940
4,959,941
Develop Bi-directional Spinner in Android
<p>I need to create a Bi-directional spinner in Android . Providing the following sample:</p> <p><img src="http://i.stack.imgur.com/d80hC.png" alt="enter image description here"></p> <p>Can anyone provide any inputs ?</p> <p>Thanks in Advance.</p> <p>Warm Regards,</p> <p>CB</p>
android
[4]
4,354,196
4,354,197
php set time delays after input attempts
<p>Question is related with brute force attacks. If user enters incorrect password, php records in mysql datetime of the attempt. And in case of incorrect password I need that the user can make next attempt only after certain time (1-2 seconds). As i understand php sleep is not good, because it does not prevent bots to...
php
[2]
1,618,717
1,618,718
Read Response object
<p>How do I read/write Response to an array? I'm not talking about HttpWebResponse but using Response. The purpose is that I'm writing to the response to build a simple file and I need to perform a checksum on it.</p> <p>Is it possible to read everything I've written to the response using the response object?</p> <p>...
asp.net
[9]
1,546,497
1,546,498
Can someone direct me to a script
<p>Stack overflow has this very cool char counter under the comment box. Can someone direct me to the script? or a something slightly different</p>
javascript
[3]
899,369
899,370
is it possible ui pickerview like Iphone in android
<p>i am using default android spinner for drop down selection from multiple items array ,but i see the ui in Iphone it looks cool then android then is it possible to make like iphone ui picker view in android means a dropdown would be open with bottom to top animation with a "done" button on upper side of picker view a...
android
[4]
4,135,603
4,135,604
Correct place to initialize class variables?
<p>Where is the correct place to initialize a class data member? I have the class declaration in a header file like this:</p> <p>Foo.h:</p> <pre><code>class Foo { private: int myInt; }; </code></pre> <p>Then I try to set a value to myInt in the corresponding .cpp file:</p> <p>Foo.cpp:</p> <pre><code>int Foo::m...
c++
[6]
2,537,250
2,537,251
using sqlite manager in android application
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/6333412/how-to-view-sql-database-in-eclipse-debug-mode-for-android">How to view SQL database in Eclipse Debug mode for android</a> </p> </blockquote> <p>I am developing an android application which involves data...
android
[4]
3,874,352
3,874,353
what are the advantages and disadvantages of anonymous methods in javascript?
<p>in javascript there are so many different ways to set up a method for something such as a button click event.</p> <p>for example say you have retreived an input element 'button'</p> <pre><code>function MyForm(){ //anonymous method button.click = function(){ //work }; //private method var handleClick ...
javascript
[3]
2,988,668
2,988,669
How to retrieve the inner key value of a plist file in android
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/3904418/apple-plist-form-of-xml-can-i-parse-it-through-android-java">Apple pList form of XML can I parse it through Android Java?</a> </p> </blockquote> <pre><code>&lt; array &gt; &lt; dict &gt; &lt; key &gt...
android
[4]
4,017,373
4,017,374
Trying to build a Python class in a C extension that can be instantiated from a Python module
<p>I'm trying to build an exception class that I can use both in a C extension and the Python modules that import the extension. I'm using the PyErr_NewException to create the class as a superclass of the Exception class, but I can't figure out how to create an <code>__init__</code> constructor for the class. I assum...
python
[7]
816,733
816,734
How to detect a click on anything other than this one div in jQuery?
<p>I want to hide a div with the class "myProfile" when the user clicks anywhere outside that div. How can I do this? </p> <p>I have this so far but obviously it says hide the div when the user clicks on it instead of "outside" it:</p> <pre><code>$('.myProfile').click(function() { $(this).hide(); }); </code></pre...
jquery
[5]
3,357,358
3,357,359
Which standard Java collections are remove-safe during iteration?
<p>Using <code>for(Type x:collection){...}</code> which widely used collection types make removing <code>x</code> safe during iteration?</p> <p>And is there a technical term for this to look out for in the JavaDocs?</p> <p><strong>Clarification:</strong></p> <p>I initially only asked about using the for-each syntax ...
java
[1]
3,288,748
3,288,749
How to get latitude and longitude of a location which user clicked on it
<p>I'm going to get latitude and longitude of a location on map which user has clicked on and do some calculation on them. BTW I shall say that I'm working with emulator and I don't have access to mobile phone and I have to run it in emulator. Please help me what to do!</p>
android
[4]
1,491,463
1,491,464
How to construct notes from a given song file?
<p>Are there any modules in Python that help us to construct or obtain the musical notes and octaves from a given original song?</p> <p>Thanks for the help</p>
python
[7]
2,604,690
2,604,691
DISTINCT for foreach
<pre><code>&lt;?php $array = array('aaa', 'bbb', 'aaa', 'ccc', 'ddd', 'ccc', 'eee'); foreach($array as $a){ echo $a; } </code></pre> <p>Is possible use some like DISTINCT for foreach? I would like show each values only one, without repeat. How is the best way for this?</p> <p><a href="http://codepad.org/FZQNEBeK...
php
[2]
4,870,920
4,870,921
unexpected T_Variable error, what is causing it in loop?
<p>I ma receiving an error stating:</p> <p>Parse error: syntax error, unexpected T_VARIABLE in .... on line 599</p> <p>which belongs in the line below: </p> <pre><code>foreach ($questions as $key=&gt;$question) { echo '&lt;p&gt;&lt;strong&gt;Question:&lt;/strong&gt; ' .htmlspecialchars($row_question['question_n...
php
[2]
3,869,480
3,869,481
jquery animation repeat, what is wrong with my syntax?
<p>Can someone please evaluate my code and let me know if it is correct.</p> <p>I am trying to run one animation after another, pause for 5000 milliseconds, reset all heights back to zero and repeat the animation again indefinitely.</p> <pre><code>function animateThis(){ $(".bars div:nth-child(1)").animat...
jquery
[5]
1,249,095
1,249,096
how to parse bank alert messages in android?
<p>how to parse bank alert messages in android?</p> <p>I have parsed HDFC banks alert sms. "thank you for using your HDFC bank Credit card ending 1364 for rs.7195.00 in MUMBAI at CLEARTRIP TRAVEL SERVI on 2012-02-24:11:10:50." thisis what.</p> <p>But i have to parse all banks(SBI,ICICI,UNION,AXIS etc)</p> <p>this is...
android
[4]