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
5,248,736
5,248,737
formatting currency
<p>I have this value : 12345678,99</p> <p>I'd like have this : €12.345.678 to resume "." as thousand separator, not show decimal number and add the € befor the number.</p> <p>Do you know the formatting string ?</p> <p>Thanks, </p>
c#
[0]
4,735,378
4,735,379
Is there any alternative to Java properties for keeping tree-like data?
<p>I have 3 item data that I should keep on remote PC. Let it be: ID, login, password. If there're only 2 items, Java property will suit me great, but I have some sort of tree. It is impossible to install any DB on that machine, so the variant with DB usage is declined at once.</p> <p>Do we have any alternative to Jav...
java
[1]
4,723,813
4,723,814
Scheduling a method to execute recursively and terminate that method
<p>I have a method which will be called repeatedly after successive intervals. I have used <code>public void schedule(TimerTask task, Date firstTime, long period)</code>. How to stop this schedule method being called after certain time.</p> <p>Right now i have no idea how to stop this method.</p> <p>Any help would be...
java
[1]
2,866,987
2,866,988
jquery rotation which can rotate table html elements
<p>I have table with some data. Table has 40 nested tds like</p> <pre><code>&lt;table&gt; &lt;tr&gt; &lt;td&gt; xxx &lt;/td&gt; &lt;td&gt; xxx &lt;/td&gt; &lt;td&gt; xxx &lt;/td&gt; ... &lt;/tr&gt; &lt;/table&gt; </code></pre> <p>now i am looking for some jquery rotation plugin which will rotate this tds. Does anyone...
jquery
[5]
4,817,480
4,817,481
HTML of selected text
<p>Is there a cross-browser way to get HTML of selected text?</p>
javascript
[3]
2,315,860
2,315,861
Download a PDF and rename it?
<p>I'm working on a little script to save some time. My script takes a given URL to a PDF and I want to download the PDF to the local computer, say to /Downloads but I want to rename the file with a name taken from a form. </p> <p>Is this possible with PHP?</p>
php
[2]
2,059,292
2,059,293
How to pass an value of type enum to another enum variable?
<p>I'm getting the value of in an enum variable but while assigning it to another variable of type enum its getting 0 all the time...Here's the code i'm using , dbProperties is the object of class DBProperties which has a member of type DBType. dbProperties.DBType is always returning 0 even after assigning a value to i...
c#
[0]
2,742,014
2,742,015
Asp.net FTP Upload and Unzip - Overwrite Files
<p>I got a custom CMS, would like to automate the upgrade.</p> <p>Steps like:</p> <p>1- Download the latest version zip. 2- Extract it to the local path (overwrite). 3- Exec the update stored proc.</p> <p>I downloaded the latest zip but now ASP.net user doesn't have enough rights to overwrite, thats logical but what...
asp.net
[9]
212,264
212,265
Converting/wrapping h264 video stream into MPEG2 TS
<p>I am reading in an mp4 file which I can demux. The file contains h264 video stream. I want to be able to wrap the h264 video stream in mpeg2 ts such that I can pass it onto other parts of the system as mpeg2 ts or even writing it into a new file as mpeg2 ts. Any pointers would be appreciated.</p> <p>Thanks,</p>
c++
[6]
2,224,234
2,224,235
Value Stored to during its initialization is never read when assigning a frame
<pre><code>CGRect bannerFrame = testView.frame; bannerFrame = CGRectMake(0, 236, 480, 32); testView.frame = bannerFrame; </code></pre> <p>I get <strong>Value stored to 'bannerFrame' during its initialization is never read</strong> this warning in analyze. How can i resolve it ??</p> <p>Thanks in adv.</p>
iphone
[8]
2,180,810
2,180,811
Getting the entire size of a website using php's FTP functions
<p>I'm trying to get the size of my website using php and ftp. I would like to get the size of everything under httpdocs, (files and directories combined)</p> <p>And have it output: My website is 42.5MB.</p> <p>I've tried ftp_rawlist, but that gives me an ugly array that I have no idea how to parse. (Im new to php ar...
php
[2]
2,509,141
2,509,142
explanation about activity re-creation on configuration change and context
<p>I'm pretty new to Android development and I'm looking for explanation about a problem I'm facing, for gaining deeper understanding of Android.</p> <p>I have this piece of code:</p> <pre><code>someAutoCompleteTextView.setOnFocusChangeListener(new OnFocusChangeListener() { @Override public void onFocusChange...
android
[4]
5,062,146
5,062,147
Android animation
<p>When i try to make a man run in android by displaying his images with his his legs in different position the animation does not look very good.It appears as two different images switching between one another.It does not look uniform.Is there any other way to implement animation in android.</p>
android
[4]
4,211,592
4,211,593
How to remove namespace from Inherits Attribute without a Parser Error, Could not load type
<p>I've seen lots of posts about the Inherits Attribute, and the Parser Error "Could not load type"</p> <p>I can get this working by putting "RootNamespace.PageName" for a specific page, where RootNamespace matches the Root namespace in my project properites.</p> <p>But I would rather not put the namespace in there. ...
asp.net
[9]
3,846,590
3,846,591
show one random list out of many on page load
<p>help guys</p> <pre><code>&lt;ul&gt; &lt;li&gt;&lt;p&gt;“I should say upfront that I have never been in a cellar in my life. In fact, I can see no reason why anyone should ever go into a cellar unless there is wine involved.”&lt;/p&gt; &lt;span class="author"&gt;~Rachel Hawkins, Hex Hall&lt;/span&gt;&lt;/li&gt; &lt;...
php
[2]
1,254,324
1,254,325
Adding dynamic content from a database
<p>I'm using a new no-name framework that I'm not completely familiar with and I'm hung up on how I will add dynamic content from the database in this environment.</p> <p>In the index controller, I'm forced to have an index function that answers all requests for index.html. If I wanted to create a second page dynamica...
php
[2]
4,899,271
4,899,272
How to get MD5 from debug.keystore file?
<p>I use some command to get MD5 private key from <code>debug.keystore</code> file but actually I get SHA1 private key instead of MD5. I do not know how to get MD5.</p> <p>This is command that I use.</p> <pre><code>keytool -list -alias androiddebugkey -keystore (path_to_debug_keystore).keystore -storepass android -ke...
android
[4]
433,179
433,180
Need help to debug jQuery char counter logic
<p>I have a textarea with a counter below that counts input characters. There is a maximum input limit set as well. I also added couple of spans that insert values into that textarea too when they are clicked. </p> <pre><code>&lt;span id="tag1" class="tags"&gt;&lt;/span&gt; &lt;span id="tag2" class="tags"&gt;&lt;/span...
jquery
[5]
2,538,792
2,538,793
Code Signing Error with iPhone Configuration utility for in-house distribution
<p>We have an Enterprise license to distribute our app in house. From that account on developer.apple.com, we generated a provisioning profile. On some people's machines, the provisioning profile works and they are able to install the app. On others, they get, </p> <blockquote> <p>"Could not install application o...
iphone
[8]
343,316
343,317
Asp.net request.querystring
<p>I am using request.querystring just to access a parameter which I am passing from one page to other.</p> <p>It is giving me error. Non-invocable member 'System.Web.HttpRequest.QueryString' cannot be used like a method. </p> <p>I am using C#.</p> <p>Any help would be appreciated!</p>
asp.net
[9]
2,585,719
2,585,720
Get a href attr and set it to another
<pre><code>&lt;script type="text/javascript"&gt; $(function() { $('.thelink a').select(function() { var a_href = $(this).attr("href"); }); $('.calltoActionMoreInformation a').attr('href', a_href); }); &lt;/script&gt; &lt;div class="thelink" style="height: 250px; position: relative;"&gt; &lt;...
jquery
[5]
1,813,625
1,813,626
dir() function in commandline vs IDLE
<p>I've tried running the following code in IDLE:</p> <pre><code>import sys dir(sys) </code></pre> <p>There is no result:</p> <pre><code>&gt;&gt;&gt; </code></pre> <p>But when I run it in the command line, i get this:</p> <pre><code>&gt;&gt;&gt; dir(sys) ['__displayhook__', '__doc__', '__excepthook__', '__name__',...
python
[7]
966,523
966,524
Obtain the result in easier way
<p>I need to get an array containing reversed alternate elements of the original array.</p> <p>For example: an array containing elements {12,56,67}.</p> <p>I need to get an array containing {67,12} (reversing array to get {67,56,12} then take alternate elements means {67,12})</p> <p>I need to do this in c#</p>
c#
[0]
4,158,994
4,158,995
Pass an object as parameters to a function in C++
<p>In Javascript or ActionScript it's possible to pass an object to a function or a constructor.</p> <pre><code>myfunction({myParam:1, myOtherParam:"hello"}); </code></pre> <p>It is very useful when you have a lot of parameters to pass, IMO it makes using functions easier than using the classic approach.</p> <pre><c...
c++
[6]
3,403,602
3,403,603
Multi tab jquery issue with cvs3DLib-07, jquery say has no replace method at Line 6710
<p>Referring to the post as mentioned in <a href="http://stackoverflow.com/questions/3847152/jquery-simple-tab-program-does-not-show-nested-div-tag/14859890#comment20830148_14859890">JQuery simple tab program does not show nested Div Tag</a> </p> <p>I am using 3D Library, that is cvs3DLib-07.js, moment i include it al...
jquery
[5]
1,962,995
1,962,996
What to use thread or Services for android multiplayer game app
<p>Need some help. So I am creating a multiplayer game app in android. Basically I have simultaneous thread running at the same time like UI thread, gameEngine thread, connect to server thread. Right now my app is using around 80% of the CPU resource. I think the cause of this has to do with the multiple threads. Is t...
android
[4]
2,987,592
2,987,593
how to start learning JavaScript
<p>I am experienced in the technical support like Linux, oracle, sunos etc and but if i say scripting i know little bit of bash. Now i promoted to manage technical engineers including some JavaScript developers, so i want to learn JavaScripting so that i can understand engineers. Hope you understand. Can you please adv...
javascript
[3]
4,943,251
4,943,252
Problem with System.nanoTime()
<p>I´m working on a 2d java game but I´m stuck on timer problems. Here is my game loop:</p> <pre><code>void gameLoop(isRunning){ .... doStuff(); .... } </code></pre> <p>I have a fps measuring code like this inside the loop:</p> <pre><code>long thisLoop = System.currentTimeMillis(); delta = thisLoop - lastLoopTime;...
java
[1]
3,958,650
3,958,651
StringValueof && To String' What is difference?
<p>What is difference betwin this two:?</p> <pre><code>int a=20; System.out.print(a.toString); System.out.print(String.valueOf(a)); </code></pre> <p>Thanks!</p>
java
[1]
1,487,353
1,487,354
Properties or fields in Equals and GetHashCode?
<p>I'm using a mix of <a href="http://stackoverflow.com/a/263416/47493">Jon Skeet's GetHashCode</a> and the <a href="http://msdn.microsoft.com/en-us/library/ms173147%28v=vs.80%29.aspx" rel="nofollow">MSDN Guidelines for Overloading Equals</a> to implement my Equals and GetHashCode methods. However, one thing has been b...
c#
[0]
749,229
749,230
Preferring non-member non-friend functions to member functions
<p>This question title is taken from the title of item #23 in Effective C++ 3rd Edition by Scott Meyers. He uses the following code:</p> <pre><code>class WebBrowser { public: void clearCache(); void clearHistory(); void removeCookies(); //This is the function in question. void clearEverything(); ...
c++
[6]
1,285,434
1,285,435
Getting Forms on Page in Python
<p>I'm working on a project (web vulnerability scanner).</p> <p>I have compleate 30% of the program it can scan only GET Methods. but having a problem now. I have no idea how I shall make the program pentest the POST Method (the forms) .</p> <p>I'm having a idea to make it Extract the form data/names from all the pag...
python
[7]
5,889,738
5,889,739
How can I get whether textBox is changed in Android Activity?
<p>I have a activity contains many edittexts. How can I know whether the user have input or change the content of the edittext?</p> <p>Not check one edittext, there are many edittexts in the activity. If one of them has been changed. While the user leave the activity, I need tell he/her, the information is not saved.<...
android
[4]
5,623,685
5,623,686
php - simple cache feature - retrieve data every hour
<p>I want to set up a simple cache feature with php. I want the script to get data from somewhere, but not to do it on every page view, but only every hour. </p> <p>I know i can have a cron job that runs a php script every hour.</p> <p>But I was wondering if this can be achieved without cron, just inside the php scri...
php
[2]
1,706,298
1,706,299
How to edit a row in a text file with C++?
<p>I have a txt file like this:</p> <pre><code>"shoes":12 "pants":33 "jacket":26 "glasses":16 "t-shirt":182 </code></pre> <p>I need to replace the number of jacket ( from 26 to 42 for example ). So, I have wrote this code, but I don't know how to edit a specific row where there is the word "jacket":</p> <pre><code>#...
c++
[6]
5,512,427
5,512,428
How to calculate area inside multiple geo coordinates in android
<p>In my application i am capturing all selected location gps coordinates,and also i am drawing line between each selected coordinates.</p> <p>I already know how to calculate distance between two points </p> <p>but in my application user may select any number of locations so i wants to calculate the area between all ...
android
[4]
3,336,927
3,336,928
asp:TextBox Disabled style is not consistent in different Browsers
<p>ASP.NET</p> <p>When <code>TextBox1.Enabled = false;</code> it has a gray background in FF3, but no change in IE8 or Chrome. So it's harder to tell if it's disabled or not. Is there any more general way to make the disable textbox rendered more consistent on a top-level? So I don't need to change this for every page...
asp.net
[9]
329,825
329,826
How to display picture in imageview photo taken by camera in android
<p>can anybody tell How to display picture in imageview photo taken by using front camera in android can anybody provide code</p> <p>Thanks</p>
android
[4]
3,092,001
3,092,002
jQuery sibling selector
<p>I have the following:</p> <pre><code>&lt;input name="Check100" type="checkbox"&gt; &lt;tr&gt; &lt;td&gt;&lt;input name="ClassIDs" type="checkbox" value="3132"&gt; &lt;td&gt;50&lt;/td&gt; &lt;/tr&gt; &lt;tr&gt; &lt;td&gt;&lt;input name="ClassIDs" type="checkbox" value="3133"&gt; &lt;td&gt;100&lt;/td&gt; ...
jquery
[5]
2,752,965
2,752,966
C# Rich Text Box, Brace Matching
<p>Is there a good open source project with brace matching support? I was searching codeproject all day but failed to find any. Or atleast can someone advice me on how to tackle it? Thanks!</p> <p>It can be in C# or VB.NET.</p> <p><strong>Edit:</strong> Sorry forgot to mention, I do not want to use other dll compone...
c#
[0]
5,347,000
5,347,001
Up-to-date jQuery books
<p>jQuery just released version 1.6.4. Despite that, the list of "books about jQuery" at the bottom of jquery.com all deal with jQuery 1.4 or below. Where can I find jQuery literature dealing with the more cutting edge features of jQuery available in 2011?</p>
jquery
[5]
5,186,779
5,186,780
Android: code to handle return button of the softkey or return button which is on mobile
<p>in my application I collect some data by the client. On the main layout.xml client put some data and in last they need to click on save button after that all the data will store in database or in other place. What I want when the client is in middle of the application and when he press on return button or back butto...
android
[4]
64,395
64,396
Should I learn on the iPhone App Dev 3.0 or not
<p>I think the 3.0 update is coming out in July 09, that is about 30 days away.</p> <p>Coming from a C# background, I am learning objective C and my way around a mac.</p> <p><strong>Should I start learning with the 2.2 or 3.0?</strong></p>
iphone
[8]
4,943,286
4,943,287
only can write until the 924th byte using RandomAccessFile
<p>Im having a problem when i try to fill up a randomaccessfile, in using a loop for it and it stops writing when it reaches de 924th byte, so when i try to fill up 2500 bytes with "-" for example, it only fills 924 byte. Here is the code that im using, hope someone can tell me what i am doing wrong</p> <pre><code>pub...
java
[1]
3,466,079
3,466,080
local php files will not work
<p>I have to do a php project. I done php before so I understand the syntax for the most part. Just for a test, I made a file.php and in it I wrote:</p> <pre><code> &lt;html&gt; &lt;body&gt; &lt;?php echo "helloWorld"; ?&gt; &lt;/body&gt; &lt;/html&gt; </code></pre> <p>Well it won't display. The scr...
php
[2]
2,262,551
2,262,552
rss@gmail.com&amp;b=52 I want to remove &amp;b=52 from this mail id which String function is used for this
<p>Please give me the code for removing the <code>&amp;amp;b=52</code> from strings such as these:</p> <ul> <li>rsc@gmail.com&amp;b=52</li> <li>ab@gmail.com&amp;b=52</li> <li>aaaa@gmail.com&amp;b=52</li> </ul>
java
[1]
1,028,014
1,028,015
ASP.NET - Browser always returns "Page not found" message the first time I request the start page
<p>Whenever I start a new browser session and request the start page of my ASP.NET site, I am redirected to a different URL that is similar to the one I requested. For example, if I request the page</p> <pre><code>http://myserveralias.xyz.com/virtualfolder/startpage.aspx </code></pre> <p>I am redirected to</p> <pre>...
asp.net
[9]
2,264,538
2,264,539
Multiple project solution, 'missing assembly reference' despite including it
<p>I have two projects in the current solution:</p> <pre><code>abc.Dashboard abc.ThingyService </code></pre> <p>abc.ThingyService needs to be able to use a class from abc.Dashboard.</p> <p>I've added a reference to abc.ThingyService pointing at abc.Dashboard (right click on project -> add reference -> projects -> ab...
c#
[0]
4,091,723
4,091,724
Stack size dimension ocupied by recursive function
<p>For a C++ program that is using a recursive function, how can I evaluate the dynamic stack size occupied by this function? </p>
c++
[6]
4,155,810
4,155,811
JQuery ControlID in User control
<p>I have an ASP.NET Usercontrol and am using JQuery to do some stuff for me. I use the User control dynamically in different pages. I need to get the ControlID of the control that is in the user control. How do i dynamically do a $('#myControl') instead if $('#HostPage.myControl'), <strong>what is the syntax for $('&l...
jquery
[5]
2,432,277
2,432,278
exporting sql query result to excel
<p>In my asp.net application i wanted to export the SQL query result to Excel and that excel should be avaliable to the user as a download. Please help</p>
asp.net
[9]
607,773
607,774
What am I calling?
<p>Is there a way to check inside a fnc what is this fnc name? I'm working currently on LargeInt class and I've realized that code for oparator> and operator&lt; is almost identical so I would like to know what operator is calling me and react accordingly.<br> Thank you.</p>
c++
[6]
4,092,932
4,092,933
The point of pointers
<p><strong>I Know</strong> am very wrong about this, but i would like some help. What is the point of pointers in c++ when i can just declare variables. What, When, Where is a good situation to use them?</p>
c++
[6]
1,062,728
1,062,729
ASP.NET using DLL's instead of App_Code
<p>What are the advantages, if there are any, of using a separate DLL in the BIN folder instead of adding your classes to the App_Code folder. Is there a method preferred?</p>
asp.net
[9]
3,525,883
3,525,884
How can I resize the image that was retrieved via URL and save it?
<p>I am getting an image via URL from the Internet and trying to resize (to a smaller size) before saving it. I managed to save it, but I'm unable to resize it. How could I do that? Here is the code:</p> <pre><code>URL url = new URL(LogoURL); InputStream input = url.openStream(); try { OutputStream output = new F...
android
[4]
2,141,533
2,141,534
Javascript eval limits
<p>Is there a limit to javascript's eval, like in lenght?</p> <p>I'm trying to build an app where you can store JS code in the DB, which you can later load and eval in order to execute it, but i'm reaching a limit. First of all, the code has to all be in one line. Any multiline statements are not executed. Next, i'm r...
javascript
[3]
2,350,847
2,350,848
Android programatically inserted SMS have incorrect timestamp in Messaging apps
<p>I have tried to use the undocumented content provider (content://sms) to insert a SMS into the inbox, and the insertion is successful. Then I check the newly inserted mesage in the Messaging apps, however the time displayed is always the real time that the insertion is done, instead of the time I specified in Conten...
android
[4]
4,501,803
4,501,804
Accessing of UILabel object crash
<p>I created a UIView and a UILabel outlet for the XIB. In the first load is fine then I execute the removeFromSuperview to remove that UIView and call again the addsub to show that UIView again. But when I tried to access again the UILabel like the setText method then the app will crash. Do you think its about removeF...
iphone
[8]
2,326,182
2,326,183
PHP grabing the dominant color from an image?
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/8730661/how-to-find-the-dominant-color-in-image">How to find the Dominant color in image?</a> </p> </blockquote> <p>How I could grab the dominant color from a PNG image with php?</p> <p>I've seen this achieved ...
php
[2]
5,540,851
5,540,852
iPhone Image Loading in Photos Application
<p>I am not sure if this is the right forum for asking this question, but I googled "questions related to iPhone" and the first page had SO from top to bottom. So here goes.</p> <p>When I open the Photos Application in iPhone (3GS, 4 and 5 all running iOS 5.0) and open an image, first a blurred image appears for a fra...
iphone
[8]
3,072,837
3,072,838
Moving stuff out of appdelegate
<p>I have a tricky situation in my app . i am making the server call in application did finish launching method based on the server response i need to load different views .my app is working fine in simulator but in device the app getting crashed because of the time taking to get the server response .i tried NSThread t...
iphone
[8]
5,311,452
5,311,453
Win 8 App Development: How does this tutorial code work?
<p>Just started learning Win 8 app development and I'm following the basic tutorial for data binding. </p> <p>The code I'm trying to understand is:</p> <pre><code>&lt;div id="basicBinding"&gt; Welcome, &lt;span id="nameSpan" data-win-bind="innerText: name"&gt;&lt;/span&gt; &lt;/div&gt; &lt;script...
javascript
[3]
4,149,259
4,149,260
Detecting which object invoked the method in C#
<p>Is there a way in C# to detect which object invoked a method?<br> for example:</p> <pre><code>class Foo1 { Foo2 m_inner = null Foo1() { m_inner = new Foo2(); m_inner.Do(); } } class Foo2 { Foo2() { } void Do() { //Here I want to know that Foo1 called it. } } </code></pre...
c#
[0]
5,580,830
5,580,831
What is wrong with my firefox browser test?
<p>I want to test if the user is using Firefox under version 3.0, if yes trigger the function and here's what I ended up with! Now I use the version 14.0 of Firefox to test it out and it still trigger the function! Anyone can help a beginner? Thanks!</p> <p>script:</p> <pre><code>if (/Firefox[\/\s](\d+\.\d+)/.test(na...
javascript
[3]
1,476,661
1,476,662
Java : Object Initialization
<p>How to interpret the statements below:</p> <pre><code>Notes bean = null; bean = new Notes(); </code></pre> <p>Small explanation would be very helpful. </p>
java
[1]
1,813,298
1,813,299
Error in counting number of words and characters from a file in java
<p>I have written the following code to print file content and print the number of character and words from file</p> <pre><code>import java.io.*; import java.util.*; class Ass53 { public static void main(String args[]) throws Exception { File file=new File("sample.txt"); Scanner sc=new Scanner(new FileInp...
java
[1]
1,030,938
1,030,939
How to open two popup window on a button click?
<p>I need to open two pdf files as popup window on click ona button in asp.net C#,but now its opening only the first popup?Can anybody help me ,to open the both windows at the same time?</p> <p>This is my code:</p> <pre><code>string PDFPath = folderpath + filename; string PopupName = "popUp"; ...
c#
[0]
961,803
961,804
how to put clickable image jframe
<p>i want to add icons in jframe which does some action while click like buttons. </p>
java
[1]
1,549,746
1,549,747
C# Noob Looking for Little Help : Why this mini code doesnt works?
<p>I am very very new at C# and i am just trying a little code here. </p> <p>But it didn't work. I don't understand why. And i dont get any erros on Visual Studio. It just doesn't work right. I alwasy says " You wrote a higher number. " and close.</p> <p>Can you help me?</p> <p>You can understand what i am trying to...
c#
[0]
1,710,104
1,710,105
Does SSTab1.TabPages.Item(?) start from 0 or 1?
<p>Hallo all,</p> <p>short question:</p> <p>Does the index x in SSTab1.TabPages.Item(x) start from 0 or from 1? How could I find out which tab corresponds to which item(x)?</p> <p>Thanks in advance,</p> <p>John</p>
c#
[0]
5,335,328
5,335,329
how to change value of global variable inside of function
<p>I am using javascript i create a global variable. by define it outside of function i want to change the global variable value from inside a function and use it from other function how to do this? </p>
javascript
[3]
2,933,468
2,933,469
Internationalization in Manifest file
<p>I have some label in the manifest file which has english text how can i have them in other languages also.for e.g. </p> <pre><code>&lt;activity android:name=".activity.MainMenuActivity" android:label="Main Menu Options" android:configChanges="locale" &gt; &lt;/activity&gt; </co...
android
[4]
1,610,073
1,610,074
How to check if array a is part of array b in java?
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/808394/check-whether-an-array-is-a-subset-of-another">Check whether an array is a subset of another</a> </p> </blockquote> <p>I have array <code>a = { 1,4,3,5,1,2,3,6 }</code> and array <code>b= { 1,2,3 }</code>...
java
[1]
2,624,605
2,624,606
android how do you dynamically change a radiogroup based on the radiogroups selection
<p>I get an error on the "button2.setOnClickListener(<strong>radio_listener</strong>);" </p> <p>Because its embedded inside the onclick listener calling itself, whats the way around this?</p> <pre><code> final RadioGroup rGroup3 = (RadioGroup) findViewById(R.id.radio_gcam); OnClickListener radio_listener = ne...
android
[4]
800,509
800,510
Open a PopUpWindow from an AppWidget
<p>As it doesn't appear to be possible to put an EditText in an AppWidget, I would like to open a PopUpWindow with an EditText when I click on it.</p> <p>I know how to open an Activity from an AppWidget and I also know how open a PopUpWindow from an Activity. I don't, however, know how to open a PopUpWindow from an Ap...
android
[4]
5,057,187
5,057,188
Android search dialog in activity.. two problems
<p>I have a simple ListActivity right now, created using the code at <a href="http://developer.android.com/guide/topics/search/search-dialog.html#PerformingSearch" rel="nofollow">http://developer.android.com/guide/topics/search/search-dialog.html#PerformingSearch</a>.</p> <p>I simply call onSearchRequested() in onCrea...
android
[4]
2,143,649
2,143,650
Android: How do I create loading screen while access the database
<p>I have been developing one Map project. In all Activity classes i have one method called <strong>getDataFromServer()</strong> which parse some JSON Response from the server for the particular activity. And displays that data on the Map. While receiving and parse data , I want to display loading screen. How to make g...
android
[4]
4,385,030
4,385,031
what is wrong here
<pre><code> unsigned __int8 result[]= new unsigned __int8[sizeof(username) * 4]; </code></pre> <p>IntelliSense: initialization with '{...}' expected for aggregate object</p>
c++
[6]
5,961,334
5,961,335
Simple, server-side ASP.NET richtext control?
<p>I'm aware of TinyMce, FCKeditor, and Telerik RadEditor, but they are all too heavy weight for my needs. I just want a text box where the user can mark text as bold, italic, make a list, and most importantly spellcheck it. It should also be able to count the number of characters entered. Where I'm at now is a custom ...
asp.net
[9]
2,192,689
2,192,690
jQuery - combine statements
<p>Could i trouble someone to help me combine these statements...everytime i do i get a script error, but am unable to debug what is exactly wrong...</p> <pre><code>&lt;script type="text/javascript"&gt; $(function() { $('.slideshow').after('&lt;div id="mininav" class="mininav"&gt;').cycle({ fx: ...
jquery
[5]
1,906,617
1,906,618
Is it possible to show push notification as popup message in android?
<p>I want push notification as popup message .I dont want to show it top of the status bar . when ever push notification arrives .Please help me!!</p>
android
[4]
5,382,610
5,382,611
Add title="" to A PHP Code
<p>I am using a code to call WP thumbnails and want to add a title="" tag. I would like the title to call the_title... how do I do so? I want to assign the title tribute to the image, not the link.</p> <p>My code:</p> <pre><code>&lt;?php if ( has_post_thumbnail() ) { the_post_thumbnail( 'thmb-archive' ); } ?&gt; </...
php
[2]
5,832,324
5,832,325
unable to use gets(); and puts(); in c++ program
<p>unable to use <code>gets()</code>; and <code>puts()</code>; </p> <p>In c++ program </p> <blockquote> <p>error : function should have a prototype</p> </blockquote> <p>code :</p> <pre><code>. . gets(name); or puts(name); . . </code></pre> <p>i have included header file <code>string.h</code></p>
c++
[6]
2,361,988
2,361,989
iPhone SDK: How to add an image to a UIBarButton?
<p>I have used the code below to create a button on the nav bar with an image.</p> <p>I can see the image but I can also see the border of the button around it. My question is, how can I get rid of the button border. All I want to see is the image on the nav bar, no border.</p> <pre><code>UIBarButtonItem *settingsBtn...
iphone
[8]
4,520,813
4,520,814
Updating a page before initiating a download?
<p>I've got a page that allows users to enter search criteria and then display matching records. It also has a download button to enable the user to download matching records. </p> <p>How can I code it so that clicking on "Download" will first refresh the record display before downloading the data?</p> <p>This is t...
asp.net
[9]
4,607,958
4,607,959
Hide Activity without finish()
<p>I want my application to launch another activity/application (in this case, the Browser application), but currently when the user presses the Back button to exit the Browser, they return back to my Activity.</p> <p>How can I make it so they do not come back to my activity after leaving the Browser, <strong>but</str...
android
[4]
4,300,802
4,300,803
jQuery is not submitting form values with .submit()
<p>i have a form with action = post and i am validating it with after validating it i am submitting that form with $("#form").submit(); but it is submitting all fields nullled while i have data in those fields.... how can i post those fields filled..</p>
jquery
[5]
635,744
635,745
Strange results when searching if value exists in list
<p>Here's the area of code I'm having problems with. T1 and T3 are both lists of lists:</p> <pre><code>for num in T1: print num print T3[0] print type(num) print type(T3[0]) if num == T3[0]: print 'they are the same!' else: print 'nope they are not!' if T3.index(num): ...
python
[7]
459,673
459,674
Validation to check if password and confirm password are same is not working
<p>Here's my code:</p> <pre><code>function validate_form(thisform) { with (thisform) { if (validate_required(name,"Name must be filled out!")==false) {name.focus();return false;} if (validate_required(country," Country must be filled out!")==false) {country.focus();return false;} if (validate_required(...
javascript
[3]
3,370,043
3,370,044
Pythonic way to access arbitrary element from dictionary
<p>I have a dictionary, full of items. I want to peek at a single, arbitrary item:</p> <pre><code>print "Amongst our dictionary's items are such diverse elements as: %s" % arb(dictionary) </code></pre> <p>I don't care which item. It doesn't need to be <em>random</em>.</p> <p>I can think of many ways of implementing ...
python
[7]
2,271,155
2,271,156
refresh a view in iphone programming
<p>i want to refresh my current view when i click a button how to do this </p>
iphone
[8]
4,081,011
4,081,012
Jquery data retrieving not work
<p>I need to store the data to each 'li' element of my 'ul', in case if i assigning the value like this:</p> <pre><code>$('li:eq(0)').data('some', {name:'some',age:'some'}) $('li:eq(1)').data('some', {name:'some',age:'some'}) </code></pre> <p>then is it correct. or any other short way to set the data to element?</p...
jquery
[5]
5,115,301
5,115,302
How to guarantee Java instance control (without enum) in world of serialization?
<p>In a world before Java 1.5 (so no <code>enum</code>) and with my object being serialized, how can I enforce proper instance control? I'm talking about a class like this, where, as far as I can tell, I'm not sure that instance0 and instance1 will always be the only instances.</p> <pre><code>import java.io.Serializa...
java
[1]
3,115,166
3,115,167
TypeError: Result of expression 'input.replace' [undefined] is not a function
<p>I wrote the following function in javascript:</p> <pre><code>function maskString(input) { return input.replace(/\s\s+/," "); } </code></pre> <p>Very simple. In a second function I wrote:</p> <pre><code>function secondFunction(string1, string2) { //Attetion! See Update 2! var string1masked = maskString(string1...
javascript
[3]
2,450,822
2,450,823
c++ unable to get proper string input
<p>I am new to programming just wrote this simple function to calculate length of a string but I am unable to take input string from the user properly(have tried my alternatives).</p> <pre><code>/////////Function to calculate length of a string//////////////////// void str_length(){ char str[30]; int counter=0...
c++
[6]
1,097,292
1,097,293
java listing the txt files in sub folders
<p>Hi I have a jlist and currently it is viewing a folder + subfolders... Now i would like to change this to view the files in the subfolders as well. below please find the code I am currently using:</p> <pre><code> jList1.setModel(new javax.swing.AbstractListModel() { File folder = new File ("/As...
java
[1]
3,742,359
3,742,360
Selector with image and textview at the same time
<p>I know how to make a selector for imageview and how to do it for textView ,now i have a tabwidget that contains tabs each tab have image and text view below it , my question is how to change the background of the image view and the color o it text view when the user click on the tab .</p>
android
[4]
2,388,439
2,388,440
document.activeElement.id is not working
<p>I am developing an application for device. and i want to know the current focused anchor.</p> <p>for this i used <strong>document.activeElement.id</strong>. It is working fine on webkit but not working on older browser. So i used </p> <pre><code> $(":a").focus(function () { id = this.id; ...
javascript
[3]
1,098,969
1,098,970
Implement animation in UIButton
<p>I'm new to cocoa and iphone programming and I want to implement an animation in UIButton. For example, I create a custom UIButton with a square image. Then when I press that UIButton, the square image will flip. Note that the square image is the image of the UIButton.</p> <pre><code>[UIButton setImage:[UIImage imag...
iphone
[8]
4,208,368
4,208,369
jquery: add html after a group of divs
<p>I have something like this: ...</p> <pre><code>&lt;div id="d120" &gt;content&lt;/div&gt; &lt;div id="d123" &gt;content&lt;/div&gt; &lt;div id="d112" &gt;content&lt;/div&gt; &lt;div id="d145" &gt;content&lt;/div&gt; &lt;div id="d134" &gt;content&lt;/div&gt; //Insert here hello world &lt;div id="bla" &gt;asd&lt;/div...
jquery
[5]