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
557,336
557,337
generation vs verification
<p>i was wondering if i am generating a number give an input and i want to then verify that the pairs are valid..would I store the result somewhere? I am not inclined to since I could run a million inputs through. Perhaps in my verification function I just call the generation function which generates the random code fo...
c++
[6]
1,290,687
1,290,688
Use ringtone from android phone on bluetooth module
<p>I'm using a bluetooth module alongside android. I would like to be able to use the users ringtone that is set on their phone as the ringtone that is used on the bluetooth module. Im not looking for a permanent transfer of the file, only the sound to be replicated. I think that it is referred to as an "inband ring...
android
[4]
4,740,427
4,740,428
radio button ID value
<p>I have a radio group where I need to do some math calculations based on the value of the radio selected, but I also need a way to know my identity value for the SQL record it represents. Normally I would have that stored in the "value" attribute of the radio button. </p> <p>What I tried to do here is have different...
jquery
[5]
2,631,912
2,631,913
Switching the browser to full screen from Javascript, possible?
<p>Is it possible to switch the browser into and out of full screen mode (simulate an F11 key press) from Javascript?</p> <p>I want to have a button that will make the switch. This have to affect the current browser window, it can't open a new window.</p>
javascript
[3]
554,355
554,356
Duplicate log output when using Python logging module
<p>I am using python logger. The following is my code:</p> <pre><code>import os import time import datetime import logging class Logger : def myLogger(self): logger = logging.getLogger('ProvisioningPython') logger.setLevel(logging.DEBUG) now = datetime.datetime.now() handler=logging.FileHand...
python
[7]
1,664,130
1,664,131
static function/variable
<p>i just started programming in c++ this concept of static variable/function wasn't clear to me..why is this used and is there any other alternative of this!!!</p>
c++
[6]
1,418,074
1,418,075
Android: Getting phone owner info
<p>Since there is the permission called</p> <pre><code>android.permission.READ_OWNER_DATA </code></pre> <p>there MUST be a way to read the phone owner info on an android device.</p> <p>The only thing I could find on the net is this:</p> <pre><code>Uri uri = Uri.withAppendedPath(Contacts.People.CONTENT_URI, "owner")...
android
[4]
4,498,907
4,498,908
Python: write floats to file, and reduce number of digits after decimal point
<p>In my program I am printing float numbers to file. There is high precision of these numbers so there are many digits after decimal point, i.e number 0.0433896882981. How can I reduce number of digits that I print into file?So I would print, say, 0.043 instead of 0.0433896882981.</p>
python
[7]
3,585,113
3,585,114
.htaccess and double quotations in url
<p>I get the 404 error when i click on the hyperlink due to the quotation marks. The MySQL column <code>title</code> has this value <code>the official "i'm hungry" page</code></p> <pre><code>$title = str_replace(' ','-',$row['title']); &lt;a href='/page/$id/$title'&gt;click me&lt;/a&gt; </code></pre> <p>Here is the ...
php
[2]
4,323,396
4,323,397
How to create a Default, Custom Styled Spinner
<p>I am trying create my custom Style spinner with help of <a href="http://www.mokasocial.com/2011/03/easily-create-a-default-custom-styled-spinner-android/" rel="nofollow">this</a> site. But the changes no appear. I did exactly like shown in that site. But I don't know understand what should I do to see the result</p>...
android
[4]
3,919,714
3,919,715
How do i format a string in an email so that in outlook it will look in Tabular format?
<p>I wanted to generate an email from java.By formatting the message body to look like a tabular format with proper alignment.Can any one please help me how to format a message body into tabular format?</p>
java
[1]
5,336,174
5,336,175
When to use Yield?
<p>When should I use return yield and when should I use return only?</p>
c#
[0]
1,335,390
1,335,391
jQuery drag-and-drop demo works. Now how to make it a form that can be submitted?
<p><a href="http://plugins.scbfolio.com/jquery_drag_drop_select/#Events" rel="nofollow">This</a> is exactly the behaviour I want: dragging items from a list to another.</p> <p>Now, I would like to add a "submit" button so that I can save the chosen items on the server side.</p> <p>How to do this?</p> <ul> <li>Create...
jquery
[5]
4,773,330
4,773,331
Calling Form.Show() in series
<p>everyone. How do I call a number of forms one after another (meaning call new form after previous one is closed). I wrote something like this;</p> <pre><code>Form1.Show(); Form2.Show(); </code></pre> <p>and it naturally results in opening both forms simultaneously. How to make function to wait for the fist form t...
c#
[0]
5,519,879
5,519,880
What have you used Object.clone() for?
<p>A colleague recently asked me how to deep-clone a Map and I realized that I probably have never used the clone() method- which worries me.</p> <p>What are the most common scenarios you have found where you need to clone an object?</p>
java
[1]
2,035,013
2,035,014
highlight a text in web view
<p>I am using a html page in the web view. I want to track the location of the html page when I tap on the webview.Basically I want to mark the selected text in the html page.Please help me out as soon as possible.</p> <p>Thanks in advance.</p>
iphone
[8]
5,158,064
5,158,065
Redraw LinearLayout after change of orientation
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/456211/activity-restart-on-rotation-android">Activity restart on rotation Android</a> </p> </blockquote> <p>I've got a LinearLayout that I want to be <code>android:orientation="vertical"</code> when in portrait ...
android
[4]
441,719
441,720
Is it necessary to call delete[] vs delete for char arrays?
<p>I'm utilizing a library written by a collegue and discovered that <code>valgrind</code> was spewing out errors related to the <code>delete</code>.</p> <p>The problem was that there were allocations of char arrays like</p> <pre><code>char* s = new char[n]; </code></pre> <p>followed up later with <code>delete s</co...
c++
[6]
5,600,477
5,600,478
want to show a image when enter a particular region of lat. long by zoom in and out android
<p>hi friends i am able to display Google map in my android device and by default i am able to perform zoom in and out,so now i want to show a image when i enter,A REGION of between lat. long then a small pop msg appear at top of google map as "you enter buenos region"(Buenos is just place name whose coordinate area i...
android
[4]
5,053,804
5,053,805
Android - Custom Date style - SimpleDateFormat - app crash
<p>Im trying to make Statusbar date can change to an format gave by user though an inputbox</p> <pre><code>&lt;PreferenceCategory android:title="StatusBar Date"&gt; &lt;CheckBoxPreference android:title="Custom date" android:key="custom_date" android:summary="Turn on to enable custom date format" android:defaultVal...
android
[4]
5,446,517
5,446,518
How to change push notification alert sound
<p>I am trying to customize a push notification alert. I copied one sound file to the application bundle and set the sound file name in the push notification payload to that of the new file name, But the sound is not playing. How can I change the push notification alert sound?</p>
iphone
[8]
1,414,647
1,414,648
How to change background color of custom xml file in android
<p>how to change the inner color of my xml file.It has default color as black only.how to change to other color.i have gn by xml file below .xml file is used for creating border,but i cant change the background color.Need help on this</p> <p>Regards Gomathi sankar</p>
android
[4]
1,953,517
1,953,518
Python Colon(:) in list index
<p>I'm new to Python. I see <code>:</code> used in list index especially when it's associated with functional calls, for e.g., python 2.7 document suggests that <code>lists.append</code> translates to <code>a[len(a):] = [x]</code>. Why do one have to suffix <code>len(a)</code> with a colon?</p> <p>I understand that : ...
python
[7]
998,116
998,117
javascript button click casuing Internet Explorer secuirty exception
<p>I have a application that allows a user to choose some parameters for a powerpoint report, run the report, then allow the user to "save" or "open" the powerpoint file. I got all of that working OK. When you click on "run" report, it pops open a window which generates the report, stores it in session, then closes the...
javascript
[3]
3,299,204
3,299,205
How to draw a gaussian curve in android?
<p>I have to draw a simple gaussian distribution curve in android. A sample code will be a great help.</p>
android
[4]
5,090,294
5,090,295
How to create dynamic forms for dynamic survey and how to store that form's value?
<p>I want to make application like "<strong>wufoo.com-Online form and surveys</strong>". How can I create dynamic forms for dynamic survey. </p> <p>How can I handle that dynamic form's value into DB? Can anyone give me an idea how can I should manage dynamic surveys?</p>
php
[2]
1,702,646
1,702,647
Editing JavaScript on browser debugger
<p>We want to test the script that is executing in prod environment. We are unable to reproduce the issue at our side.</p> <p>we are using FireFox/Chrome debugger and here we want to edit the JavaScript and see how it behaves in prod environment. Is that possible?</p> <p>Regards,<br> RPK</p>
javascript
[3]
5,016,085
5,016,086
Url rewriting in asp.net 3.5
<p>I am developing an asp.net 3.5 application.I need to rewrite the url.My current url is,</p> <p><a href="http://app.evetos.com/Areas/UserV1/Controllers/Order1.aspx?EventID=JRQlVFOQDYs=&amp;status1=true" rel="nofollow">http://app.evetos.com/Areas/UserV1/Controllers/Order1.aspx?EventID=JRQlVFOQDYs=&amp;status1=true</a...
asp.net
[9]
2,306,238
2,306,239
Struct existence in functions/methods
<p>Say</p> <pre><code>a_function(mystruct::create().execute()); </code></pre> <p><code>create()</code> creates an instance of struct as <code>mystruct s()</code> then the method <code>execute()</code> returns something.</p> <p>does the struct continue to exist for the entire time the function is executed or is it re...
c++
[6]
4,775,553
4,775,554
Menu Control: How to Make Whole Item Clickable, not Just Text
<p>I have a problem that confuses my users, being that although an item is highlighted (by the hover style) when the user mouses over it, they have to mouse over the actual item text, sometimes quite small compared to the item. Is there a way to make the whole item clickable?</p>
asp.net
[9]
930,647
930,648
PHP crop image from base64_decode
<p>i am generating a screen grab jpg using html2canvas from this code. However i cant target a particaular div so i am grabbing the entire screen.</p> <pre><code>$canvasImg = $_POST['img']; $data = base64_decode($canvasImg); $File = "z.jpg"; $Handle = fopen($File, 'w'); fwrite($Handle, $data); fclose($Handle); </co...
php
[2]
4,730,305
4,730,306
How to read serial number on a Samsung device (from within app / on the device)?
<p>How to read the device <strong>serial number</strong> (not IMEI) of a <strong>Samsung Android phone</strong> (same value that you get when you call 'adb devices') but from within an app or from the device; not using PC/USB/adb.</p> <p>I found a solution for HTC and other devices, which is - to call </p> <pre><code...
android
[4]
986,099
986,100
php - strstr with an ending needle
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/3577641/how-to-parse-and-process-html-with-php">How to parse and process HTML with PHP?</a><br> <a href="http://stackoverflow.com/questions/3969907/php-get-part-of-string-by-searching-for-characters-instead-of-cou...
php
[2]
1,818,913
1,818,914
Resize dialog to take up more screen
<p>I have a dialog that setContentView on a layout. I have an editText and Button in the layout set width to match parent but that makes it only as wide as the setTitle. As I enter info into the editText, the dialog expands with each character. Is it possible to make the dialog look like below without setting a dp size...
android
[4]
3,674,355
3,674,356
Short hand to do something like: if($variable == 1 || $variable == "whatever" || $variable == '492') .
<p>I find my self doing this type of <code>IF</code> statement allot. For example: </p> <pre><code>if($variable == 1 || $variable == "whatever" || $variable == '492') { ... } </code></pre> <p>Except for allot of the time, I am comparing the $variable to maybe 4-5 things, sometimes more. Is there a short hand way ...
php
[2]
3,318,509
3,318,510
Android Development - ActivityManager: Starting: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] cmp=com.a/.Image }
<p>I am new to Android Development. While running an application, I am getting the following error:</p> <p>"ActivityManager: Starting: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] cmp=com.a/.Image }"</p>
android
[4]
4,630,628
4,630,629
iPhone App Store. Client submitting question
<p>I am writing an application which will be submitted by my client. I don't want to give them my source code, what must I do?</p>
iphone
[8]
5,167,690
5,167,691
How to make a timer to shutdown computer with c# windows form application
<p>i'm having trouble finding enough resources to create the windows form application that i want.As title says i want to create an application on which i can set a timer to shutdown computer.Any example or help would be appreciated.Regards</p> <p>Edit:so i've mananged to put current date/time button and individual sh...
c#
[0]
2,770,605
2,770,606
Cache online-file contents in String rather than local file
<p>I am downloading a text-file from example.com/test.txt and I need the contents only during the runtime of my app, they don't need to be saved to a static file.</p> <p>My code so far:</p> <pre><code> InputStream input = new BufferedInputStream(getURL.openStream()); OutputStream output = new F...
android
[4]
1,436,059
1,436,060
Dynamically import and create class instance
<p>With my python application, I have 40 modules (classes) which contain a parser for some text. In my function I only want to instanciate and use a particular module. These are all sorted in the database.</p> <p>I am at the point now where I know my parser, and have both the python file name and class I want to impor...
python
[7]
4,367,194
4,367,195
Showing GIF image at the time of the Upload
<p>HI,</p> <p>I am working on Asp.net 2.0 and C#.</p> <p>I stuck with one issue. </p> <p>I want to upload the file (Large file through upload control in asp.net). but at the time of uploading, want to see a animated gif image (In Process). I don't want to use Ajax and third party tool to upload. It's in plain asp.n...
asp.net
[9]
2,502,901
2,502,902
Get the width and height of an image
<p>How can I get the width and height of image? The image url is saved into a variable. Thank you.</p>
php
[2]
572,370
572,371
How can I find an element ID when I only know the text inside the element with jQuery?
<p>I have a form with id="main-form" and inside that there's a class="block-footer" </p> <p>Inside that an element: </p> <pre><code>&lt;button type="button"&gt;Submit&lt;/button&gt; </code></pre> <p>How can I use jQuery to find this button without my adding an Id to the element? The button always has the text of Sub...
jquery
[5]
2,967,146
2,967,147
the better method to store page hits in very crowded site
<p>I have website with too much traffic, I want to add a hits counter. what the better method to store that ? ihave 2 options <br/> 1- create DB and store hits in. <br/> 2- create local txt file and store hits in. <br/> the server is already over loaded so what would be better to avoid more pressure on the server ?</p>...
php
[2]
1,779,343
1,779,344
jQuery: dealing with a space in the id attribute
<p>I have an element with id="A B". The following code <strong>fails</strong>:</p> <pre><code>&lt;input type="text" id="A B"&gt; &lt;script&gt;$("#A B").click(function(){alert();});&lt;/script&gt; </code></pre> <p>The following code <strong>does not fail</strong>:</p> <pre><code>&lt;input type="text" id="AB"&gt; &l...
jquery
[5]
4,546,553
4,546,554
Android network stats
<p>Is it possible to create a application that gets network activity / statistics while running as a background process? Or just make a application that listen to traffic on a specific port?</p> <p>Thanks M</p>
android
[4]
2,150,845
2,150,846
MQ Pure Java Client Lib
<p>I am evaluating Websphere MQ7. I am a traditionally a TibRV guy. One thing I do not like is the fact that the IBM java client libs require C++ libs in order to run. Is there anyway to run the IBM java client libs without requiring the C++ libs? e.g. is there a pure java client library for MQ ?</p>
java
[1]
81,554
81,555
Android provider Entity Relationship diagrams?
<p>Has anybody ever seen an entity relationship diagram of Android's provider databases?</p> <p>I'm getting into the contacts database, and a bit into the media database. Boy would a diagram showing how the tables relate to each other really help.</p>
android
[4]
282,293
282,294
Unexpected end in PHP script
<p>I really can't find the error. Here is my code:</p> <pre><code>&lt;? // Action: add news if( array_key_exists('create_new', @$_POST) ) { ?&gt; ... &lt;? exit(); } ?&gt; </code></pre> <p>Before this my problem was in construction: <code>&lt;?=...;?&gt;</code> My web server (Apache) did not...
php
[2]
5,924,130
5,924,131
error: Use of unassigned local variable
<p>I have this method:</p> <pre><code>public static void Add(int _Serial, string _Name, long? _number1, long? _number2) { // ... } </code></pre> <p>and use this code for send date to method:</p> <pre><code>long? _num1; long? _num2; if (txtNumber1.Text != null &amp;&amp; txtNumber1.Text != "") { _num1= long.P...
c#
[0]
3,302,300
3,302,301
Using a subclass method on a base class object
<p>Let's say I have declared the following classes:</p> <pre><code>class BaseClass{ /* properties, constructors, getters, setters etc. */ public static BaseClass Create(string url){ /*will return, depending on url, a BaseClass or a SubClass object*/ } public void Method(){ /* some code here *...
c#
[0]
3,146,261
3,146,262
unexpected '[', expecting ')' - array in constructor
<p>I have this code:</p> <pre><code>class foo { public function __construct ( $bar[var1] = 0, $bar[var2] = 0, $bar[var3] = 0 ) { /* do something */ } } </code></pre> <p>and I get this error:</p> <blockquote> <p>Parse error: syntax error, unexpected '[', expect...
php
[2]
2,186,788
2,186,789
Passing in functions
<p>I want to overload a function without using optional parameters. When I use generics, I run into a problem; however, it works with simple types. I am confused so thanks for the help. Class B uses int to validate my syntax; while class C is what I want to accomplish. </p> <pre><code>using System; using System.Collec...
c#
[0]
1,155,761
1,155,762
How do I automate wrapping methods?
<p>I would like to automatically wrap all methods in an object with a function. For now, I only know how to do it one by one:</p> <p>jsfiddle: <a href="http://jsfiddle.net/4VuE7/" rel="nofollow">http://jsfiddle.net/4VuE7/</a></p> <p>code:</p> <pre><code>&lt;div style=white-space:pre&gt; &lt;i&gt;foo bar lorem ipsum&...
javascript
[3]
865,346
865,347
NullReferenceException causing w3wp to fail. How best to investigate?
<p>We have a problem in one of our web apps whereby a null reference exception is periodically causing the worker process to fail and the app pool to recycle. This is being logged in the windows event log from IIS but it doesn’t give sufficient information regarding the method or data that cased the fault. We do, howev...
c#
[0]
4,629,540
4,629,541
appending div, nested or below?
<p>I'm reading a book on JavaScript that's appending divs to other divs, and I just wanted to get a visual on what that actually looks like. i.e. is the appended div contained within that div it's appended to, or is it just added below it. Anyways, to figure this out, I created this fiddle which doesn't work <a href="...
javascript
[3]
5,965,799
5,965,800
Is there a better way to write these functions?
<p>I'm not a javascript programmer by any means, but this has been annoying me for the longest while,</p> <p>is there a better way to write these two seperate functions. As in a single function?</p> <pre><code>function showAll() { var collection = getElementsByClassName("dealHolder"); for (var x = 0; x &lt; col...
javascript
[3]
2,293,361
2,293,362
*** Terminating app due to uncaught exception 'NSRangeException', reason: '*** -[NSCFArray objectAtIndex:]: index (13) beyond bounds (13)'
<p>HI all,</p> <p>can anyone let me know,</p> <p>wat does dis means</p> <p><strong>* Terminating app due to uncaught exception 'NSRangeException', reason: '*</strong> -[NSCFArray objectAtIndex:]: index (13) beyond bounds (13)'</p> <p>so that i can solve my problem</p> <p>regards shishir</p>
iphone
[8]
5,480,778
5,480,779
jQuery JS Error on .click()
<p>When I click on the element I get the error <code>uncaught exception: Syntax error, unrecognized expression: .</code> which I'm not sure what to do with.... I see no errors</p> <pre><code>var tc = $('#tc-woot'); $('.sites .tab', tc).bind('click', function (e) { /*$(e.currentTarget).addClass('selected');*/ }); <...
jquery
[5]
5,840,959
5,840,960
why my following fiddle giving output without any print call?
<p>I have one piece of code as:</p> <pre><code>&lt;script type="text/javascript"&gt;&lt;!-- google_ad_client = "ca-pub-8514414755716493"; /* AdX_Washington_Examiner */ google_ad_slot = "9465392777"; google_ad_width = 320; google_ad_height = 50; //--&gt; &lt;/script&gt; &lt;script type="text/javascript" src="http://pag...
javascript
[3]
3,005,042
3,005,043
jQuery: filtering elements with multiple criteria
<p>so here's the basic idea. I have a list of links, and an array of href values, I want to filter the links so that my list only contains the links that have an href value that exists in the array. I can do this like so:</p> <pre><code>var filtered = unfiltered.filter(function() { for (var i = 0; i &lt; ids.leng...
jquery
[5]
1,590,838
1,590,839
C++ HelloWorld Compile Error
<p>When I try to compile my code I get an error. I followed this tutorial: <a href="http://www.youtube.com/watch?NR=1&amp;feature=fvwp&amp;v=EwvfBtC1nL4" rel="nofollow">http://www.youtube.com/watch?NR=1&amp;feature=fvwp&amp;v=EwvfBtC1nL4</a></p> <pre><code>#include "stdafx.h" #include &lt;iostream&gt; using namespa...
c++
[6]
3,775,953
3,775,954
Do I need to install python packages as root
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/10291922/what-are-site-packages-in-python-and-can-you-install-use-them-if-you-arent-root">What are site-packages in python and can you install/use them if you aren’t root?</a> </p> </blockquote> <pre><code>sudo ...
python
[7]
4,747,033
4,747,034
getting 0 on listView.getChildCount()
<p>I want to change the font and size of textlist that I created, but getting 0 on <code>listView.getChildCount()</code>.</p> <p>I want to change the font of text before display them. Here is my code:</p> <pre><code>public class NewsActivity extends ListActivity { public ReadXMLFile ReadXML; public ArrayList&l...
android
[4]
4,317,412
4,317,413
Asynchronous for cycle in JavaScript
<p>How could I do this...? Do you have any ideas? Thank you.</p> <pre><code>for ( /* ... */ ) { someFunction(param1, praram2, function(result) { // Okay, for cycle could continue }) } alert("For cycle ended"); </code></pre>
javascript
[3]
5,726,889
5,726,890
file not found error when reading excel file in java
<p>I am getting following error when I try to read an excel file in java although the file is present. I am in Windows environment. I have confirmed that that the file is present at that location. </p> <pre><code>java.io.FileNotFoundException: D:\myfile.xls (The system cannot find the file specified) at java.io.Fi...
java
[1]
3,575,166
3,575,167
Percentage Calculation for values less than 1 and greater than 0
<p>I am trying to display the percentage using BigDecimal.</p> <p>for example if i have to do </p> <pre><code> double val = (9522 / total ) * 100; System.out.println("Val is :" + val); </code></pre> <p>where total is 1200000.</p> <p>I want to display the calculation as a percentage but since the calculation...
java
[1]
3,670,022
3,670,023
Use of List inside map C++
<p>Can I use follwing syntax?</p> <pre><code> std::map&lt;int,std::list&lt;int&gt;&gt; mAllData; </code></pre> <p>Where Key Value(int) will be ID of data. and said data could have multiple types so storing all them against said key value. I am trying to use it. Can somenody provide sample code how this should work or...
c++
[6]
4,596,738
4,596,739
javascript persistent selection
<p>I need to only have 1 character at any time in an input field. The only way I can think of doing this is by having javascript keep everything in the box always selected and making the maximum input length 1 so that when I type something new, whatever was in there gets overwritten (since it is selected). That way I d...
javascript
[3]
4,649,121
4,649,122
How to fake a Android hardware device?
<p>I'm developing for Galaxy Note specifically. I want to test my app on a real device which I don't have. Is there some way I can fake a Galaxy Note on AVD?</p> <p>I do know how to create an AVD with hardware matching Note. However, that won't suffice. I want the app to identify AVD as a real device. I have small hin...
android
[4]
3,303,887
3,303,888
update query problem
<p>hi all i have a field "ammount" in mysql database which have "varchar(50)" type. When i insert data into that field e.g ammount= 4 kg its ok but when i update that field it gives me the following error.</p> <pre>Error in query: UPDATE ingredients SET ingredient_name='test recipe',ammount=4 gm where ingredient_id='5...
php
[2]
1,883,104
1,883,105
How to read sqlite file using cursor and display data in a listview
<p>Hi im trying to read sqlite file which is placed in assets/databases folder</p> <p>i followed this link to read data from sqlite file <a href="http://www.reigndesign.com/blog/using-your-own-sqlite-database-in-android-applications/" rel="nofollow">http://www.reigndesign.com/blog/using-your-own-sqlite-database-in-and...
android
[4]
3,726,158
3,726,159
What is the relationship of .lib and .obj to each other and my project in c++?
<p>What are how do .lib and .obj files relate to each other? What is their purpose? Is a .lib just a collection of .obj files? If so are the .obj's then stored inside the .lib making the .obj's unnecessary? </p>
c++
[6]
613,763
613,764
Javascript match error - Invalid quantifier
<p>i get an strange error "invalid quantifer" ... can somebody help me please?</p> <p><strong>html</strong></p> <pre><code>&lt;input type="text" value="5+5" id="test"/&gt; </code></pre> <p><strong>JS</strong></p> <pre><code> ups = {}; ups['2'] = new Array(); ups['2']['cmd'] = '#(\-|\+|\*|\/|)[0-9](,|[0-9]|)(\-...
jquery
[5]
1,636,946
1,636,947
JavaScript Broken Closures and Wrapper Function from John Resig #62 and #63
<p>The first example below is #62 from John Resign`s Learning Advanced JavaScript <a href="http://ejohn.org/apps/learn/#62" rel="nofollow">http://ejohn.org/apps/learn/#62</a>. It is called Fix the Broken Closures. Example 1 fails 4 times. Example 2, which is only different because it has a wrapper function, passes 4 t...
javascript
[3]
2,545,293
2,545,294
Can't get Javascript to set text
<p>I see examples for this all over, but for some reason, mine isn't working. I have a textbox that is added dynamically if a certain value is selected in a select list.</p> <p>The part where the field shows up is working, but I am also trying to add some text to the box, which I can't get to work. I'm also trying to ...
javascript
[3]
2,815,721
2,815,722
Tools and Libs to be a more productive .net web developer
<p>I am trying to get a list together of tools/libraries that make me more productive or more efficient.</p> <p>Tools I am using at this moment are ELMAH for all my logging or errors and exceptions.</p> <p>I am also using the JQuery validation library and been playing with xVal lately.</p> <p>I know there are simila...
asp.net
[9]
2,690,732
2,690,733
How can I separate Logic/UI in Android
<p>I want as my application to be structured in 2 parts: the logic code and the UI.</p> <p>I've tried to implement that using a controller class(here I keep the logic code) inside of each activity. The activity send messages to controller and receive the answer in two ways:</p> <ol> <li>the answer is returned immedi...
android
[4]
1,747,648
1,747,649
asp.net drop down list viewstate issue after client side Ajax update
<p>In my aspx page I have drop down list that initialy in page load event loads up with list of values which is shown to client(drop down list "A") and in client side, depending on client selecion of another drop down list(drop down list "B") I have written a javascript to update drop down list "A" with corresponding ...
asp.net
[9]
1,863,590
1,863,591
python: printing horizontally rather than current default prining
<p>I was wondering if we can print like rowwise in python. I know its kinda stupid question.. or maybe not even important.. Basically I have a loop which might go on million times and i am printing out some strategic counts in that loop.. so it would be really cool if I can print like rowwise</p> <pre><code>print x # ...
python
[7]
2,089,939
2,089,940
iPhone In-App Advertising
<p>I'm strongly considering making a free version of my app that is ad-supported, but I don't exactly understand how it works. Do you get paid every time an ad is displayed or only when the user taps it? Can someone please explain how it works?</p>
iphone
[8]
2,529,795
2,529,796
Run python script without printing newline at end?
<p>Whenever I run a python script, a new line is also printed at the end.</p> <p>The only way I can stop this is by using posix._exit(0) at the end to avoid Python's cleanup code. Is there a more portable way?</p> <p>(Sorry if this is a repeat question/seemingly obvious to answer. Unfortunately, I've only seen questi...
python
[7]
517,134
517,135
php - resize and save an image?
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/747101/resize-a-picture-to-a-fixed-size">Resize a picture to a fixed size</a> </p> </blockquote> <p>I am using the following php code to resize (the width) and save an image, the code is working no error but the...
php
[2]
1,983,506
1,983,507
Java help -> weird code
<p>Can someone explain to me this code </p> <pre><code> new Object[]{"PLease","Help"}; </code></pre> <p>Ive never seen code like this before,<br> so It would be helpful if someone explains these to me. Thank you in advance </p>
java
[1]
2,661,232
2,661,233
javascript inside a div loaded with ajax cant access functions outside the div
<p>I have my search results loaded into a div using an AJAX function and I am trying to add pagination to the bottom of the div which calls that ame function but I keep getting:</p> <pre><code>Uncaught ReferenceError: update_results is not defined </code></pre> <p>Here is the page: [link removed]</p> <p>There is a n...
jquery
[5]
3,192,518
3,192,519
Button on Custom Dialog Not Responding to Click Events
<p>I created a custom dialog that extends Dialog. One button on that the dialog is an “OK” button which the user is expected to press when finished entering information in other fields. I cannot get any listeners set to that button to fire.</p> <pre><code>public class HeightDialog extends Dialog { private Button...
android
[4]
4,443,233
4,443,234
Is wrapping new within the constructor good or bad?
<p>I watched John Resig's <a href="http://ejohn.org/blog/building-a-javascript-library/" rel="nofollow">Best Practices in JavaScript Library Design</a> presentation; one slide suggested "tweaking" the object constructor so it instantiates itself. </p> <pre><code>function jQuery(str, con) { if (window === this) { ...
javascript
[3]
4,969,363
4,969,364
post message to users wall
<p>i am creating a iphone application using Facebook SDK.I want to post message to friends wall.can u help me to implement this..</p>
iphone
[8]
4,852,639
4,852,640
contain new elements of an "instance" in javascript
<p>so I know there are tons of ways to simulate inheritance and other OO features. I have chosen one to use for my project and am wondering if I can create an instance and add stuff to it and keep it contained (within braces). Consider the following:</p> <pre><code>function BaseClass(){ &lt;this.stuff here&gt; } f...
javascript
[3]
1,033,000
1,033,001
System process listener in python
<p>Is there any way to notify when the system process started, terminated or completed.</p> <p>I am searching kind of listener that listen events of the system, such as process start, stop etc.</p>
python
[7]
2,717,944
2,717,945
find the pattern in java
<p>I need to find the method to find the following pattern is in the given string or what. <code>#8226:</code>. Here numbers can be anything, that should be start with #, end with : and should contains 4 numbers(4 digits).</p>
java
[1]
5,898,096
5,898,097
What is "String args[]"? in Java
<p>I'm very beginner for programming.</p> <p>In Java.</p> <pre><code>public static void main(String []args) </code></pre> <p>What's String args? and What kind of case do you use args at? I am fortunate when I have you teach it with source codes and examples.</p>
java
[1]
273,507
273,508
Javascript onclick executing without click
<p>I am attaching onclicks to buttons with the function I want to be called when the event happens. When running the page, it goes ahead and executes the function for onclick without clicking. </p> <pre><code>window.onload=function(){ var recipeCount = 0; //gets the recipes and puts them in the menu bar #left //places...
jquery
[5]
1,909,312
1,909,313
set interval() not showing number one by one
<p>Hello friend i tried to show number 1 to 4 one bye one with loop my code is </p> <pre><code>&lt;script&gt; $(document).ready(function(){ setInterval(function() { var i = 1; for(i=0; i&lt;=5; i++) { var dis = $('#fade'); dis.html(i); ...
jquery
[5]
3,495,561
3,495,562
ASP.NET Processing lambdas
<p>What is the code clean up needed on the following linq inorder to validate Email IDs</p> <p><strong>Error:</strong> <strong><code>var validemails = emails.Where(p=&gt;IsValidFormat(p)).Select;</code></strong></p> <pre><code> Dictionary&lt;int, string&gt; emails = new Dictionary&lt;int, string&gt;(); emails.Add(1...
c#
[0]
2,809,484
2,809,485
multi-dimensional stdClass Object
<p>I've got a rather large multidimensional stdClass Object being outputted from a json feed with PHP.</p> <p>It goes about 8 or 9 steps deep and the data that I need is around 7 steps in.</p> <p>I'm wondering if I can easily grab one of the entires instead of doing this:</p> <p>echo $data->one->two->anotherone->get...
php
[2]
2,715,963
2,715,964
Need to post JSONObject to PHP server through parameter
<p>From past couple of hour I was trying to send JSONObject to a PHP server. I need to send this object through a parameter.</p> <p>Some what like this:</p> <pre><code>message={"name":"Firstname","email":"test@test.com"} </code></pre> <p>here message is my parameter name.</p> <p>Yes I am using HttpClient for postin...
android
[4]
75,364
75,365
Jquery animate scrolling not working properly
<p>I have a div with a table inside and several content divs in cells. This div has a vertical scroll bar that I would like to move via jquery code. I have some animation code that does move the scroll bar after clicking an anchor link. However the scroll bar movement is not consistent and only rarely goes to my desire...
jquery
[5]
3,855,209
3,855,210
Android how to set ScrollBar in Edittext?
<p>I am new to Android i want to ScrollText in Edittext and also show Scrollbar at corner.I Scroll theText By Using</p> <pre><code>questionEntry.setScroller(new Scroller(myContext)); questionEntry.setMaxLines(1); questionEntry.setVerticalScrollBarEnabled(true); questionEntry.setMovementMethod(new ScrollingMovementM...
android
[4]
347,032
347,033
How to have drawn objects(g.draw(...)) respond to mouse events?
<p>I have this program where it draws a bar graph in a JFrame. The bars of the bar graph change color when I click on them. So my question is whats the best way to approach this? The bruteforce way,i.e. calculate the mouse click and see if it falls within the bars' range, or extends the BufferedImage class and have ...
java
[1]