Unnamed: 0
int64
65
6.03M
Id
int64
66
6.03M
Title
stringlengths
10
191
input
stringlengths
23
4.18k
output
stringclasses
10 values
Tag_Number
stringclasses
10 values
4,006,316
4,006,317
Calling a class and returning data?
<p>I'm a bit of a newbie, so some help here would greatly be appreciated. I have a class called Device which gets a devices screen size:</p> <pre><code>int Device::GetDisplay() { DisplayInfo display; int displayArray [2]; displayArray[0] = display.pixelSize().width(); displayHeight[1] = display.pixelSize().height(...
c++
[6]
8,137
8,138
Android chromium disk_cache error : Corrupt Index file
<p>I am just trying to do a -</p> <pre><code>webView.loadUrl("http://www.google.com"); </code></pre> <p>But I get blank page with the following error in the log-</p> <blockquote> <p>07-05 17:20:30.623: E/chromium(1243): external/chromium/net/disk_cache/backend_impl.cc:2022: [0705/172030:ERROR:backend_impl.cc(2...
android
[4]
4,820,313
4,820,314
when I use global scope variable without 'var', its showing me Error. why?
<p>See my example code below</p> <pre><code>&lt;script&gt; alert(a); // undefined alert(b); // It is Error, b is not defined. var a=1; b=10; &lt;/script&gt; </code></pre> <p>When both variable a and b are in global scope, why I am getting error message for b. But there is no error message for variable a ? what is the...
javascript
[3]
720,515
720,516
hiding a div when the mouse is a certain distance away from that div
<p>I have a div on a page which is toggled by an item in a navigation bar. What I'd like to do is have that div hide when the user's mouse gets a certain distance away from the div's outer boundry.</p> <p>Here's some example code:</p> <pre><code>&lt;ul&gt; &lt;li&gt;This is link A&lt;/li&gt; &lt;li&gt;This is link C&...
jquery
[5]
5,399,267
5,399,268
Difference between "==" and "===" in java script
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/359494/javascript-vs-does-it-matter-which-equal-operator-i-use">Javascript === vs == : Does it matter which &ldquo;equal&rdquo; operator I use?</a> </p> </blockquote> <p>Hi I am not clear why there are two <code...
javascript
[3]
144,942
144,943
Getting list element's Attribute
<p>I have two list. List1 contain objects and each object has node1 property. List2 contain lists of node which are the properties of objects stored in list1.</p> <p>I want to create separate list which contain list of objects whose node present in list2. I want to create this list without using for loop because my ob...
python
[7]
3,715,154
3,715,155
Filtering or sorting causes page to reload
<p>Applying sorting or filters on the ASPXGridview causes the page to refresh. How can I prevent this? This is kind of annoying to the users. The enablecallback property for the ASPXGrid is set to false.(I want it to be false). Also that causes all the user selection to go away(checkboxes,radiobutton defaults to the or...
asp.net
[9]
1,371,246
1,371,247
$_SERVER['REQUEST_URI'] doesn't work when #text at the end of url
<p>I know $_SERVER['REQUEST_URI'] works in getting the current page's url, but it leaves out the #post at the end of the url. I like to use the #blah at the end to make the page scroll to a certain point. Example:</p> <pre><code>index.php#answer </code></pre> <p>using $_SERVER['REQUEST_URI'] just returns:</p> <pre>...
php
[2]
1,192,145
1,192,146
Retrieve action layout from ActionBar, inside fragment
<p>How do I retrieve a action layout for an item inside the ActionBar, from a Fragment. I have tried to access the layout directly via getActivity().findViewById, and via getActivity().findViewById(MenuItem).findViewById(ActionLayout).</p> <pre><code>@Override public void onViewCreated(View view, Bundle savedInstanc...
android
[4]
1,187,152
1,187,153
utilities of AdWhirl over other ads Network
<p>Can anyone tell me what are the advantages of using Adwhirl in comparism to AdMob,Millenial,Google AdSense for Mobile Applications,ZestADZ.Is there any disadvantage if i use AdMob or ZestADZ instead of AdWhirl...</p> <p>with regards Anshuman</p>
android
[4]
3,709,360
3,709,361
Click Event not working in windows mobile 6.0 application
<p>I am currently doing a project on windows mobile application 6.0 all the application was working fill till i add a .dll file now it shows the error as shown below <img src="http://i.stack.imgur.com/izy4x.png" alt="enter image description here"></p> <p>The events are not working after adding that dll</p>
c#
[0]
2,753,132
2,753,133
making vars for elements not yet created
<p>I am trying to create a var for a dom element to clean things up but it doesn't give me expected results. The reason I think it's doing this is because the element isn't yet created when I run the function. I could move the var after the .prepend() is called but what if I'd like to keep all my vars at the top?</p> ...
jquery
[5]
3,991,231
3,991,232
How to implement a Required Property in Python
<p>If I have a class such as below (only with many more properties), is there are clean way to note which fields are required before calling a particular method?</p> <pre><code>class Example(): def __init__(self): pass @property """Have to use property methods to have docstrings...""" def pro...
python
[7]
1,386,473
1,386,474
Why is main() in java void?
<p>In the case of languages with a C-like syntax, we declare the main() method to return an int or float value (or void). Is it possible to declare a non-void return type from main() in Java? If not, then why not? Does this mean that a Java program doesn't return any value to the OS?</p>
java
[1]
3,550,355
3,550,356
A property exists in the parent class, but can't be used from the child class
<p>EDIT: SOLVED!</p> <p>I have been working on my own framework lately. I have a controller class like this:</p> <pre><code>class Controller { private $model; public function __construct() { global $bean_db, $mv_name; if (file_exists(APP_PATH . 'models/' . $mv_name . '.php')) { r...
php
[2]
2,464,017
2,464,018
How to read "Builder Number" from "About Phone" settings in android?
<p>I'm trying to read which ROM the user is using from my app.</p> <p>It seems that this info can be seen in the phone's settings, in the About Phone setting under "Build Number".</p> <p>How can I read this info with code?</p> <p>Couldn't see it with <code>android.os.Build class</code>..</p> <p>Thanks.</p>
android
[4]
2,943,564
2,943,565
URLEncoder.encode() and a whitespace?
<p>I've got a resource on my server named:</p> <pre><code>some image.png </code></pre> <p>There's a space in the name. When I type the url into the browser (chrome), it's transforming the space into %20:</p> <pre><code>some%20.png </code></pre> <p>WHen I use URLEncoder.encode("some image.png") from my application, ...
java
[1]
3,965,645
3,965,646
Encryption message in java
<p>i am a project about using java's bouncycastle to do the encryption.</p> <p>However, when I encrypt the message, it throws an exception for me.</p> <p>javax.crypto.IllegalBlockSizeException: data not block size aligned</p> <p>I am using Blowfish/ECB/NoPadding, and the message is an xml.</p> <pre><code>public sta...
java
[1]
1,474,657
1,474,658
Check If Word Is In A String errors
<p>Using the following from <a href="http://stackoverflow.com/questions/5319922/python-check-if-word-is-in-a-string">Python - Check If Word Is In A String</a></p> <pre><code>&gt;&gt;&gt; def findWholeWord(w): ... return re.compile(r'\b({0})\b'.format(w), flags=re.IGNORECASE).search ... &gt;&gt;&gt; findWholeWord(...
python
[7]
5,868,583
5,868,584
where we get the source of K9 email client for android?
<p>K9 mail client is open source android application. Where can we get the source files ?</p>
android
[4]
2,239,425
2,239,426
page.response - can't set it in asp.net
<p>I generate a PDF document inside a helper method. the helper method returns a HttpResponse object, which is the response containing the generated PDF. But I can't change the page.response to the one the method returned. How shuld I solve this?</p>
asp.net
[9]
3,059,156
3,059,157
how do i obtain system info from my app?
<p>Im making an app for my website, I need to know the system info of whoever installs my app,</p> <p>I have an email.java Activity class, i am wondering if its possible to add the system info as an attachment or on the bottom of whatever's typed,</p> <p>I also have a text.java Activity which id like to do same if po...
android
[4]
3,625,709
3,625,710
Class extending Application in Android project library?
<p>I have a project (in Eclipse) which I've turned into an Android Project Library so as to re-use some of the code in another similar project. I think I've shot myself in the foot however as I'm getting the error:</p> <pre><code>Unable to start activity ComponentInfo{com.test.scroller1/com.lib.scrolltest.ScrollTestA...
android
[4]
4,592,706
4,592,707
Appending data in UITextField programmatically
<p>I am creating a report &amp; printing the same on a UITextView.My report has some titles and there respective subtitles. I am printing 1st title then its subtitle &amp; then second title and its subtitle and so on. I want different font and font sizes for the titles and subtitles. But the problem is the text field a...
iphone
[8]
4,655,934
4,655,935
how to open new IE window on click of hyperlink
<pre><code>&lt;asp:HyperLink id="hyperlink1" NavigateUrl="&lt;%#Eval('name')%&gt;" Text="&lt;%#Eval('name')%&gt;" Target="_blank" runat="server" /&gt; </code></pre> <p>here the text that i have binded to navigate url can be any url (eg:asp.net,google.com)</p> <p>this is my code when i try to open a new iE ...
asp.net
[9]
3,173,286
3,173,287
Understanding Python Numerology
<p>We can not declare an integer which start with 0.</p> <pre><code>&gt;&gt;&gt; n = 08 SyntaxError: invalid token </code></pre> <p>But we do declare a variable that contains all zeros.</p> <pre><code>&gt;&gt;&gt; n = 00000 &gt;&gt;&gt; print n &gt;&gt;&gt; 0 </code></pre> <p>So the question is in first case why py...
python
[7]
4,298,089
4,298,090
Python Global File
<p>How can I write to a global file inside of a function?</p> <p>Example:</p> <pre><code>output_file=open("output_file_name.txt", "w") def write_to_file: global output_file output_file.write('something') write_to_file() output_file.close() </code></pre> <p>The code above is not working. It says "V...
python
[7]
2,202,018
2,202,019
how to control mediaplayer volume
<p>I created a simple application. In my main activity class i use this to play a sound when a button is clicked</p> <pre><code>MediaPlayer buttonSound = MediaPlayer.create(this, R.drawable.button_sound); public void onClick(View arg0){ buttonSound.start(); } </code></pre...
android
[4]
5,104,938
5,104,939
How can I implement this javascript "Superfast Blur" in my website?
<p>I was looking for a JavaScript code to make my images blurred till I found this good looking script "Superfast Blur"</p> <p><a href="http://www.quasimondo.com/BoxBlurForCanvas/FastBlurDemo.html" rel="nofollow">http://www.quasimondo.com/BoxBlurForCanvas/FastBlurDemo.html</a></p> <p>the problem is I know nothing abo...
javascript
[3]
5,368,972
5,368,973
Character.valueOf
<p>I run this method: </p> <pre><code>String str=Character.valueOf(char).toString() </code></pre> <p>The output comes like a small square at console and just like a bar code in the file. What the actual format of the output is, also the output is not able to copy.</p>
java
[1]
3,911,704
3,911,705
check string for youtube link or image
<p>I have a small piece of code that checks a string for a url and adds the &lt; a href> tag to create a link. I also have it check the string for a youtube link and then add rel="youtube" to the &lt; a> tag. </p> <p>How can I get the code to only add rel to the youtube links?</p> <p>How can I get it to add a differe...
php
[2]
1,057,788
1,057,789
how to connect sqlite to an android application?
<p>I am trying to connect my android application to sqlite, i dont knw how to configure SD card in emulator to have a database... can anyone help me please?</p>
android
[4]
5,321,831
5,321,832
Scrolling up and down with HTML page in android
<p>I had put an question in StackOverflow yesterday but could not get the answer. I am attaching the url for the same <a href="http://stackoverflow.com/questions/8790080/scrolling-with-static-html-page-not-working-saved-in-assets-folder-in-android">Question link</a> looking for the answer. I am using WebView to render ...
android
[4]
1,820,168
1,820,169
How to use readlines to read from file and return the abbreviation of item
<p>file looks like this:</p> <pre><code>BURGER KING BRG MCDONALDS MCDNLDS WENDYS WNDY </code></pre> <p>Example:</p> <pre><code>food('abbreviations.txt') Enter a fast food place: McDonalds Abbreviation: MCDNLDS Enter a fast food place: Thank you! </code></pre> <p>so far:</p> <pre><code>infile = open(filename, '...
python
[7]
2,339,481
2,339,482
How to refactor the C++ code to support the dynamic array size
<p>I need to get rid of fixed array size in C++/ODBC apps. Instead the hardcoded array size (ROWS =10 below) I want to pass the ROWS as the command-line argument. I know how to parse the command line. But how to adjust the following code?</p> <pre> #define ROWS 10 SQLINTEGER idata[ROWS] SQLCHAR cdata1[...
c++
[6]
969,942
969,943
Any good freeware advanced ASP.NET grid control available on the web?
<p>Was just wondering if there were any good free advanced asp.net grid controls that are available for use on the web? I know a few but they are payable and only have free trial versions e.g Telerik Radgrid controls or obout suite. </p>
asp.net
[9]
1,544,818
1,544,819
Could a service bind another service
<p>I just want to know could I bind a service from another service. For example, currently I have an <code>activity A</code> starting a <code>service B</code> and now I just want <code>service B</code> to bind and start another <code>service C</code>. So does anybody know how to do that? That means could I use the same...
android
[4]
2,456,328
2,456,329
malloc: *** error for object 0x1001002e0: pointer being freed was not allocated
<p>please help me I am running the code of api microtik, but I have this error</p> <pre><code> malloc: *** error for object 0x1001002e0: pointer being freed was not allocated *** set a breakpoint in malloc_error_break to debug </code></pre> <p>any body could help me?</p>
c++
[6]
745,033
745,034
Only top corners rounded in <shape>
<p>I am trying to have the top corners of a shape rounded and the bottom just straight, but I'm having a problem with my shape it's saving </p> <blockquote> <p>error! UnsupportedOperationException: null</p> </blockquote> <p>When I have </p> <pre><code>&lt;corners android:radius="10dp" android:bottomRightRadius="...
android
[4]
1,253,228
1,253,229
Is it possible to chain multiple events with one function in jQuery
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/451795/jquery-event-chaining">Jquery event chaining</a> </p> </blockquote> <p>Traditionally we may write:</p> <pre><code> $("selector").click(function () { }); </code></pre> <p>but is it possible to ch...
jquery
[5]
5,197,880
5,197,881
Align include images to base when using to Html.fromText
<p>I have a code like this.</p> <pre><code>Button b = findViewById(R.id.button); mImgGetter = new MiniImageGetter(this); b.setText(Html.fromText("&lt;img src=\"foo\"&gt; FOO!"),mImgGetter,null) </code></pre> <p>where MiniImageGetter is a class like:</p> <pre><code>class MiniImageGetter implements ImageGetter { p...
android
[4]
916,990
916,991
Error starting executable, no provisioned ios device is connected
<p>Why am I seeing this error? Is it looking for my real iphone device to be connected to install it on their?</p> <p>I just downloaded the views sample code from: <a href="http://www.sunsetlakesoftware.com/sites/default/files/Fall2010CourseNotes/views%20and%20controllers.html" rel="nofollow">http://www.sunsetlakesof...
iphone
[8]
4,432,090
4,432,091
page expired message in php script
<p>i am working on an e-commerce website using php. i have tried post/get and now session but problem is persisting. when i hit back button it display message page has expired. i thought may be i am not handlling session variables proparly but i dont know what to do ? what could be cause ans what could be solution .</...
php
[2]
947,358
947,359
what is the problem with android while downloading? can any one figure out?
<p>The following link downloads a file from a site.it works fine in desktop browser. but it is not working in android default browser and in webview code(i used download listener too but not working).</p>
android
[4]
2,515,499
2,515,500
Create top ten list of items in php
<p>I would like to create an app where my users can create their top ten movies assigning values from 1 to 10. Each user will be able to choose from my movies data table. For examle my data contains 100 movies and each user can give values (1 to 10) to 10 of them.</p>
php
[2]
805,352
805,353
What is the best method to retrieve the value of "Sum = ####" from List View using jQuery?
<p>Here's a little challenge for you SharePoint and jQuery experts. I have an out of the box list view in MOSS where I total one of the columns as a "Sum" so that at the very top of my list I have "Sum = #####". </p> <p>What I want to know is the most efficient script that would be to pull the text "Sum = ###,###" ou...
jquery
[5]
2,486,474
2,486,475
jQuery on() method not working for appended elements
<p>I know I should use on() method for triggering appended elements and not use click(), so:</p> <pre><code>$('#change_profile_img').on('click', function(){ alert(1); }); </code></pre> <p>so the above code is working fine on any elements unless the appended elements, for example, I'm appending:</p> <pre><...
jquery
[5]
1,945,612
1,945,613
accessing serverside code from client program
<p>How can I access server side functions from the HTML code? See the following code:</p> <pre><code>&lt;a id="Taggloud" runat="server" class="lblTagCloud" onClick="TagOnCloud_Click"&gt;click&lt;/a&gt; </code></pre> <p>Here I'm calling the <code>tagonCloud_click</code> function that's defined in server side(code behi...
asp.net
[9]
318,809
318,810
How to load images from server properly?
<p>I have a code below, this code works perfectly fine when you are trying to load one or two images. However, the problem is, when you have a lot of images in one Activity, all images must load first before you can get in. My question is, what is the best way to handle this images? I want the images to load one by one...
android
[4]
4,606,358
4,606,359
Android imagebutton does not flash on click
<p>I've implemented an ImageButton. All works well except when I press on it, it doesn't "flash" before moving on (to another activity). Does Android has intrinsic "flash" for ImageButton or I have to write/animate that explicitly inside onClickEvent? or use Selector? </p> <p>Thanks in advance for all your help.</p>
android
[4]
5,060,085
5,060,086
Function that takes a string as input and counts the number of times the vowel occurs in the string
<p>So I am very new to python and am in the process of learning the basics. I am trying to create a function the counts the number of vowels in a string and returns how many times each vowel occurs in the string. For example if I gave it this input, this is what it would print out.</p> <pre><code> &gt;&gt;&gt;countV...
python
[7]
5,095,525
5,095,526
Python - Getting all links from a div having a class
<p>I am using BeautifulSoup to get all links of mobile phones from this url <a href="http://www.gsmarena.com/samsung-phones-f-9-0-p2.php" rel="nofollow">http://www.gsmarena.com/samsung-phones-f-9-0-p2.php</a></p> <p>My code for the following is :</p> <pre><code>import urllib2 from BeautifulSoup import BeautifulSoup ...
python
[7]
2,928,099
2,928,100
Android equivalent to applicationDidBecomeActive and applicationWillResignActive(from iOS)
<p>I hope it exists.</p> <p>I would like to store the time when the application loses focus and then check if it has lost focus for more than n-minutes to bring up a lock.</p> <p>Seeing how an application is composed of activities, I think there will not be a direct equivalent. How would I be able to achieve similar...
android
[4]
1,745,726
1,745,727
How can extract images from pdf file using itext library in my android application
<p>I want to extract images from pdf file using itext library where i put my pdf files in asset folder on android application and display these images in android using itext library.</p>
android
[4]
2,170,753
2,170,754
Can The Application Icon in the Built In Search Dialog Be Clickable?
<p>Is there anyway to capture when the user clicks on the application icon in the built in search dialog? Please note I am NOT referring to a custom dialog but to android built in search dialog.</p>
android
[4]
4,248,065
4,248,066
Assign a hidden field value on default.aspx using BasePage Class methods
<p>Is that possible? The reason why am doing this is because I need to parse that variable into a an JQuery function so I wanted JQuery to read that field. Can I Assign that value in base class or I have to do it within default.aspx pageload method?</p>
asp.net
[9]
2,908,801
2,908,802
PHP: still work even if not isset
<p>HTML new_password:</p> <pre><code> &lt;input name="new_password" type="password" maxlength="25" id="new_password" class="ModuleTextbox" onkeyup="var regex = new RegExp(/^.*(?=.{6,})(?=.*\d)(?=.*[aA-zZ@!¤&amp;amp;/()_?,.-]).*$/m); if(regex.test(this.value)) { pwok.style.visibility = 'visible'; } else { pwok.style....
php
[2]
2,417,390
2,417,391
What attributes are not stored in __dict__ and why are they not?
<p>In Python, a lot of the "special" attributes of objects are stored in the <code>__dict__</code> dictionary, like <code>__doc__</code>, <code>__module__</code> (from what I could see in my experiments).</p> <p>However some are not, like <code>__class__</code>. My question is exactly which attributes are not stored i...
python
[7]
2,960,367
2,960,368
Should displaying an unsigned char* & an signed char* output exactly the same result
<p>I am unsure if I am correctly translating/converting a unsigned char* to a regular signed char*?</p> <p>The unsigned char* is a string that has been hashed. Does the following code correctly convert an unsigned char* to signed char*?</p> <pre><code>std::string message = "to be encrypted"; unsigned char hashMessage...
c++
[6]
2,520,979
2,520,980
Remove one option from dropdown based on the option selected in the before dropdown list
<p>Here is my HTML Code. </p> <pre><code> &lt;table&gt; &lt;tr&gt; &lt;td&gt; &lt;select class="dropdown"&gt; &lt;option value=""&gt;Select answer&lt;/option&gt; &lt;option value="1" selected="selected"&gt;A&lt;/option&gt; &lt;option value="2"&gt;B&lt;/option&gt; &lt;option value="3"&gt;C&lt;/o...
jquery
[5]
1,589,189
1,589,190
Parsing plain text that contains custom conditionals
<p>I presume this is a weird sort of thing that I'm looking for.</p> <p>I have the following text string:</p> <pre><code>$string = "The compass is pointing &lt;north|south|east|west&gt; towards &lt;London|Paris|Rome&gt;"; </code></pre> <p>Somehow I want to parse this to obtain any of the following outputs:</p> <ul>...
php
[2]
5,379,629
5,379,630
getElementsByTagName: How to select more than one type of tag?
<p>I have a for loop inside which I check to see if the current element being iterated has any <code>a</code> tags or <code>form</code> tags inside of it and if so I do some stuff to them. Anyway I can check either or like so:</p> <pre><code>var form_or_a_tag = elem[i].getElementsByTagName('a'); var form_or_a_tag = el...
javascript
[3]
2,260,006
2,260,007
Creating blurring effect on both sides of ViewPagerIndicator
<p>I realize, for Google Play market, they have "blurring" effect on left right (See "Paid" on left, and "Trend" on right, as in attachment)</p> <p>I was wondering, is it possible to achieve such effect using <a href="https://github.com/JakeWharton/Android-ViewPagerIndicator/" rel="nofollow">ViewPagerIndicator</a>? As...
android
[4]
5,772,037
5,772,038
Why does C# Math.Floor() return Double instead of Int
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/1348892/why-does-math-floordouble-return-a-value-of-type-double">Why does Math.Floor(Double) return a value of type Double?</a> </p> </blockquote> <p>Why does C# <code>Math.Floor()</code> return <code>double</co...
c#
[0]
3,896,995
3,896,996
Is it safe to change application properties?
<p>I see that my application has the wrong name.</p> <p>When I go to:</p> <p>Project -> Application properties...</p> <p>I see an <code>Assembly name</code> and a <code>default namespace</code>.</p> <p>Is it safe to just change these two to the values which would better represent my app or will it break something?<...
c#
[0]
231,380
231,381
Frontcontroller help
<pre><code>RewriteEngine On RewriteCond %{REQUEST_FILENAME} -s [OR] RewriteCond %{REQUEST_FILENAME} -l [OR] RewriteCond %{REQUEST_FILENAME} -d RewriteRule ^.*$ - [NC,L] RewriteRule ^.*$ /index.php [NC,L] </code></pre> <p>php</p> <pre><code>&lt;?php $pagesDir = "pages"; // Get the request $page = $_SERVER['REQUEST_U...
php
[2]
2,664,345
2,664,346
Get the Key pressed on an editText
<p>I want to know which key has been pressed in the edittext. For eg: if 'a' is pressed I want to get it as 'a'. Please help me.</p>
android
[4]
2,407,688
2,407,689
Reverse substring for double extension files
<p>How can i add reverse substring for "<strong>test.csv.txt</strong>" this type of files using javascript? </p>
javascript
[3]
452,831
452,832
Is it possible to set up an open URI for Android application?
<p>From this article: <a href="http://developer.android.com/guide/publishing/publishing.html#marketintent" rel="nofollow">http://developer.android.com/guide/publishing/publishing.html#marketintent</a></p> <p>Android Market could be invoked by an ACTION_VIEW intent with URI like </p> <pre><code>http://market.android.c...
android
[4]
1,028,381
1,028,382
How to give the progress value morethan hundred to progressview
<p>I am developing one application.In that iam using the progress view.In this i need to give the progress value more than hundred.If i give more than hundred then that fill the total bar.So please tell me how to do this one.</p>
iphone
[8]
1,675,951
1,675,952
php constant case-insensitive issue
<p>I'm overriding a constant with case in-sensitive parameter. But php doesn't give me "constant already defined" error. I've enabled E_ALL,E_STRICT errors. Example:1</p> <pre><code>define('ONE',1000); define('one',2000,true); echo ONE; // prints 1000 echo one; // prints 2000 </code></pre> <p>In the second line, i'm ...
php
[2]
2,084,009
2,084,010
How can I stop an ASP.NET website from loading depending on a certain condition?
<p>How can i stop asp.net website?<br> I want check some condition and after that if something's wrong then stop website from loading.</p>
asp.net
[9]
3,056,022
3,056,023
c# return concatenation of properties
<p>i have a class:</p> <pre><code>public class LabOccurrenceForm { public DateTime Occurrence_Date { get; set; } public string Cup_Type { get; set; } public string Analytical_Testing_Phase { get; set; } public string Area { get; set; } publ...
c#
[0]
3,616,405
3,616,406
Get Activity object from Custom Preferences
<p>I am trying to integrate facebook-connect to my android application. All the examples i am seeing over the internet are creating the connection from an Android activity. I am doing something a bit different, the user can configure its connection to facebook from a custom preference. I was successfull when doing it f...
android
[4]
1,393,633
1,393,634
Sorting files with the same first 3 letters, than deleting the older files?
<p>I had a question last week, and you quickly alleviated any concern that it would roadblock me, hoping that you can help a beginner program once more!</p> <p>I'm trying to automate one of my daily mundane tasks and it's being quite a bugger, I think mainly because I'm not taking the correct approach.</p> <p>Each mo...
c#
[0]
3,692,685
3,692,686
Set specific background color of image to transparent using JS
<p>I'm using the following code to modify the transparency on an image. What I would like to do however is only modify the background color of the image and set its alpha channel to 0 instead of the entire image.</p> <p>Following code sets the alpha transparency to 0 for the entire image:</p> <pre><code>var ctx = thi...
javascript
[3]
1,365,702
1,365,703
can help me to solve ListView?
<p>I am new in android. I dont know to list items in android? Can anyone help me with this?</p>
android
[4]
46,224
46,225
How to switch the server in apk
<p>I have one test apk which is pointing 3 different environments.</p> <p>Is there any way to switch from one to another environment or Is there any app to switch between one server to another?</p> <p>Thanks Chandra</p>
android
[4]
4,400,693
4,400,694
which is the use of position and name in putextra?
<p>How do I use <code>.get[position]</code> and <code>name</code> in <code>.putextra</code> in Android, and how can I use <code>position</code> in <code>putextra</code> using an array?</p> <pre><code>ainListView = (ListView) findViewById( R.id.mainListView ); mainListView.setOnItemClickListener(new OnItemClickListener...
android
[4]
5,541,540
5,541,541
Python out params?
<p>Is it possible to do something like this:</p> <pre><code>def foo(bar, success) success = True # ... &gt;&gt;&gt; success = False &gt;&gt;&gt; foo(bar1, success) &gt;&gt;&gt; success True </code></pre> <p>Does Python have out params, or an easy way to simulate them? (Aside from messing with parent's stack ...
python
[7]
4,537,742
4,537,743
How can i set theme at run time?
<p>Please Anyone know how to set theme using runtime? getApplication().setTheme() not set theme?</p> <p>How can i set theme when user select the button and it will set the theme in my application?</p>
android
[4]
2,597,432
2,597,433
Center a formatted row of integers in Python?
<p>I am a bit new to Python, having dabbled in VB.NET, C, and a few other odd languages, so I am finding the approaches used before don't always apply to Python. In this case, I want to print out a series of integer values into columns and center them in as small amount of code as possible.</p> <p>With plain strings,...
python
[7]
3,454,496
3,454,497
Android ACTION_SEND different texts for each application
<p>I'm using an Intent with ACTION_SEND and I need to share different texts. I need to send a text for Gmail and I need to send other text for twitter. depends on the application. Can I get the application selected by the user before the application sends the text shared?</p>
android
[4]
3,214,032
3,214,033
rss feed android example
<p>I am working on Nasa image of the day example from head first android. In the last step below code is showing error.</p> <pre><code> public void resetDisplay(String title, String date, String imageUrl, String desc){ TextView titleView = (TextView) findViewById(R.id.ImageTitle); titleView.setText(...
android
[4]
2,039,426
2,039,427
GridView Inital Editing mode?
<p>I am writing a web application that is used for tracking and entering some everyday user data... Every day I need to enter some data for multiple users manually...</p> <p>I will choose the date with the calendar, and for that date I will get DB values assigned for all users on chosen date...If there are some entrie...
asp.net
[9]
5,531,202
5,531,203
Comparing two list
<p>I have two string list -</p> <pre><code> List&lt;string&gt; ObjList1; List&lt;string&gt; ObjList2; </code></pre> <p>How can I compare these two list efficiently, such a way that these should have exact match of parameter regardless of their order in the list? (count as well as exact match of string regardless of ...
c#
[0]
5,184,826
5,184,827
Php syntax problem
<pre><code>&lt;input type="radio" name="ques1" value="op4"&gt;Jingles&lt;br&gt; </code></pre> <p>just a part of the code..... when i am checking this... iam doing this as </p> <pre><code>$selected=$_POST['ques1']; </code></pre> <p>now when i am doing this with for loop....</p> <pre><code>for($i=0;$i&lt;...;$i++) $s...
php
[2]
1,958,459
1,958,460
What tricks did Fabrice Bellard use to make his PC emulator in Javascript so fast?
<p>Fabrice Bellard's <a href="http://bellard.org/jslinux/" rel="nofollow">PC emulator implemented in Javascript</a> is impressively fast--it boots a small Linux image <em>in the browser</em> within a few seconds.</p> <p>What techniques were used to get this performance?</p>
javascript
[3]
2,950,902
2,950,903
Using static methods in objects PHP - is it advantage?
<p>I was reading some articles and discussions on the use of <code>static methods</code> on objects and it struck me how much the views differ.</p> <p>Someone say that using static methods is an <strong>advantage</strong>. Someone says that use is a big <strong>mistake</strong>.</p> <p>I wonder how is it? My question...
php
[2]
4,498,174
4,498,175
How to find character appearence in text
<p>How can i find with jquery how many times a character appear in text, for example i have the character <strong>1</strong> and the text <strong>143443143241</strong> so here the character 1 appear 3 times, how can i check that.</p>
javascript
[3]
2,169,142
2,169,143
JavaScript IF with AND/OR.. not working
<p>Can someone who is a master at JS tell me what's wrong with this?</p> <pre><code>if ( $.trim($("#add-box-text").val()).length &lt; 2 &amp;&amp; $.trim($("#add-box-text").val()) != "Click here to add an item" ) { // If it's LT than 1 Character, don't submit $("#add-box-text").effect('highlight', {color: '#BD...
javascript
[3]
5,899,113
5,899,114
Android ScrollView, scroll before visible
<p>how can I set scroll of scrollview to x pixels, before it's even shown? </p> <p>In ScrollView I have some Views and i know that it will fill screen. Can I scroll to let say second View, so that first View is not visible when activity is started?</p> <p>Now I have sth like this, but I think it's not perfect, someti...
android
[4]
2,051,871
2,051,872
How do I delete all the nodes in my custom linked list?
<p>Is is possible for me to delete all nodes of my linkedlist to delete by my this code piece? If no then how is it possible to delete all the node at once! </p> <p>my code is</p> <pre><code>EditNode mynode=start; while(mynode!=null){ mynode.editnext=null; mynode=mynode.editnext; } </code></pre> <p>Help need...
java
[1]
4,412,095
4,412,096
How to send array by post method
<p>Following is my sample form.</p> <pre><code>&lt;form METHOD="post" METHOD="post" ACTION="index.php" METHOD="post" METHOD="post" METHOD="post"&gt; &lt;input TYPE="text" NAME="array[]" /&gt; &lt;input TYPE="text" NAME="array[]" /&gt; &lt;input TYPE="text" NAME="array[]" /&gt; &lt;input TYPE="text" NAME="array[]" /&gt...
php
[2]
4,131,838
4,131,839
Page_init and Page_prerender methods - performance issues
<p>We were running a simple aspx page on IIS7.5 and we observed that it is taking long time to exit Page_Init method and call Page_PreRender method. There is nothing getting executed between these methods. See trace for the page calls.</p> <pre> [INFO ] 2011-07-15 18:30:24,783 [6] Customer.Ektron.Web END - Page_Init...
asp.net
[9]
1,188,742
1,188,743
support for multiple resolution android
<p>My app has 2 different resolution support, 480x800 and 320x240, i have created folder for them for instance layout-normal-hdpi and layout-normal-mdpi. But somehow emulotor is not picking up the ui for hdpi. I have created different layout aswell.</p>
android
[4]
5,762,125
5,762,126
Indicate the user that data is being loading
<p>I want to show a progress bar or anything else when particular peice of code will execute. How can i do this? </p>
android
[4]
4,118,229
4,118,230
IE error when trying for( var i in window.external )
<p>I am building an object/property dump using JavaScript. This code breaks under Internet Explorer 8 (assuming subject = window.external)</p> <pre><code>// Gather the property names into the keys array. var keys = Array(); for( var i in subject ){ keys.push(i); } /* After this I sort the keys, then loop through to g...
javascript
[3]
2,089,302
2,089,303
C# return string array from static string
<p>Here's the code i'm using, I want to be able to feed it a single string, the character i want to convert with, and then return the array, Here's what I have but i'm not sure how to get the array to return.</p> <pre><code> public static string SplitSingleCharecter(string splitCharecter,string inString, out strin...
c#
[0]
572,306
572,307
PHP - Links: From Thumbs to page.php
<p>I need to link 9 thumbs called: <code>project1.jpg, project2.jpg, project3.jpg</code>... to php pages with the same name: <code>project1.php, project2.php, project3.php</code>.</p> <p>It's my code so far:</p> <pre><code>&lt;?php $dir = 'portfolio/print/img/thumbs/'; $main_page ='portfolio/print/project1'; // How ...
php
[2]