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,837,721 | 2,837,722 | Stripping $ from php values | <p>I have a form where users can enter the amount they spend on their phone bill and then I tell them how much they could save if they switched to vonage, skype etc. </p>
<p>I pass the value "$monthlybill" in the url and then do some math to it. The problem is that if the user writes "$5" instead of "5" in the form,... | php | [2] |
4,918,067 | 4,918,068 | Create a List that contain each Line of a File | <p>I'm trying to open a file and afterwards create a list with each line read from the file.</p>
<pre><code> i=0
List=[""]
for Line in inFile:
List[i]=Line.split(",")
i+=1
print List
</code></pre>
<p>But this sample code gives me an error because of the i+=1 saying that index is out of range.
W... | python | [7] |
647,749 | 647,750 | How to sort 3D array in c#, with each row is specific to one entry if 1D array? | <p>Please guide me as how to sort an array with taking into consideration that each row is specific to one specific column value. For example,</p>
<p>1D array<br>
5<br>
3<br>
4 </p>
<p>2D array<br>
1,2,3<br>
3,4,5<br>
6,7,8 </p>
<p>In above example,let say, 5 (In 1Darray) is associated with the first ... | c# | [0] |
2,180,906 | 2,180,907 | what is server.mappath(".") in asp.net | <p>What is server.MapPath() in asp.net.
Can any one please explain with example written in Vb.net</p>
<p>Thank you</p>
| asp.net | [9] |
2,713,862 | 2,713,863 | php path issue, solution needed | <p>The following code works when I place this script in the root </p>
<pre><code>if (file_exists("pics/2012/Blackhall Primary/" . $_FILES["file"]["name"]))
{
echo $_FILES["file"]["name"] . " already exists. ";
}
</code></pre>
<p>but if I move my script to a folder /teacher/ it no longer works.</p>
... | php | [2] |
1,424,843 | 1,424,844 | How to add a jquery listener? | <p>I have a list sorter plugin that is sorting just fine but the filter function is not working. I think it is because the filter buttons are not directly adjacent the list that needs to be filtered. How would I add a listener for the div that contains the list to be filtered?</p>
<p>jsfiddle: <a href="http://jsfiddle... | jquery | [5] |
5,343,477 | 5,343,478 | Convert.ToInt32() conditional formatting according to string with comma | <pre><code>string str = e.Row.Cells[index].Text;
int value = Int32.Parse(str, NumberStyles.AllowThousands, NumberFormatInfo.InvariantInfo);
if (value >= 100)
e.Row.Cells[index].BackColor = System.Drawing.Color.Green;
</code></pre>
<p>Cell values are 168,88 - 125,45 - 75,3 </p>
<p>After parsing str returns 168... | c# | [0] |
1,734,650 | 1,734,651 | Problem escaping string | <pre><code>const string postdescWithComments = @"<span class=""footerLeft"">posted on <a href=""{0}"" title = ""Permanent link to this post"">{1}</a></span><span class=""footerRight""><a href=""{2}#feedback"" title=""comments, pingbacks, trackbacks"" class=""comments""><img class=... | asp.net | [9] |
4,805,320 | 4,805,321 | swappable Java components | <p>I want to change an application by changing a component. In Java, it would seem that the swappable object could be placed in a jar. One version of the jar could be deleted and another identically named jar would be put in its place. </p>
<p>Is this the best practice for swappable Java components, and if not, the... | java | [1] |
367,357 | 367,358 | Elegant TryParse | <p>I feel that every time I use TryParse that results in somewhat ugly code, mainly I am using it this way :</p>
<pre><code>int value;
if (!int.TryParse(someStringValue, out Value)
value = 0;
</code></pre>
<p>Is there some more elegant solution for parsing all basic DataTypes, to be specific is there a way to do fa... | c# | [0] |
5,552,522 | 5,552,523 | Using tabulator / tabspace in a TextView | <p>I wish to use some tabspace in a line where I call setText</p>
<pre><code>if(id==R.id.radioButton1){
title.setText(numbertext.getText()+" Grams");
</code></pre>
<p>In this case I would like to tab between numbertekst.getText() and the grams.
The output is part of a simple row with values. But as I can'... | android | [4] |
4,931,943 | 4,931,944 | How to put a check on Empty TextField? | <p>Str is empty i mean i enter nothing in TextFied even then it's going in else case
NSString *Str= textField.text;
NSLog(@"%@",Str);</p>
<pre><code>if([Str isEqualToString:@""])
{
NSLog(@"Hi");
}
</code></pre>
| iphone | [8] |
3,225,745 | 3,225,746 | java using BigInteger and While | <p>I have a problem </p>
<pre><code>import java.math.BigInteger;
import java.io.*;
import java.util.*;
import java.lang.*;
public class medici {
public static void main(String[] arg) {
{
BigInteger zac = new BigInteger("3");
zac = zac.pow(399);
BigInteger kon = new BigInteger("3");
kon = kon.pow(40... | java | [1] |
2,691,526 | 2,691,527 | receiving data from serialport stops when main form is minimized or moved | <p>Sir,</p>
<p>I apologize if this is already covered somewhere. I did a search and find something which I have already implemented.</p>
<p>I am developing an application which receives data from a device connected via serialport. I am using SerialPort datareceived event to capture data. I am to display data in text... | c# | [0] |
2,502,235 | 2,502,236 | Passing value from a form to another form (C# winforms) | <p>Please take a look at this image:
<img src="http://a.imageshack.us/img21/6190/64635037.png" alt="alt text"></p>
<p>I have a <code>MDI</code> form with 2 different child forms in it (<code>Form1</code>, and <code>Form2</code>).
Is it possible to pass the value of <code>textBox1</code> in <code>Form1</code>, to <code... | c# | [0] |
3,756,358 | 3,756,359 | Retrieve an NSMutableArray which is in a method from another method of same class | <p>I am new to iphone i have a small doubt that is I have a method in a class that is below</p>
<pre><code>-(void)bookNamesWhichAreInDownloadedQueue:(NSMutableArray *)receivedBookNamesWhichAreInDownloadedQueue{
NSLog(@"receivedBookNamesWhichAreInDownloadedQueue is %@",receivedBookNamesWhichAreInDownloadedQueue);
... | iphone | [8] |
1,127,918 | 1,127,919 | TextView underline phone number and hyperlink | <p>I've written an app which contains a large textview for displaying notes. Is it possible to have the textview highlight any phone numbers or hyperlinks without underlining the entire view?</p>
| android | [4] |
593,086 | 593,087 | How do I get anchor href value on click using jQuery? | <p>Let's say I have an anchor like this:</p>
<pre><code><a onClick="return confirm('Sure?')" href="http://stackoverflow.com/">Click here</a>
</code></pre>
<p>Is there anyway I can get the value of href "http://stackoverflow.com/" when I click "Click here"? Bearing in mind that I don't have other attribute... | jquery | [5] |
1,790,233 | 1,790,234 | Is a C# field private by default? | <blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="http://stackoverflow.com/questions/3763612/default-visibility-for-c-classes-and-members-fields-methods-etc">Default visibility for C# classes and members (fields, methods, etc)?</a> </p>
</blockquote>
<p>Is a C# field by default private? In gener... | c# | [0] |
4,507,733 | 4,507,734 | operator overloading internal call conversion | <p>If there is a class</p>
<pre><code>class complex
{
private:
float real,imag;
public:
complex operator +(complex c)
{
complex t;
t.real=real+c.real;
t.imag=imag+c.imag;
return t;
}
</code></pre>
<p>and in main if we call overloaded operat... | c++ | [6] |
4,727,048 | 4,727,049 | C++ Passing a pointer to a member function as an argument | <p>I need to pass a pointer to a member function as an argument to a member function in another class. What I'm doing is something like below.
I want to call int Processor::AddJob(void <em>(</em>_pFunc)(void*), void* _pArg) method with void* ProcessHandler::Task(void* a) as the first argument.
I did it as </p>
<pre><c... | c++ | [6] |
2,517,129 | 2,517,130 | toggle is not working | <pre><code><!DOCTYPE html>
<html>
<head>
<script type="text/javascript" src="jquery-1.7.1.min.js"></script>
<script type="text/javascript">
$(document).ready(function(){
$("button").click(function(){
$("p").toggle(function(){
$("p").hide();},
function(){
$("p").show(... | jquery | [5] |
1,343,587 | 1,343,588 | htmlentities utf-8 problem | <p>I got something weird happening here and I can't understand why, on my php 5.2.5 server when I use a POST Form to post the content on an input containing "é" and on the other side I echo(htmlentities($_POST["myinput"])) it echo <code>&Atilde;&copy;</code> </p>
<p>But if I echo my $_POST["myinput"] simply it... | php | [2] |
4,905,234 | 4,905,235 | Moving Activity to another Activity when class extends ArrayAdapter | <p>When I click the <code>edit_remainder</code> button I want to move my Activity to another Activity.</p>
<p>But where the class extends ArrayAdapter I don't understand how to move to another Activity.</p>
<p>Please help me with an example of the Intent class.</p>
<pre><code>public class mylist extends ArrayAdapter... | android | [4] |
4,797,234 | 4,797,235 | How can I use a ttf file for a button's text? | <p>How can I use a ttf file for a button's text?</p>
| android | [4] |
5,918,798 | 5,918,799 | place condition in the read or in the code? | <p>I am checking if an item has a linked item in the database but cant decide where to put the condition. </p>
<p>option one: place the condition in the database read statement.</p>
<pre><code>select * from item where id = id.
</code></pre>
<p>Option two check afterwards in code.</p>
<pre><code>temp = select * fr... | java | [1] |
3,744,648 | 3,744,649 | remove all children of ul element thats means remove all li's | <p>I am doing the following code to remove all the children of UL.Is it right to do.ALl the childrens are li element.</p>
<p>thickBoxProductLists is the id of UL element</p>
<pre><code> $('#thickBoxProductLists').children().remove();
</code></pre>
| jquery | [5] |
1,329,272 | 1,329,273 | PHP's mail function doesn't send email | <p>So when I submit my form, everything is stored in the database just fine, I had a really simple email that basically consisted of, 'Hey thanks, this is your link' kind of deal and I received that just fine. But now I've upgraded to using an HTML body instead and suddenly I'm not receiving the email, any idea why?</p... | php | [2] |
1,064,668 | 1,064,669 | jQuery .contentWindow.document.getElementById('email_box').value help | <p>Hey all, i'm just wondering if there was any way to condense this line of code to pure jQuery without having the need to have ".contentWindow.document.getElementById('email_box').value" in there?</p>
<pre><code> $('#OIPHPFrame')[0].contentWindow.document.getElementById('email_box').value = $("#txtEmail").val();
</c... | jquery | [5] |
2,977,238 | 2,977,239 | "Request timed out." error when setting debug="false" | <p>I have a page that takes a few minutes to run. When I set <code>debug="false"</code> in the <code><compilation /></code> tag in web.config, I get a "Request timed out." error (and internal try/catch blocks in my code get a "Thread was being aborted." error. </p>
<p>What is the fix to allow long pages to run ... | asp.net | [9] |
1,887,855 | 1,887,856 | JavaScript: Error - "Expected an assignment or function call and instead saw an expression"? | <p>I am using the <strong><a href="http://JSLint.com">JSLint</a></strong> tool to ensure my JavaScript is "strict" and I'm getting the following error:</p>
<pre><code>Expected an assignment or function call and instead saw an expression
</code></pre>
<p>On the following code:</p>
<pre><code>(my_var > 0 ) ? $("#ab... | javascript | [3] |
3,516,461 | 3,516,462 | How to change the background colour? | <p>I want to design a identical screen like messaging screen.Iam using the below xml code for designing the screen. I want to change the background colour as gray for the edittext <code>@+id/txtMessage</code> and for the button as like the messaging screen of android.How can i done that?</p>
<pre><code><?xml vers... | android | [4] |
5,127,618 | 5,127,619 | When i pass one form id to the queryselectorall method im able to see all the inputs inside the form | <p>When i pass one form id to the queryselectorall method im able to see all the inputs inside the form. But when i pass two id of form to queryselector all i see it two form being returned. Can some one help me out with this ? Below is the code that im using </p>
<pre><code>window.$ = function(el) {
el = documen... | javascript | [3] |
4,156,926 | 4,156,927 | How to convert from Decimal to T? | <p>I've built a wrapper over NumbericUpDown control.
The wrapper is generic and can support int? and double?</p>
<p>I would like to write a method that will do the following.</p>
<pre><code>public partial class NullableNumericUpDown<T> : UserControl where T : struct
{
private NumbericUpDown numericUpDown;
... | c# | [0] |
191,293 | 191,294 | Bad url in iphone sdk | <p>url <a href="http://crescerance.com/School/isummit/speakers.html" rel="nofollow">http://crescerance.com/School/isummit/speakers.html</a></p>
<p>Isummit[12923:1d013] Error Domain=NSURLErrorDomain Code=-1000 "bad URL" UserInfo=0x91aa490 {NSUnderlyingError=0x91aa1d0 "bad URL", NSLocalizedDescription=bad URL}</p>
| iphone | [8] |
352,986 | 352,987 | How do I cancel an AsyncTask | <p>I am using an Asynctask as the loop controller for a game and noticed that the thread created kept on running after the activity was finished.</p>
<p>I realised that was the correct behaviour of a separate thread and then I tried hunting down answers on how to end the thread when the app enters onPause.</p>
<p>I f... | android | [4] |
1,706,861 | 1,706,862 | How do I use str_replace() with multiple parameters? | <p>Basically, I want to use both <code>$city_name</code> and <code>$ref_name</code> with str_replace(), so that if either one (or both) of them are inputted by the user, both of them are replaced with their actual variable forms.</p>
<p>To give a better illustration, here's my current code;</p>
<pre><code>$headlines ... | php | [2] |
4,056,618 | 4,056,619 | Difference between Response.Redirect() and Response.Write() | <p>What is the difference between </p>
<pre><code>Response.Redirect("Default.aspx");
</code></pre>
<p>and </p>
<pre><code>Response.Write("<script>location.href='Default.aspx';</script>");
</code></pre>
<p>Why someone will choose the second one?</p>
| asp.net | [9] |
3,505,690 | 3,505,691 | SMS Receiver as a Service | <p>I have created SMS Receiver app... but i want to create it as an service, it should run in the background (i.e no separate UI for this app, want to work like alarm app) and even if mobile restarts it automatically starts... could any one help on this?</p>
<p>My previous SMS Receiver app code was here
<a href="http... | android | [4] |
5,562,026 | 5,562,027 | How can I get the name/file of the script from sitecustomize.py? | <p>When I run any Python script, I would like to see the script's filename appear in the Windows command line window's titlebar. For example, if I run a script called "<code>mytest.py</code>", I want to see "<code>mytest</code>" in the titlebar. I would like this to be automatic, so I don't have to add code to every on... | python | [7] |
5,477,785 | 5,477,786 | Black screen in inner preferenceScreen | <p>My <code>PreferenceActivity</code> contains a nested <code>PreferenceScreen</code> in another <code>PreferenceScreen</code> and I'm applying a theme to my <code>PrefenceActivity</code> that changes the background color. However when I open the nested <code>PreferenceScreen</code> I get a black background and I canno... | android | [4] |
4,517,151 | 4,517,152 | Best way to handle shape drawable differences Android 2.3.5 vs 4.0 | <p>I'm trying to have a shape drawable with this shape:</p>
<p><img src="http://i.stack.imgur.com/Coy3J.png" alt="enter image description here"></p>
<p>This works properly in 1.6 to 2.3.5 when using the following:</p>
<pre><code><shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="re... | android | [4] |
4,021,148 | 4,021,149 | Countdown with hours and minutes - compute the difference | <p>I have two dates:</p>
<pre><code>$today = '2012-12-01 10:40:00';
$check = '2012-12-03 12:00:00';
</code></pre>
<p>How can I show countdown for this dates?
Should show me:</p>
<p>Count: <strong>49</strong> hours and <strong>20</strong> minutes. I can check only hours or only minutes with function mktime, but how c... | php | [2] |
4,465,386 | 4,465,387 | spliting a string based on delimiter | <blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="http://stackoverflow.com/questions/96428/how-do-i-split-this-string-with-javascript">How do I split this string with JavaScript?</a> </p>
</blockquote>
<p>I have a string in following format</p>
<pre><code>part1/part2
/ is the delimiter
</code>... | javascript | [3] |
638,102 | 638,103 | Do Messages block in Android | <p>Im writing an app which loads data from a rest interface.
for this task i use a service which gets called by the activitys. Those calls are based on the "Message". I do it like that because i thought that just sending a message does not result in a blocking of the UI thread (i used much of the RemoteService example ... | android | [4] |
4,451,642 | 4,451,643 | Android json error.index out of range | <p>I am trying to get values from mysql and inserting them in sqlite database.But i am getting error in json index out of range.</p>
<p><strong>Here is my code</strong>.
<strong>I am getting json parsing Exception</strong>:</p>
<pre><code> protected void onPostExecute(Void v)
{
try{
Datab... | android | [4] |
3,024,506 | 3,024,507 | Unable to grasp this javascript snippet function abc(){a:'b'; c:'f'; f:'t'; }; Can someone explain? | <pre><code>function abc(){
a:'b';
c:'f';
f:'t';
};
</code></pre>
<p>This snippet does not throw an error in console. I want to understand whats happening with the variables inside the function. Hows it being interpreted by the javascript engine.</p>
| javascript | [3] |
2,947,576 | 2,947,577 | Python ljust method not working as expected on formatted strings | <p>When using string formatting resulting string is longer than expected.</p>
<p>For example:</p>
<pre><code>In [1]: "%s".ljust(7) % "123456"
Out[1]: '123456 '
</code></pre>
<p>Output string is not 7 characters long.</p>
<p>I'm interested in what is exactly happening 'in the background' to result in such behavi... | python | [7] |
2,086,320 | 2,086,321 | startSearch now working | <p>Hi i have the following code in onSearchRequest
public boolean onSearchRequested() {</p>
<pre><code> startSearch("HI", false,null,true);
return true;
}
</code></pre>
<p>This is working bt uses default google search .If i use
startSearch("HI", false,null,false); then sarch dialog doesnt open...... | android | [4] |
2,980,084 | 2,980,085 | Android Text to speech | <p>I want to use TTS (Text to Speech) in my android application.how can i use texttospeech Engine
and one more is it support Japanese language? please help me on this.</p>
<p>Regards
Thilag.</p>
| android | [4] |
5,182,965 | 5,182,966 | custom search engine for image and url | <p>I’d like to create a search engine that pretty much functions like Google web search. However, instead of meta descriptions under each URL, I’d like photos from the website to appear.</p>
<ol>
<li>The search engine should pull images from the site and display them under the result in a predefined area. </li>
<li>Th... | php | [2] |
3,468,017 | 3,468,018 | jQuery Selector to Return All Elements Hidden By an Element Without a Particular Class | <p>Is it possible to write a single selector to query for all elements which have a hidden parent where the hidden parent doesn't have a specific class. </p>
<p>For example given the HTML below, it would only select Field2 as it's parent is hidden and the parent element that hides it does not have the "tab" class.</p>... | jquery | [5] |
4,545,901 | 4,545,902 | Using interpreter to lookup module 'sys' in Python | <p>So I just installed the python interpreter and wanted to use the help(sys) feature to get more information about the sys module, but I got this error and had no idea what went wrong.</p>
<pre><code>C:\Users\Jake>python
Python 2.7.2 (default, Jun 12 2011, 14:24:46) [MSC v.1500 64 bit (AMD64)] on win
32
Type "help... | python | [7] |
2,753,386 | 2,753,387 | Is there an event to detect when the screen dims? | <p>I'm using a SCREEN_DIM_WAKE_LOCK and so my never turns off. It just goes from full brightness to dim.</p>
<p>Is there any way for me to detect when the screen gets dim (event, receiver, etc.) ?</p>
| android | [4] |
3,588,375 | 3,588,376 | Can anyone help me with this questions about eclipse and windows builder? | <p>I actually have more than one question, and I really need help because I'm starting in java's world and I don't know a lot, I used to program using C#, but now I want to learn java and there are some things that I just don't understand.(sorry for my english, it's not my first language.)</p>
<p>1 question- I see you... | java | [1] |
4,892,530 | 4,892,531 | Problems in posting value from Jquery UI Dialog | <p>I have submit button in side the jquery ui dialog and the dialog is inside a form. I am posting values to the same or different php page. But what I found that the values are not posted and actually submit button is not working at all. What is the fix? Please help with your opinions.</p>
<p>thanks</p>
| jquery | [5] |
3,488,173 | 3,488,174 | Illegalstate exception in listview | <p>in my listview i am populating datas which come from a background thread and i also called notifydatasetchanged(),still it gives exception.does anybody have solution to this.</p>
| android | [4] |
773,383 | 773,384 | Differences between android:text="@string" and android:text="..." | <p>Maybe this is a silly question but is there a difference,besides the obvious,between
android:text="@string/...." and android:text="..."?.I'm thinking that maybe the text that appears on the screen has the option for styling when using @string.Which one is best to use in general or it really doesn't matter?</p>
| android | [4] |
1,814,382 | 1,814,383 | mimerender installation issues | <p>I am having a hard time installing mimerender. I followed all the steps and downloaded the .egg package. I was trying to use your example here:</p>
<p><a href="http://stackoverflow.com/questions/713847/recommendations-of-python-rest-web-services-framework">Recommendations of Python REST (web services) framework?<... | python | [7] |
5,704,513 | 5,704,514 | internationalization in iphone | <p>I am developing an app in English. I want to change this app into French.</p>
<p>For static data I am able to do this. But For dynamic data I am unable to do this. How can I solve my problem..</p>
<p>Thanks and Regards
sai</p>
| iphone | [8] |
5,713,047 | 5,713,048 | How can I check whether a user enters the same number twice? C++ Help? | <p>I just need quick help. Here's a breakdown of some code:</p>
<pre><code>char userLetter;
int userNumber;
cout << "Please enter a letter: ";
cin >> userLetter;
while(userLetter == 'A')
{
cout << "Please enter a number: ";
cin >> userNumber;
//do something in the loop here
... | c++ | [6] |
2,663,032 | 2,663,033 | Speeding up System.Collection.Generic.Queue() possible? | <p>50\% of my simulation time is spent on the following code:</p>
<pre><code> internal double simWithdrawalFast(double t)
{
simarrivals.Enqueue(t + Leadtime);
return simarrivals.Dequeue();
}
</code></pre>
<p>where simarrivals is a <code>System.Collection.Generic.Queue<double></code>. ... | c# | [0] |
3,759,365 | 3,759,366 | Iterating through a list of objects and displaying the property in the combobox | <p>I have 2 combo boxes, the first one lets you pick an interface and the second one should display the appropriate addresses depending on which interface you chose, I have a list of objects, each object is an interface with associated addresses. I need to display these addresses to the combo box after the user choose... | c# | [0] |
4,286,932 | 4,286,933 | how to make online radio application on android? | <p>I tried to make some test for listening mp3 file which is located in website. It was successfull. But when I tried to listen a link which is online radio, application is doing nothing. No any sounds..</p>
<p>I used :</p>
<pre><code>private void initializeMediaPlayer() {
player = new MediaPlayer();
try {
... | android | [4] |
4,362,030 | 4,362,031 | Why use initializer_list instead of vector in parameters? | <p>What is the actual benefit and purpose of <code>initializer_list</code>, for unknown number of parameters? Why not just use <code>vector</code> and be done with it?</p>
<p>In fact, it sounds like just a <code>vector</code> with another name. Why bother?</p>
<p>The only "benefit" I see of <code>initializer_list</co... | c++ | [6] |
4,205,850 | 4,205,851 | FileSystemWatcher, unsubscribe from the event | <p>I'm fooling around with the FileSystemWatcher in 4.0. I find this very useful but am getting caught in a loop. I'm trying to monitor whenever an ini is changed and change it back to the correct default (long story) however the change event copying over the new file is causing it to drop into a loop ... Any Ideas > ... | c# | [0] |
5,552,324 | 5,552,325 | apply script to all elements | <p>i need to show all images, which are in the <code>div</code> with <code>class="deep"</code>.</p>
<p>when i try the following script it doesn't work.</p>
<p><code>$(".deep img").css("visibility", "visible");</code></p>
<p>i can solve the problem using something like <code>.each</code>, but maybe there is something... | jquery | [5] |
549,567 | 549,568 | Check box checked Automatically in listview when scrolling the list. | <p>I have one problem, i have customize <code>listview</code> with <code>checkbox</code>. </p>
<p>When i scroll the items the some <code>checkbox</code> is automatically <code>checked</code> without clicking on <code>checkbox</code>.</p>
<p>Can any one help me?</p>
| android | [4] |
5,355,257 | 5,355,258 | Printed representation of list | <p>I want to format a list into a string in this way:
<code>[1,2,3] => '1 2 3'</code>. How to do this?
Is there any customizable formatter in Python as Common Lisp format?</p>
| python | [7] |
5,736,390 | 5,736,391 | Get Item From List<T> and update a property on that Item | <p>I have a List of type Person that I would like to update DisplayValue based on DisplayName. How can I accomplish this?</p>
<pre><code>public class Person
{
public string DisplayName { get; set; }
public string DisplayValue { get; set; }
... other properties
}
</code></pre>
| c# | [0] |
1,986,349 | 1,986,350 | unable to connect postgresql in android code on windows 7 | <p>i want to connect postgresql database in my android code...
for that first i install postgresql 9.1 and download the jdbc driver .....
and then follow the android code from below site</p>
<p><a href="http://appliedcoffeetechnology.tumblr.com/post/10657124340" rel="nofollow">http://appliedcoffeetechnology.tumblr.com... | android | [4] |
2,706,862 | 2,706,863 | Automating Website Testing - Website Online/Available? | <p>I would like to automate some testing of whether a long list of websites is available or not. I need to test access of certain websites in an intranet. I just need to basically create an HTTPRequest and send the URL and then read the HTTPResponse (200, 404, 500, etc.) and log the results. I have some code doing t... | c# | [0] |
5,980,610 | 5,980,611 | Can I have an object return a default value if no methods are called? | <p>As an example, I want to mimic the functionality of the String object:</p>
<pre><code>String mystring = new String ( "Hi there." );
System.out.println(mystring); // prints "Hi there." without calling any methods on String
// (that is what I want with my object)
System.out.println(mystr... | java | [1] |
4,686,144 | 4,686,145 | android monitoring apps | <p>I would like to create an Android application with real-time monitoring functions. One monitoring function is to audit the audio flow. The other function is to interact with a peripheral sensor. These monitoring functions can be triggered by others.
Besides, in order to save power consumption, the audio function... | android | [4] |
4,667,679 | 4,667,680 | What is the way collide UILabel in UIImage? | <p>I have a task to do. I have a big image like a country and different names like name of the states in a country which are UILabels. My task is if I place the label on any state in the UIImageview, it should check whether I placed it on correct place or not.</p>
<p>Can anyone let me know the logic how to do this?</p... | iphone | [8] |
4,115,045 | 4,115,046 | ASP.net AJAX: textbox readonly state | <p>I currently have a button called Edit and a text box call blah on a ajax updatepanel. is it possible to set the asp.net's textbox Readonly via trigger? </p>
| asp.net | [9] |
3,839,663 | 3,839,664 | C++: boost smart pointer | <p>Could you please help me to check this code following, I got some errors?</p>
<pre><code>class VideoInfo {
public:
VideoInfo();
virtual ~VideoInfo();
std::string filename; // name of the video file in the fileSystem
unsigned int frameSequenceID; // frame index of the video file
};
}
}
</code></pre>... | c++ | [6] |
2,119,155 | 2,119,156 | Show 2 by 2 elements on click | <p>I have the following container:</p>
<pre><code> <div id="container">
<div id="1">1</div>
<div id="2">2</div>
<div id="3" style="display:none">3</div>
<div id="4" style="display:none">4</div>
<div id="5" style="display... | jquery | [5] |
4,788,747 | 4,788,748 | Null-Pointer by findViewById | <p>I have in my onCreate-Method a lot of findViewById. Some of them are parameter for objects I make in the onCreate-Method. Now I tried to make the findViewById-call in the Constructor of my Objects but i get a Null-Pointer.
How do I get these findViewByIds in my Object?</p>
| android | [4] |
1,395,875 | 1,395,876 | check for online update when open program in C# | <blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="http://stackoverflow.com/questions/555118/suggest-a-method-for-auto-updating-my-c-sharp-program">Suggest a method for auto-updating my C# program</a> </p>
</blockquote>
<p>I'm sorry if this question has been asked already.
i have a problem whit o... | c# | [0] |
1,182,166 | 1,182,167 | jQuery Deferred object callback args & dynamically building? | <p>I saw this code at jQeury Site : </p>
<pre><code> 1: var jqxhr = $.ajax( "example.php" )
.done(function() { alert("success"); })
.fail(function() { alert("error"); })
.always(function() { alert("complete"); });
2: // perform other work here ...
// Set another completion function f... | jquery | [5] |
4,731,366 | 4,731,367 | Good examples of PHP code for an intermediate PHPer? | <p>I know the basics for PHP and have written a school project in PHP (although looking back on it, I'd really love to rewrite it)</p>
<p>I'd really like to get a feel for how to code <em>good</em> PHP code though, for example what are the best practices when it comes to PHP? And are there recommended ways of tackling... | php | [2] |
3,445,660 | 3,445,661 | edit the first option name | <p>I have the following code which I do not have access to. </p>
<p>What I want to do is add some text into the first option which is now empty. Text such as "Select Address"</p>
<pre><code><select name="My_Saved_Billing"
onChange="Choose_My_Saved_Billing(this.selectedIndex)" style="background-color:#EEEEEE">
&... | jquery | [5] |
4,683,510 | 4,683,511 | sql data type bit | <p>I have sql data type bit and i want to ask </p>
<pre><code>if(dr[2] != null)
</code></pre>
<p>What changes should make it?
Sorry for the mistakes I'm not local.</p>
| c# | [0] |
2,559,925 | 2,559,926 | PHP form not working on new server | <p>I have created a form for my website by following a tutorial at tutorialzine</p>
<p>I have this form working nicely on one of my websites but when I tried to install the form on a new website the form fields are full of script and it doesn't work. I have put the same form on both servers to demonstrate the problem.... | php | [2] |
3,275,374 | 3,275,375 | how to construct a long string | <p>I need to construct a long string with javascript. Thats how i tried to do it:</p>
<pre><code>var html = '<div style="balbalblaba">&nbsp;</div>';
for(i = 1; i <= 400; i++){
html+=html;
};
</code></pre>
<p>When i execute that in firefox its taking ages or makes it crash. what is the best way t... | javascript | [3] |
3,107,851 | 3,107,852 | What does Python's dir() function stand for? | <p>I know that the dir() function gives you back either the names defined in the current scope or the names defined in an object. But why is it called dir()? Is it some mysterious acronyms like LISP's CAR and CDR?</p>
| python | [7] |
2,372,970 | 2,372,971 | limit php script (fetch all photos in a directory) to 7 | <p>can someone please help, i am using a script in php to fetch all the photos in a directory, but i want it to limit it to only fetch 7 images in total, the ones it select can be random.</p>
<p>can anyone suggest a way i can do this thanks.</p>
<pre><code><?php if (isset($_SESSION['user_id'])) {
if ($use... | php | [2] |
3,317,381 | 3,317,382 | How to start an ACTION_PICK activity with only those contacts which have a mobile phone | <p>I want the user to select a contact to which my application would send a SMS. How do I ensure that when I start an activity with ACTION_PICK intent only those contacts with mobile phone numbers are displayed?</p>
<p>Currently, I'm starting the activity like this:</p>
<pre><code>Intent intent = new Intent(Intent.AC... | android | [4] |
1,811,495 | 1,811,496 | Rename a string-array in arrays.xml | <p>In my values/arrays.xml, I have <code><string-array name="pref_entries" translatable="false"></code>
but as soon as I rename it to </p>
<pre><code><string-array name="pref_entries2" translatable="false">
</code></pre>
<p>I get this error:</p>
<p>res/values/arrays.xml:28: error: Resource at pref_entri... | android | [4] |
139,039 | 139,040 | Close a running program from java application | <p>I open up an external application from my java application. How can I close this application from the same Java application?
thanks</p>
| java | [1] |
4,860,083 | 4,860,084 | How to express the difference between two dates in a human-readable format | <p>If I have two dates - <code>$end_date</code> and <code>$start_date</code>, how can I express the difference between the two in a format such as "2 Years : 4 Months : 2 Days"?</p>
<p>I know that I can get the difference between the two dates like so:</p>
<pre><code>$dif=strtotime($end_date)-strtotime($today);
</cod... | php | [2] |
2,601,981 | 2,601,982 | Better way to read in stream data without wrapping the whole thing in an empty try catch? | <p>Doing something like this at the moment:</p>
<pre><code>try
{
while ((bytesRead = clientStream.Read(data, 0, data.Length)) != 0)
{
string message = Encoding.ASCII.GetString(data, 0, bytesRead) + Environment.NewLine;
txtLog.Invoke(c => c.AppendText(message));
}
}
catch
{
}
</code></p... | c# | [0] |
3,510,555 | 3,510,556 | combining PHP functions | <p>I've inherited some php that parses an xml file to populate a page full of unordered lists and am wondering if there is a way to consolidate the php functions to make them more efficient.</p>
<p>There are 25 or so functions like the following:</p>
<pre><code>function oaAccounting(){
// load SimpleXML
$term = ... | php | [2] |
2,730,200 | 2,730,201 | How to play more than two songs using AVAudioPlayer | <p>I want to play more than two song in my app. how do I can do it using AVAudioPlayer ?</p>
| iphone | [8] |
2,186,783 | 2,186,784 | IE 7 & 8 wont load script | <p>I am using the following code to load in needed JS libraries for my widget:</p>
<pre><code>function loadScrip(url, callback) {
var script = document.createElement("script")
script.type = "text/javascript";
if (script.readyState) { //IE
script.onreadystatechange = function () {
if (s... | javascript | [3] |
4,903,898 | 4,903,899 | "Clear User Data" android | <p>What exactly does Clear User Data do? I mean I know it clears the users data from the app, but what data being stored where?</p>
| android | [4] |
2,863,689 | 2,863,690 | php: keyword lookup | <p>I'm looking for a little php script that looks up keywords in a mysql table and gives the response, based on the most matching keywords.
For example:</p>
<ul>
<li><p>imput:who are you </p></li>
<li><p>mysql table: KEYWORDS:who,you RESPONSE: I'm a robot</p></li>
<li><p>script returns: I'm a robot</p></li>
</ul>
| php | [2] |
3,228,922 | 3,228,923 | Passing parameter to a windows service in c# | <p>I am creating a windows service which has to run on specific days and time. I am passing these variables using an XML document. Here is my code for passing the values</p>
<pre><code> static void Main()
{
ServiceBase[] ServicesToRun;
Service1= new Service1();
//Load setting ... | c# | [0] |
3,824,597 | 3,824,598 | how to show images in grid view? | <p>I have a database which contains list of image path. My problem is I have to show all the images in a grid view.
I have taken list of path from database but i am not able to show all the images in grid layout.
Please help me.
Thanks</p>
| android | [4] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.