Why doesn't @try block work?
It crashed the app, but it was supposed to be caught by the @try block.
NSString* test = [NSString stringWithString:@"ss"];
@try {
[test characterAtIndex:6];
}
..
I would like to find the location of a character in a string.
Say: string = "the2quickbrownfoxeswere2tired"
I would like the function to return 4 and 24 -- the character location of the 2s in strin..
I have Postgresql on a server in a docker container. How can I connect to it from the outside, that is, from my local computer? What setting should I apply to allow that?..
I have big amount of data that I collected from different files. In this main workbook, I have different types of formulas for every cells. In range A to F is where the data from other files are colle..
I'm using find to all files in directory, so I get a list of paths. However, I need only file names. i.e. I get ./dir1/dir2/file.txt and I want to get file.txt..
I have a dataframe from which I remove some rows. As a result, I get a dataframe in which index is something like that: [1,5,6,10,11] and I would like to reset it to [0,1,2,3,4]. How can I do it?
T..
I'm trying to run an openssl command to narrow down what the SSL issue might be when trying to send an outbound message from our system.
I found this command in another topic: Using openssl to get th..
I have a very simple task I am trying to do in Groovy but cannot seem to get it to work. I am just trying to loop through a map object in groovy and print out the key and value but this code does not ..
What command does one have to enter at the command line in Windows 7 to compile a basic C program?
Like I am literally wondering what you type in the command prompt, to compile a .c file.
I tried:
..
I have a problem using java rmi:
When I'm trying to run my server, I get a connectException (see below).
Exception happens when executing the rebind method:
Runtime.getRuntime().exec("rmiregistry 2..
I want my users to be able to click a button to open my company's webpage in the default browser when clicked. How would I do this?
I'm using VB.net so all .net examples are acceptable...
I have a model:
public class DbUserRole
{
public int UserRoleId { get; set; }
public string UserRole { get; set; }
}
public class DbUserRoles
{
public List<DbU..
The function more() is supposed to return an Observable from a get request
export class Collection{
public more = (): Observable<Response> => {
if (this.hasMore()) {
re..
I have this code:
// basic file operations
#include <iostream>
#include <fstream>
using namespace std;
int main()
{
writeFile();
}
int writeFile ()
{
ofstream myfile;
myfile.op..
I have few .bat files that I used under Windows XP. Now I want to use them under Windows 10, but when I run one of the files (even as administrator) it shows the command prompt screen for 1 second and..
I want to do some programming with the latest JavaFX, which requires Java 8. I'm using IntelliJ 13 CE and Mac OS X 9 Mavericks. I ran Oracle's Java 8 installer, and the files look like they ended up a..
I have recently been studying UML and drawing simple diagrams with ordinary plain arrows between classes, but I know it's not enough. There are plenty of other arrows: generalization, realisation and ..
Note: This question was originally asked here but the bounty time expired even though an acceptable answer was not actually found. I am re-asking this question including all details provided in the or..
I'm trying to insert data to a table from another table and the tables have only one column in common. The problem is, that the TABLE1 has columns that won't accept null values so I can't leave them e..
I'm trying to transcode a bunch of files from US-ASCII to UTF-8.
For that, I'm using iconv:
iconv -f US-ASCII -t UTF-8 file.php > file-utf8.php
My original files are US-ASCII encoded, which mak..
Our Mysql queries use temporary tables which creates temporary files in the process. Currently the files are written to /tmp. How exactly can the path of the temp folder to which mysql writes to be ch..
What I need is to encrypt string which will show up in 2D barcode(PDF-417) so when someone get an idea to scan it will get nothing readable.
Other requirements:
should not be complicated
it shoul..
I have a datasets where all the dates have the following format:
2012-10-09T19:00:55Z
I'd like to be able to be able to use methods like .weekday on them. How do I convert them to the proper format..
I have tables that I've tried setting PK FK relationships on but I want to verify this. How can I show the PK/FK restraints? I saw this manual page, but it does not show examples and my google search ..
I'm new to OS X, having just gotten a Mac after working with Ubuntu Linux for some time. Among the many things I'm trying to figure out is the absence of colors in my terminal window - like the ones t..
Basically I have a table similar to this:
time.....activities.....length
13:00........3.............1
13:15........2.............2
13:00........3.............2
13:30........1.............1
..
If I have a URL that, when submitted in a web browser, pops up a dialog box to save a zip file, how would I go about catching and downloading this zip file in Python?..
I need to write a macro that searches a specified column and counts all the cells that contain a specified string, such as "19/12/11" or "Green" then associate this number with a variable,
Does anyon..
I want to compare two dates and check if the date has expired or not.
Here is the code I used :
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd hh:ss:ii");
Date date1 = sdf.parse("20012-10-4..
How can I loop over a class attributes in java dynamically.
For eg :
public class MyClass{
private type1 att1;
private type2 att2;
...
public void function(){
for(var in MyC..
I've run out of space on a virtual machine disk which is a vmdk and need to resize the virtual image. Resizing with the command
vboxmanage modifyhd Machine-disk1.vmdk --resize 30720
gives the erro..
How can i send an email with an attachment (either local file or a file in the intranet) using outlook 2010?
<a href="mailto:[email protected]?subject=my report&body=see attachment&attachment=c:..
I have a class that I want to use to store "properties" for another class. These properties simply have a name and a value. Ideally, what I would like is to be able to add typed properties, so that th..
I just installed the ADO.NET connector from here http://dev.mysql.com/downloads/connector/net/
Yet MySQL doesn't appear as a data source like it should. I tried restarting Visual Studio. It doesn't f..
I am getting this error with the following:
jquery.dataTables.js:4089 Uncaught TypeError: Cannot read property 'style' of undefined(…)
_fnCalculateColumnWidths @ jquery.dataTables.js:4089
_fnInitia..
I have a problem with my query and I need to join two tables from different databases now my problem is how can I execute my query. I got my syntax format from here
Please visit first this link so y..
I need to modify the file /etc/httpd/conf.d/phpMyAdmin.conf
in order to allow remote users (not only localhost) to login
# phpMyAdmin - Web based MySQL browser written in php
#
# Allows only localho..
I have a site using a custom favicon.ico. The favicon displays as expected in all browsers except IE. When trying to display the favicon in IE, I get the big red x; when displaying the favicon in anot..
Due to a plugin being used, I can't add the "onClick" attribute to the HTML form inputs like usual.
A plugin is handling the forms part in my site and it doesn't give an option to do this automaticall..
I just open a console application and I type
Console.WriteLine("Test");
But the output window doesn't show this. I go to the output window with Ctrl+W,O
But nothing shows up when I run my program,..
I get the error:
C:\dev\ws\springapp\build.xml:81: Unable to find a javac compiler;
com.sun.tools.javac.Main is not on the classpath.
Perhaps JAVA_HOME does not point to the JDK.
It is currently set..
I'm trying to find the files existing in one directory but not in the other, I tried to use this command:
diff -q dir1 dir2
The problem with the above command that it finds both the files in dir1 b..
I have a div on my page:
<div id='div1' style='overflow:scroll;overflow-x:hidden;max-height:200px;'></div>
How can I make the div scroll to the bottom of the div?? Not the page, just th..
Is there a way to get the path for the assembly in which the current code resides? I do not want the path of the calling assembly, just the one containing the code.
Basically my unit test needs to ..
I need to count the number of elements in an XML file that have a particular value (to verify uniqueness). The XML file looks like this:
EDIT: I updated the original "simplified" XML with the actual ..
I want to verify whether a collection is empty and null. Could anyone please let me know the best practice.
Currently, I am checking as below:
if (null == sampleMap || sampleMap.isEmpty()) {
// do..
I'd like to add option to a select dynamically using plain javascript. Everything I could find involves JQuery or tries to create the select dynamically as well. The closest thing I could find was D..
I have a web site that allows users to upload images of cars and I would like to put a privacy filter in place to detect registration plates on the vehicle and blur them.
The blurring is not a proble..
I want to set table name in a dynamic SQL query. I tried successfully for parameter as following:
/* Using sp_executesql */
/* Build and Execute a Transact-SQL String with a single parameter
value U..
I have four projects in my Visual Studio solution (everyone targeting .NET 3.5) - for my problem only these two are important:
MyBaseProject <- this class library references a third-party DLL fil..
I am trying to populate any rows missing a value in their InterfaceID (INT) column with a unique value per row.
I'm trying to do this query:
UPDATE prices SET interfaceID = (SELECT ISNULL(MAX(interf..
Many libraries I have found, like Jcrop, do not actually do the cropping, it only creates an image cropping UI. It then depends on the server doing the actual cropping.
How can I make the image cropp..
If I have one long list: myList = [0,2,1,0,2,1] that I split into two lists:
a = [0,2,1]
b = [0,2,1]
how can I compare these two lists to see if they are both equal/identical, with the constraint t..
How to edit PATH variable on mac (Lion). I cannot find any file where I can add paths. can someone guide me about it?
Whats the file name? .profile or .bash_profile???
and where I can find it?
I hav..
I am using pgAdmin version 1.14.3. PostgreSQL database version is 9.1.
I got all Db script for table creation but unable to export all data inside tables. Could not find any option to export data in ..
I need to execute part of a bash script as a different user, and inside that user's $HOME directory. However, I'm not sure how to determine this variable. Switching to that user and calling $HOME does..
I have been struggling with this for a few hours. I am on a Mac using Yosemite. I had homebrew installed, and was using git just fine. I tried doing $git add -i and I got this error:
Can't locate ..
My first column is an index, with monotonously increasing numbers, which ends at a non predictable point.
Now I want to find out, how many entries this column has. Is there a better way than iterating..
I have an Android app that has a default theme of Holo.Light but I want to change it to Theme.Black.I tried to do this by changing the style tag in the manifest android:theme="@style/AppTheme" to Them..
I am getting this JDBC exception. I googled it but the explanation was very abstract.
DB2 SQL error: SQLCODE: -206, SQLSTATE: 42703
com.misys.liq.jsqlaccess.adapter.jdbcadapter.util.JDBCAdapterExcep..
i created a sequence using the following query,
create sequence qname_id_seq start with 1 increment by 1 nocache;
Now when i try to create a table which uses the above sequence, it is throwing the ..
I'm using Xcode 6 Beta 4. I have this weird situation where I cannot figure out how to appropriately test for optionals.
If I have an optional xyz, is the correct way to test:
if (xyz) // Do somethi..
How to flip any background image using CSS? Is it possible?
currenty I'm using this arrow image in a background-image of li in css
On :visited I need to flip this arrow horizontally. I can do this..
I am using the AmazonS3Client in an Android app using a getObject request to download an image from my Amazon S3 bucket.
Currently, I am getting this exception:
com.amazonaws.services.s3.model.Amazo..
I have a form with <input type="submit". In chrome submit doesn't do anything. On a "network" in tab in developer tools I see nothing. No errors in developer tools either. Meanwhile, if I do save a..
I am using MS Excel 2010 and trying to get the current directory using the below code,
path = ActiveWorkbook.Path
But ActiveWorkbook.Path returns blank...
I have a table:
table votes (
id,
user,
email,
address,
primary key(id),
);
Now I want to make the columns user, email, address unique (together).
How do I do this in MySql?
O..
I'm looking for a very simple algorithm for computing the polygon intersection/clipping.
That is, given polygons P, Q, I wish to find polygon T which is contained in P and in Q, and I wish T to be max..
Before I do a small release and tag it, I'd like to update the package.json to reflect the new version of the program.
Is there a way to edit the file package.json automatically?
Would using a git p..
In Excel 2007, I am looping through the values of column 4 in Sheet 2. Still in Sheet 2, I want to output the result of my vlookup formula into column 5. The vlookup formula needs to refer to Sheet 1 ..
I have two tables in MySQL. Table Person has the following columns:
id | name | fruits
The fruits column may hold null or an array of strings like ('apple', 'orange', 'banana'), or ('strawberry'), ..
I have a procedure in SQL that I am trying to turn into Linq:
SELECT O.Id, O.Name as Organization
FROM Organizations O
JOIN OrganizationsHierarchy OH ON O.Id=OH.OrganizationsId
where OH.Hierarchy lik..
I have a shell script in which I need to check whether two files contain the same data or not. I do this a for a lot of files, and in my script the diff command seems to be the performance bottleneck...
I'm executing an external script, using a <script> inside <head>.
Now since the script executes before the page has loaded, I can't access the <body>, among other things. I'd like t..
In Visual Studio Professional, we have a shortcut key, Ctrl + M Ctrl + O to collapse all methods and properties in a class. How can I do a similar thing in Visual Studio Code?
I know there are short..
I am developing an application that query to the server. In my Mac, I use the hosts file to change the dns to point to a local server within my local area network.
Now I need to test it with my iPhon..
I am asking a quite simple question, but I am bit confused in this.
Suppose I have a class Parent:
public class Parent {
int name;
}
And have another class Child:
public class Child extends Pare..
Lets say I have this:
if(bool1 && bool2 && bool3) {
...
}
Now. Is Java smart enough to skip checking bool2 and bool2 if bool1 was evaluated to false? Does java even check them from ..
I'm trying to do something common enough: Parse user input in a shell script. If the user provided a valid integer, the script does one thing, and if not valid, it does something else. Trouble is, I h..
I have installed pip and ez setup. I also checked the system path and I can see the module in the folder structure. Still when i try to run pip command, I get an Import error saying no module named pi..
I'm trying to set the style of an action link like so:
<text><p>Signed in as @Html.ActionLink(Context.User.Identity.Name,"Index",new { Controller="Account", @style="text-transform:capit..
I want to use mstsc /admin to login to a server silently. My batch file reads the code as
mstsc /v:xxx.xxx.xxx.xxx /admin
But it ask me to enter password. Can anyone help me to skip this step?
I w..
How to know if .keyup() is a character key (jQuery)
$("input").keyup(function() {
if (key is a character) { //such as a b A b c 5 3 2 $ # ^ ! ^ * # ...etc not enter key or shift or Esc or space ...e..
Are comments possible in a Jenkinsfile? If so, what's the syntax?
I am using the declarative pipeline syntax.
I want to comment out the "post" section below until my SMTP server is working.
pipelin..
Sometimes I make a function and call the function later.
Example:
function example { alert('example'); }
example(); // <-- Then call it later
Somehow, some functions cannot be called. I have to..
I want to write a function that returns the nearest next power of 2 number. For example if my input is 789, the output should be 1024. Is there any way of achieving this without using any loops but ju..
I have a problem with this struct contructor when I try to compile this code:
typedef struct Node
{
Node( int data ) //
{
this->data = data;
previous = NULL; // Compiler in..
Althought I pushed a parameter to getElementById I wonder from where is this 'is null' error coming from?
TypeError: document.getElementById(...) is null
[Break On This Error]
document.getElemen..
Recently I've seen an example like the following:
#include <iostream>
class Foo {
public:
int bar;
Foo(int num): bar(num) {};
};
int main(void) {
std::cout << Foo(42).bar <<..
I have an HttpClient that I am using for a REST API. However I am having trouble setting up the Authorization header. I need to set the header to the token I received from doing my OAuth request.
I sa..
Basically, I want to do this:
update vehicles_vehicle v
join shipments_shipment s on v.shipment_id=s.id
set v.price=s.price_per_vehicle;
I'm pretty sure that would work in MySQL (my backgroun..
In SQL server 2008, I would like to get datetime column rounded to nearest hour and nearest minute preferably with existing functions in 2008.
For this column value 2007-09-22 15:07:38.850, the outpu..
I would like to check server-side if a request to my php page is an ajax request or not.
I saw two ways to do this:
First way: sending a GET parameter in the request which tells the page that this i..
I have a huge query which uses case/when often. Now I have this SQL here, which does not work.
(select case when xyz.something = 1
then
'SOMETEXT'
else
(select case when xyz.somethingel..
I am trying to use python package manager pip to install a package and it's dependencies from the internet. However I am behind a proxy in my college and have already set the http_proxy environment va..
We are using UUID as primary key for out oracle DB, and trying to determine an appropriate max character length for the VARCHAR. Apparently this is 36 characters but we have noticed UUID'S generated w..
I have written the following code:
package staticshow;
public class StaticDemo {
static int a = 3;
static int b = 4;
static {
System.out.println("Voila! Static block put into action");
..
I had this construction error when trying to creating a new DateTime object using a timestamp:
Exception: DateTime::_construct(): Failed to parse time string (1372622987) at position 8 (8): Unexpe..
I didn't find any example how to solve my problem, so I want to ask you for help. I can't simply send POST request using RestTemplate object in JSON
Every time I get:
org.springframework.web.clie..
How do I create a namespace in JavaScript so that my objects and functions aren't overwritten by other same-named objects and functions? I've used the following:
if (Foo == null || typeof(Foo) != "ob..
I have checkboxes in my form
I added at my model
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
namespace CorePartners_Site2.Models
{
public class Care..
We have several JavaScript files which we load at the bottom of the master page. However, I have the situation that I need to perform some JavaScript before the other scripts are loaded. Is it possibl..
I need a function that can return the difference between the below two dates as 24.
DateTime a = new DateTime(2008, 01, 02, 06, 30, 00);
DateTime b = new DateTime(2008, 01, 03, 06, 30, 00);
..
I am using the javac compiler to compile java files in my project. The files are distributed over several packages like this: com.vistas.util, com.vistas.converter, com.vistas.LineHelper, com.current...
When implementing the new Google Invisible reCATPTCHA, by default you get a little "protected by reCAPTCHA" badge in the bottom right of the screen that pops out when you roll over it.
I'd like to ..
How can I remove a line (or lines) of a matplotlib axes in such a way as it actually gets garbage collected and releases the memory back? The below code appears to delete the line, but never releases..
Is there a (Unix) shell script to format JSON in human-readable form?
Basically, I want it to transform the following:
{ "foo": "lorem", "bar": "ipsum" }
... into something like this:
{
"foo"..
I want to include file name 'main.txt' in the subject for that I am passing file name from command line. but getting error in doing so
python sample.py main.txt #running python with argument
msg['..
I want to calculate difference between 2 dates in hours/minutes/seconds.
I have a slight problem with my code here it is :
String dateStart = "11/03/14 09:29:58";
String dateStop = "11/03/14 09:33:..
Can someone help explain how can building a heap be O(n) complexity?
Inserting an item into a heap is O(log n), and the insert is repeated n/2 times (the remainder are leaves, and can't violate the ..
Is there a difference between these two CSS properties:
background: none;
background: transparent;
Are they both valid?
Which one should be used and why?
..
In the Chrome's developer pane, I can see these css settings of an element.
As far as I can see, every single font-family value is inherit.
How can I find what is the actual value of the font fam..
I'm scanning through a file looking for lines that match a certain regex pattern, and then I want to print out the lines that match but in alphabetical order. I'm sure this is trivial but vbscript isn..
I want to use PHP to connect to sql server database.
I installed xampp 1.7.0(php 5.2) and SQLSRV20. I've added the extensions in php.ini and I get this error:
Warning: mssql_connect() [function.mss..
I'd like to handle the Closing event (when a user clicks the upper right 'X' button) of my window in order to eventually display a confirm message or/and cancel the closing.
I know how to do this in ..
I've got a simple setup to allow a "help"-style window to be loaded and scrolled to a particular point on the page. More or less the code looks like this:
var target = /* code */;
target.offsetParent..
I am trying to parse HTML in android from a webpage, and since the webpage it not well formed, I get SAXException.
Is there a way to parse HTML in Android?..
1 - I'm reading the documentation and I'm slightly confused with the wording. It says:
ClusterIP: Exposes the service on a cluster-internal IP. Choosing this value makes the service only reachable..
I was working on my Spring boot app project and noticed that, sometimes there is a connection time out error to my Database on another server(SQL Server).
This happens specially when I try to do some..
I am trying to make a function which will execute when the value of a text input field is changed. The value of the field changes when a table cell is clicked, not on keyup, nor paste. I tried it like..
When I run:
C:\Users\ashahria\Downloads>java -jar schemaSpy_5.0.0.jar
I get the error below. What is wrong? How can I fix it?
Error: Registry key 'Software\JavaSoft\Java Runtime Environment'\Curre..
I have developed an application and i was planning to deploy it to my HTC Desire.
I have installed USB driver. I turned on USB debugging on the phone and choosed charge only when phone plugged-in. Whe..
Is there a way to resize (scale down) images proportionally using ONLY CSS?
I'm doing the JavaScript way, but just trying to see if this is possible with CSS...
I have a String variable (basically an English sentence with an unspecified number of numbers) and I'd like to extract all the numbers into an array of integers. I was wondering whether there was a qu..
I have two columns in table users namely registerDate and lastVisitDate which consist of datetime data type. I would like to do the following.
Set registerDate defaults value to MySQL NOW()
Set last..
I'm using m2eclipse as my maven 2 plugin for eclipse. I'm brand new to maven, so my mistake might be simple, although searching has not yielded any solutions for me. I can run maven from the command..
I've got a python project with a configuration file in the project root.
The configuration file needs to be accessed in a few different files throughout the project.
So it looks something like: <..
I'm testing out Git and Bitbucket.
I've created a repository on Bitbucket and have created a local copy of the repo and I am committing files into it. I can't seem to push the files from my local rep..
Lets say that I have a git repo that looks like this.
foo/
.git/
A/
... big tree here
B/
... big tree here
Is there a way to ask git log to show only the log messages for a specific dir..
I'm using WAMP in my local machine, when a FORM(method="POST") with 2000 input fields is submitted I'm able to read only 1001 _POST variable. i.e With Netbeans debugger I can clearly see _PO..
I have written a library in Swift and I wasn't able to import it to my current project, written in Objective-C.
Are there any ways to import it?
#import "SCLAlertView.swift" - 'SCLAlertView.swift' ..
Im trying to figure out how to reverse the string temp when I have the string read in binary numbers
istream& operator >>(istream& dat1d, binary& b1)
{
string..
Using reflection, how can I get all types that implement an interface with C# 3.0/.NET 3.5 with the least code, and minimizing iterations?
This is what I want to re-write:
foreach (Type t in this.Ge..
I have a Javascript object like:
var my_object = { a:undefined, b:2, c:4, d:undefined };
How to remove all the undefined properties? False attributes should stay...
If I have a text file with a separate command on each line how would I make terminal run each line as a command? I just don't want to have to copy and paste 1 line at a time. It doesn't HAVE to be a t..
I am trying to connect to a MySQL server with python connector. I created a new user lcherukuri with the authentication plugin mysql_native_password.
But I got the error
mysql.connector.errors.No..
I'm trying to test my React application on a mobile device. I'm using ngrok to make my local server available to other devices and have gotten this working with a variety of other applications. Howeve..
As the title states, I have trouble understanding loops and have come up with a way to do a simple 1 through 100 sum, but like I said, the loops are causing me some confusion. I think I have the FOR L..
Retrofit 2's documentation says:
Headers that need to be added to every request can be specified using an OkHttp interceptor.
It can be done easily using the previous version, here's the related..
I am trying to add rows to the tbody of a table. But I am having issues with achieving that. Firstly, the function where everything takes place is called on change of a dropdown from a html page. I cr..
I'm writing a HTML page with a registration button that should just silently send an email without opening the local mail client. Here is my HTML:
<form method="post" action="">
<input t..
Sometimes I rerun a script within the same ipython session and I get bad surprises when variables haven't been cleared. How do I clear all variables?
And is it possible to force this somehow every tim..
Need to have the server make a POST to an API, how do I add POST values to a WebRequest object and how do I send it and get the response (it will be a string) out?
I need to POST TWO values, and some..
I have 2 tables and am trying to do one query to save myself some work.
Table 1: id, category id, colour
Table 2: category id, category name
I want to join them so that I get id, category id, cate..
I have an HMTL / CSS website built in Dreamweaver CS4 and I would like to add a 'share by email' link to the site (so that anyone who clicks on it can easily send a link to the site to their chosen re..
It's difficult to explain the case by words, let me give an example:
var myObj = {
'name': 'Umut',
'age' : 34
};
var prop = 'name';
var value = 'Onur';
myObj[name] = value; // This does not..
We are trying to build our own form-field-Components at our Company. We are trying to wrap material design's Components like this:
field:
<mat-form-field>
<ng-content></ng-content..
I have been trying to work on creating a tree (like a directory tree) that uses as much CSS and as little JS as possible (only for states, etc), and I want to know if there are some good existing tree..
I've a model with a byte array image file that I want to show on the page.
How can I do that without going back to the Database?
All the solutions that I see use an ActionResult to go back to the da..
Any ideas on how I could implement an auto-reload of files in Node.js? I'm tired of restarting the server every time I change a file.
Apparently Node.js' require() function does not reload files if t..
I'm trying to set up a server with python from mac terminal.
I navigate to folder location an use:
python -m SimpleHTTPServer
But this gives me error:
socket.error: [Errno 48] Address already ..
I need to have a class constructor in PHP call its parent's parent's (grandparent?) constructor without calling the parent constructor.
// main class that everything inherits
class Grandpa
{
pub..
I am using Java to get a String input from the user. I am trying to make the first letter of this input capitalized.
I tried this:
String name;
BufferedReader br = new InputStreamReader(System.in)..
I believe I have come up with a very efficient way to read very, very large files line-by-line. Please tell me if you know of a better/faster way or see room for improvement. I am trying to get bette..
My problem is that the webpage is not loaded inside the WebView.
mWebview.loadUrl("http://www.google.com"); launches the web browser...
This is the code of my activity:
import android.app.Ac..
I have jenkins.war and I started it from command prompt in Windows as:
java -jar jenkins.war
It was started well and easily browsed as http://localhost:8080
I want to start on 9090 port. How can I..
I'm getting this error from time to time and don't know what causing this:
When trying to run/debug an Android app on a real device (Galaxy Samsung S in my case) I'm getting the following error in the..
I am using Mockito for service later unit testing. I am confused when to use doAnswer vs thenReturn.
Can anyone help me in detail? So far, I have tried it with thenReturn. ..
I have a list of lists in Python:
k = [[1, 2], [4], [5, 6, 2], [1, 2], [3], [4]]
And I want to remove duplicate elements from it. Was if it a normal list not of lists I could used set. But unfortun..
I keep receiving this error when I do some Ajax calls...
It may even be something to do with Geocoding but I really have no idea how to capture the error to display something useful to users... or ev..
Maybe this is a silly question, but I cannot guess how to solve it if it's not creating a method. Maybe there's a "natural way" to do it, like in C for example. Here's the problem:
I have a var:
dou..
I want to make a list row layout. This layout has a imageview in the most left, a textview right next to the imageview, and a imageview in the most right. I want all of them are center vertical.
<..
I have an application that uses Google FCM for sending push notifications.
When i send a push notification to a group of users, i get a response of MismatchSenderId for some of them. Even though, all..
I've been trying to get a fix and can't find why the error keeps appearing. Pmin,Pmax,w,fi1 and fi2 have all been assigned finite values
guess=Pmin+(Pmax-Pmin)*((1-w**2)*fi1+(w**2)*fi2)
When i r..
How do I change the width of a select field, when using Twitter bootstrap? Adding input-xxlarge CSS classes doesn't seem to work (like it does on other form elements), so the elements in my drop down ..
I am going through learning curve with AngularJs and I am finding that there are virtually no examples that serve real world use.
I am trying to get a clear understanding of how to submit a form with..
I working with node.js by expressjs I try to store an account to session. So, i try to test to use session with code in expressjs
var RedisStore = require('connect-redis')(express);
app.use(express...
I setup global namespaces for my objects by explicitly setting a property on window.
window.MyNamespace = window.MyNamespace || {};
TypeScript underlines MyNamespace and complains that:
The pro..
I have created a CSS stylesheet for my project. Is there any way I can create a css rule that applies to all table elements EXCEPT table elements belonging to the class "dojoxGrid"? Something like:
...
I am attempting to work with a very large dataset that has some non-standard characters in it. I need to use unicode, as per the job specs, but I am baffled. (And quite possibly doing it all wrong.)
..
I want to change css property of class using javascript. What i actually want is when a div is hoverd, another div should become visible.
My css is like..
.left, .right{
margin:10px;
float:l..
When I do git fetch origin and origin has a deleted branch, it doesn't seem to update it in my repository. When I do git branch -r it still shows origin/DELETED_BRANCH.
How can I fix this?..