How to set text color of a TextView programmatically?
How can I set the text color of a TextView to `#bdbdbd` programatically?
- Modified
- 1 Mar at 13:59
Get Month name from month number
> [How to get the MonthName in c#?](https://stackoverflow.com/questions/975531/how-to-get-the-monthname-in-c) I used the following c# syntax to get month name from month no but i get `August` ...
Infinite Recursion with Jackson JSON and Hibernate JPA issue
When trying to convert a JPA object that has a bi-directional association into JSON, I keep getting ``` org.codehaus.jackson.map.JsonMappingException: Infinite recursion (StackOverflowError) ``` All ...
- Modified
- 9 May at 18:36
How to upload file to server with HTTP POST multipart/form-data?
I am developing Windows Phone 8 app. I want to upload SQLite database via PHP web service using HTTP POST request with MIME type multipart/form-data & a string data called "userid=SOME_ID". I don't ...
- Modified
- 4 Mar at 10:16
..The underlying connection was closed: An unexpected error occurred on a receive
I have the following code: ``` private Uri currentUri; private void Form1_Load(object sender, EventArgs e) { currentUri = new Uri(@"http://www.stackoverflow.com"); HttpWebRequest myRequest =...
- Modified
- 6 May at 09:27
Regex to Match Symbols: !$%^&*()_+|~-=`{}[]:";'<>?,./
I'm trying to create a Regex test in JavaScript that will test a string to contain any of these characters: ``` !$%^&*()_+|~-=`{}[]:";'<>?,./ ``` It's for a pretty cool password change applicatio...
- Modified
- 17 Sep at 20:58
Eclipse - Unable to install breakpoint due to missing line number attributes
I am getting this strange error in Eclipse while trying to set a breakpoint. ``` Unable to insert breakpoint Absent Line Number Information ``` I ticked the checkbox from Compiler options but no lu...
- Modified
- 20 Sep at 14:4
How to disable a input in angular2
In ts `is_edit = true` to disable... ``` <input [disabled]="is_edit=='false' ? true : null" id="name" type="text" [(ngModel)]="model.name" formControlName="name" class="form-control" minlength="2"> `...
- Modified
- 29 Nov at 05:12
SQL Server IF NOT EXISTS Usage?
Ok, so my schema is this: Table: Timesheet_Hours Columns: - - - - This is an extremely simplified version of the table, but it will serve for the purposes of this explaination. Assume that a person c...
- Modified
- 21 Nov at 19:49
Display a decimal in scientific notation
How can I display `Decimal('40800000000.00000000000000')` as `'4.08E+10'`? I've tried this: ``` >>> '%E' % Decimal('40800000000.00000000000000') '4.080000E+10' ``` But it has those extra 0's.
- Modified
- 22 Jun at 03:20
Create table with jQuery - append
I have on page div: ``` <div id="here_table"></div> ``` and in jquery: ``` for(i=0;i<3;i++){ $('#here_table').append( 'result' + i ); } ``` this generating for me: ``` <div id="here_table"...
- Modified
- 5 Jan at 20:23
The input is not a valid Base-64 string as it contains a non-base 64 character
I have a REST service that reads a file and sends it to another console application after converting it to Byte array and then to Base64 string. This part works, but when the same stream is received a...
How to loop and render elements in React.js without an array of objects to map?
I'm trying to convert a jQuery component to React.js and one of the things I'm having difficulty with is rendering n number of elements based on a for loop. I understand this is not possible, or re...
- Modified
- 30 Jan at 10:4
Extracting .jar file with command line
I am trying to extract the files from a .jar file. How do I do that using command line? I am running Windows 7
Add regression line equation and R^2 on graph
I wonder how to add regression line equation and R^2 on the `ggplot`. My code is: ``` library(ggplot2) df <- data.frame(x = c(1:100)) df$y <- 2 + 3 * df$x + rnorm(100, sd = 40) p <- ggplot(data = df...
- Modified
- 23 Mar at 12:37
Fixing "Lock wait timeout exceeded; try restarting transaction" for a 'stuck" Mysql table?
From a script I sent a query like this thousands of times to my local database: ``` update some_table set some_column = some_value ``` I forgot to add the where part, so the same column was set to ...
- Modified
- 8 Feb at 16:11
Link to reload current page
Is it possible to have a normal link pointing to the current location? I have currently found 2 solutions, but one of them includes JavaScript and in the other you have to know the absolute path to t...
Git reset single file in feature branch to be the same as in master
I'm trying to revert my changes in a in my feature branch and I want this file to be the same as in master. I tried: ``` git checkout -- filename git checkout filename git checkout HEAD -- filenam...
- Modified
- 22 Jun at 15:43
Linq select objects in list where exists IN (A,B,C)
I have a list of `orders`. I want to select `orders` based on a set of order statuses. So essentially `select orders where order.StatusCode in ("A", "B", "C")` ``` // Filter the orders based on the ...
- Modified
- 3 Feb at 17:17
How to add value labels on a bar chart
I'm creating a bar chart, and I can't figure out how to add value labels on the bars (in the center of the bar, or just above it). I believe the solution is either with 'text' or 'annotate', but I: a)...
- Modified
- 30 Dec at 15:31
Using JsonConvert.DeserializeObject to deserialize Json to a C# POCO class
Here is my simple `User` POCO class: ``` /// <summary> /// The User class represents a Coderwall User. /// </summary> public class User { /// <summary> /// A User's username. eg: "sergiotapia...
- Modified
- 18 Mar at 09:52
Pythonic way to find maximum value and its index in a list?
If I want the maximum value in a list, I can just write `max(List)`, but what if I also need the index of the maximum value? I can write something like this: ``` maximum=0 for i,value in enumerate(L...
- Modified
- 21 Dec at 08:58
Pass an array of integers to ASP.NET Web API?
I have an ASP.NET Web API (version 4) REST service where I need to pass an array of integers. Here is my action method: ``` public IEnumerable<Category> GetCategories(int[] categoryIds){ // code to ...
- Modified
- 9 Jan at 17:47
How to style a clicked button in CSS
I looked at W3 schools website [W3Schools](https://www.w3schools.com/css/css3_buttons.asp) which explained styling buttons with CSS. I need to specify a button style when it is clicked. What is the ps...