Questions

How can I change Eclipse theme?

I want to change Eclipse theme like this Eclipse Dark Theme: ![eclipse dark theme](https://i.stack.imgur.com/sBJyS.png) I try to do all step in this page but eclipse theme not changed (but eclipse e...

14 Feb at 08:27

Find the PID of a process that uses a port on Windows

My service crash on startup with the classic: ``` java.rmi.server.ExportException: Listen failed on port: 9999 ``` How can I find the process for killing it?

6 Apr at 16:52

Making an API call in Python with an API that requires a bearer token

Looking for some help with integrating a JSON API call into a Python program. I am looking to integrate the following API into a Python .py program to allow it to be called and the response to be pri...

Angular + Material - How to refresh a data source (mat-table)

I am using a [mat-table](https://material.angular.io/components/table/overview) to list the content of the users chosen languages. They can also add new languages using dialog panel. After they added ...

31 Jul at 07:53

java.sql.SQLException: No suitable driver found for jdbc:mysql://localhost:3306/dbname

I have this Java program: `MySQLConnectExample.java` ``` import java.sql.*; import java.util.Properties; public class MySQLConnectExample { public static void main(String[] args) { Conne...

25 Jul at 17:37

JavaScript find json value

I need to search inside a json list of countries. The json is like: ``` [ {"name": "Afghanistan", "code": "AF"}, {"name": "Åland Islands", "code": "AX"}, {"name": "Albania", "code": "AL"}, {"name...

17 Aug at 14:44

What's the bad magic number error?

What's the "Bad magic number" ImportError in python, and how do I fix it? The only thing I can find online suggests this is caused by compiling a .py -> .pyc file and then trying to use it with the w...

5 Feb at 03:13

Xampp Access Forbidden php

I'm a windows user. I've been using xampp for quite a while but suddenly none of my .php files are working now! I get this error message: --- Access forbidden! You don't have permission to acces...

23 Jul at 17:12

"The given path's format is not supported."

I have the following code in my web service: ``` string str_uploadpath = Server.MapPath("/UploadBucket/Raw/"); FileStream objfilestream = new FileStream(str_uploadpath + fileName, Fil...

26 Apr at 08:16

Configuration System Failed to Initialize

I'm currently creating a Login form and have this code: ``` string connectionString = ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString; try { using (OdbcConnection conne...

$on and $broadcast in angular

I have a footerController and codeScannerController with different views. ``` angular.module('myApp').controller('footerController', ["$scope", function($scope) {}]); angular.module('myApp').control...

19 May at 13:20

How can I read user input from the console?

I want to get a number from the user, and then multiply that number with Pi. my attempt at this is below. But `a` contains gibberish. For example, if I insert `22`, then `a` contains `50`. What am I d...

9 Jan at 21:10

Override default Spring-Boot application.properties settings in Junit Test

I have a Spring-Boot application where the default properties are set in an `application.properties` file in the classpath (src/main/resources/application.properties). I would like to override some d...

15 Feb at 13:52

How do I jump out of a foreach loop in C#?

How do I break out of a `foreach` loop in C# if one of the elements meets the requirement? For example: ``` foreach(string s in sList){ if(s.equals("ok")){ //jump foreach loop and retu...

7 Aug at 07:36

How can I scale an entire web page with CSS?

Using Firefox, you can enlarge an entire web page by simply pressing . What this does is proportionally enlarge the entire web page (fonts, images, etc). How can I replicate the same functionality u...

22 May at 06:29

Indentation shortcuts in Visual Studio

I'm using Visual Studio 2010 and C#. How can I indent the selected text to left/right by using shortcuts? ![enter image description here](https://i.stack.imgur.com/DVw7b.png) In the Delphi IDE the equ...

How can I access localhost from another computer in the same network?

I just recently downloaded WAMP Server to view and edit php webpages but now I would also like other people in my network (connected to the same wifi) to be able to access localhost and all the files ...

20 Oct at 20:0

Javascript seconds to minutes and seconds

This is a common problem but I'm not sure how to solve it. The code below works fine. ``` var mind = time % (60 * 60); var minutes = Math.floor(mind / 60); var secd = mind % 60; var seconds ...

2 Nov at 08:2

Server unable to read htaccess file, denying access to be safe

I have created a simple app using AngularJS. When I tried to host that project in my website [http://demo.gaurabdahal.com/recipefinder](http://demo.gaurabdahal.com/recipefinder) it shows the following...

2 Sep at 13:54

How can I get the DateTime for the start of the week?

How do I find the start of the week (both Sunday and Monday) knowing just the current time in C#? Something like: ``` DateTime.Now.StartWeek(Monday); ```

22 Oct at 09:22

How to get the absolute coordinates of a view

I'm trying to get the absolute screen pixel coordinates of the top left corner of a view. However, all methods I can find such as `getLeft()` and `getRight()` don't work as they all seem to be relativ...

14 Jan at 11:24

What should I do when 'svn cleanup' fails?

I have a lot of changes in a working folder, and something screwed up trying to do an update. Now when I issue an 'svn cleanup' I get: ``` >svn cleanup . svn: In directory '.' svn: Error processing ...

9 Jan at 21:53

Is the practice of returning a C++ reference variable evil?

This is a little subjective I think; I'm not sure if the opinion will be unanimous (I've seen a lot of code snippets where references are returned). According to a comment toward [this question I jus...

30 Aug at 08:13

Java: int[] array vs int array[]

Is there a difference between ``` int[] array = new int[10]; ``` and ``` int array[] = new int[10]; ``` ? Both do work, and the result is exactly the same. Which one is quicker or better? Is th...

31 Jan at 07:16

Cannot ping AWS EC2 instance

I have an EC2 instance running in AWS. When I try to ping from my local box it is not available. How can I make the instance pingable?