Questions

Sort table rows In Bootstrap

Can someone please show me an example of code that I would have to use to sort a column of a table in Bootstrap? For example, if I want to sort by price, or by name.

29 Oct at 16:56

How to check whether dynamically attached event listener exists or not?

Here is my problem: is it somehow possible to check for the existence of a dynamically attached event listener? Or how can I check the status of the "onclick" (?) property in the DOM? I have searched ...

What datatype to use when storing latitude and longitude data in SQL databases?

When storing latitude or longitude data in an ANSI SQL compliant database, what datatype would be most appropriate? Should `float` be used, or `decimal`, or ...? I'm aware that Oracle, MySql, and SQL...

Rounding a double to turn it into an int (java)

Right now I'm trying this: ``` int a = round(n); ``` where `n` is a `double` but it's not working. What am I doing wrong?

24 Oct at 19:1

C# HttpClient 4.5 multipart/form-data upload

Does anyone know how to use the `HttpClient` in .Net 4.5 with `multipart/form-data` upload? I couldn't find any examples on the internet.

Linq Syntax - Selecting multiple columns

This is my Linq Syntax which I am using to my entity model ``` IQueryable<string> objEmployee = null; objEmployee = from res in _db.EMPLOYEEs where (res.EMAIL == givenInfo || res.USER_...

9 Aug at 07:31

Android - Back button in the title bar

In many apps (Calendar, Drive, Play Store) when you tap a button and enter a new activity, the icon in the title bar turns into a back button, but for the app I am making, it doesn't do that. How do I...

How to send a Post body in the HttpClient request in Windows Phone 8?

I have written the code below to send headers, post parameters. The problem is that I am using SendAsync since my request can be GET or POST. How can I add POST Body to this peice of code so that if t...

6 Aug at 10:55

Is Unit Testing worth the effort?

I am working to integrate unit testing into the development process on the team I work on and there are some sceptics. What are some good ways to convince the sceptical developers on the team of the v...

10 Apr at 19:43

Non-static method requires a target

I have a controller action that works fine on Firefox both locally and in production, and IE locally, but not IE in production. Here is my controller action: ``` public ActionResult MNPurchase() { ...

How to make EditText not editable through XML in Android?

Can anyone tell me how to make an `EditText` not editable via XML? I tried setting `android:editable` to `false`, but 1. it is deprecated; and 2. it didn't work.

12 Feb at 23:47

PostgreSQL delete all content

Hello I want to delete all data in my postgresql tables, but not the table itself. How could I do this?

27 Feb at 10:0

In Flask, what is "request.args" and how is it used?

As a Flask beginner, I can't understand how `request.args` is used. I read somewhere that it is used to return values of query string (correct me if I'm wrong) and how many parameters `request.args.ge...

10 Oct at 06:30

Query for array elements inside JSON type

I'm trying to test out the `json` type in PostgreSQL 9.3. I have a `json` column called `data` in a table called `reports`. The JSON looks something like this: ``` { "objects": [ {"src":"foo.pn...

28 Feb at 08:52

Determine the number of lines within a text file

Is there an easy way to programmatically determine the number of lines within a text file?

24 Nov at 02:42

Entity Framework Provider type could not be loaded?

I am trying to run my tests on TeamCity which is currently installed on my machine. > `System.InvalidOperationException`: The Entity Framework provider type '`System.Data.Entity.SqlServer.SqlProvid...

Text was truncated or one or more characters had no match in the target code page including the primary key in an unpivot

I'm trying to import a flat file into an oledb target sql server database. here's the field that's giving me trouble: ![enter image description here](https://i.stack.imgur.com/CBYws.png) here are t...

28 Aug at 17:14

How to pass table value parameters to stored procedure from .net code

I have a SQL Server 2005 database. In a few procedures I have table parameters that I pass to a stored proc as an `nvarchar` (separated by commas) and internally divide into single values. I add it to...

Laravel Eloquent - Get one Row

This might be a simple question, but I cannot figure this out. I am trying to get a user by email using: ``` $user = User::whereEmail($email)->get(); ``` But this is returning an array (of dimensio...

29 May at 03:59

Push existing project into Github

I have a folder with my project sources. How I can push this project into Github's repository? I tried using this steps: 1. I created empty repository on GitHub. 2. I run git-bash and typed git in...

25 Jun at 07:54

How to detect Adblock on my website?

I would like to be able to detect if the user is using adblocking software when they visit my website. If they are using it, I want to display a message asking them to turn it off in order to support ...

9 Aug at 13:47

VSCode single to double quote automatic replace

When I execute a `Format Document` command on a Vue Component.vue file VSCode replace all single quoted string with double quoted string. In my specific case this rule conflicts with electron-vue lin...

27 May at 06:39

XPath: How to select elements based on their value?

I am new to using XPath and this may be a basic question. Kindly bear with me and help me in resolving the issue. I have an XML file like this: ``` <RootNode> <FirstChild> <Element attribute1="...

24 Sep at 08:46

why numpy.ndarray is object is not callable in my simple for python loop

I loaded a text file containing a two column matrix (e.g. below) ``` [ 1 3 2 4 3 5 2 0] ``` My calculation is just to sum each row i.e. 1+3, 2+4, 3+5 and 2+0. I am using the below c...

16 Jan at 23:38

Cannot stop or restart a docker container

When trying to stop or restart a docker container I'm getting the following error message: ``` $ docker restart 5ba0a86f36ea Error response from daemon: Cannot restart container 5ba0a86f36ea: [2] Con...

12 Jul at 09:30