I have a button "Choose file" as follows (I am using Jade but it should be the same as Html5):
input(type='file', name='videoFile')
In the browser this shows a button with a text next to it "No fi..
I have a quite simple JavaScript object, which I use as an associative array. Is there a simple function allowing me to get the key for a value, or do I have to iterate the object and find it out manu..
How do I search for a string in one particular row in excel? the I have the row index in a long type variable.
Dim rowIndex As Long
rowIndex = // some value being set here using some code.
Now I ne..
in es6 there you can define a module of functions like this
export default {
foo() { console.log('foo') },
bar() { console.log('bar') },
baz() { foo(); bar() }
}
the above seems to be ..
I am trying to setup Apache Spark on Windows.
After searching a bit, I understand that the standalone mode is what I want.
Which binaries do I download in order to run Apache spark in windows? I see ..
I have my persistence.xml with the same name using TopLink under the META-INF directory.
Then, I have my code calling it with:
EntityManagerFactory emfdb = Persistence.createEntityManagerFactory("agi..
In what segment (.BSS, .DATA, other) of an executable file are static variables stored so that they don't have name collision?
For example:
foo.c: bar.c:
static int foo = 1; ..
How can I programmatically remove a (known) password from an Excel VBA project?
To be clear: I want to remove the password from the VBA Project, not the workbook or any worksheets...
In Python, the only way I can find to concatenate two lists is list.extend, which modifies the first list. Is there any concatenation function that returns its result without modifying its arguments?..
I have the following 'set recordset' line that I cannot get working. The parameters seem correct according to all available help I can find on the subject.
The error displays :
"Run-time error '3..
I'm simply trying to access named pandas columns by an integer.
You can select a row by location using df.ix[3].
But how to select a column by integer?
My dataframe:
df=pandas.DataFrame({'a':np.r..
I have a certain element that I can select with Selenium 1.
Unfortunately I need to click the parent element to get the desired behaviour. The element I can easily locate has attribute unselectable, ..
I have a problem, I cannot pass any parameters to a modal window (using Bootstrap 3), I tried using the solution stated in this link, but I cannot make it work:
Dynamically load information to Twitte..
I'm trying to read a Json string in C#, but I'm having trouble figuring out just how to parse the string into C#. Say I have the following Json string
[
{
"AppName": {
"Descri..
I have a java application that connects to a database.
The user name and password for the database are stored in a properties file.
What is the common practice to avoid storing the password in clearte..
I am trying to call a stored procedure from my C# windows application. The stored procedure is running on a local instance of SQL Server 2008. I am able to call the stored procedure but I am not able ..
How do I scroll to the top of the page using JavaScript? The scrollbar instantly jumping to the top of the page is desirable too as I'm not looking to achieve smooth scrolling...
I've been looking through the Python Requests documentation but I cannot see any functionality for what I am trying to achieve.
In my script I am setting allow_redirects=True.
I would like to know ..
What is the best way to blur background images like the image below? I saw some code and libraries but their are a couple of years old or like BlurBehind library, but it doesn't give the same effect. ..
Im working on a project and im using some ul and li's.
But i cant seem to figure out how to remove those pesky black dots that come with those lists.
Can any of you help me with this?
Edit: i compl..
In my cms I have a checkbox group for categories. I would like to have a text input below that where the user can input the name of a new category and it will dynamically add a new checkbox with the p..
I want to have a chart that resizes with the browser window, but the problem is that the height is fixed to 400px. This JSFiddle example has the same problem.
How can I do that? I tried using the cha..
//in controller
ViewBag.Categories = categoryRepository.GetAllCategories().ToList();
//in view
@Html.DropDownList("Cat", new SelectList(ViewBag.Categories,"ID", "CategoryName"))
How can I make it ..
I just started to read "Pro Spring MVC with web flow" and it comes with a code sample that I want to follow.
What I want - I want to build the applications as it's done in the book, using Gradle
Wh..
I have a problem running phpMyAdmin. When I try to access phpMyAdmin in my browser, I get the error message: "The mbstring extension is missing. Please check your PHP configuration."
I have already s..
A common task in programming interviews (not from my experience of interviews though) is to take a string or an integer and list every possible permutation.
Is there an example of how this is done an..
I have the following code in my HomeController:
public ActionResult Edit(int id)
{
var ArticleToEdit = (from m in _db.ArticleSet where m.storyId == id select m).First();
return View(ArticleTo..
I've noticed that when using $.post() in jquery that the default contentType is application/x-www-form-urlencoded - when my asp.net mvc code needs to have contentType=application/json
(See this quest..
I'm trying to disable the html/body scrollbar of the parent while I'm using a lightbox. The main word here is disable. I do not want to hide it with overflow: hidden;.
The reason for this is that ove..
I am wondering if this is a valid query:
UPDATE table
SET ID = 111111259
WHERE ID = 2555
AND SET ID = 111111261
WHERE ID = 2724
AND SET ID = 111111263
WHERE ID = 2021
AND SET ID = 111111264
W..
I'm using React-router and it works fine while I'm clicking on link buttons, but when I refresh my webpage it does not load what I want.
For instance, I am in localhost/joblist and everything is fine..
I need to give a default value for input type=text field as follows:
<input type="text" size="32" value="" name="fee" />
There is one way to give this default value as I know:
<input type..
To start an interactive shell for the Ubuntu image we can run:
ole@T:~$ docker run -it --rm ubuntu
root@1a6721e1fb64:/# ls
bin boot dev etc home lib lib64 media mnt opt proc root run sbi..
I'm reading a binary file like this:
InputStream in = new FileInputStream( file );
byte[] buffer = new byte[1024];
while( ( in.read(buffer ) > -1 ) {
int a = // ???
}
What I want to do it t..
In SQL, I have col1 and col2. Both are integers.
I want to do like:
select col1/col2 from tbl1
I get the result 1 where col1=3 and col2=2
The result I want is 1.1
I put round(col1/col2,2). The r..
I am trying to use jQuery to do a simple thing: clear the input fields of a group of input field within a div whenever the form loads, or if the user changes a picklist; but I'm having a devil of a ti..
I want the code to be able to automatically update the time stamp when a new row is inserted as I can do in MySQL using CURRENT_TIMESTAMP.
How will I be able to achieve this in PostgreSQL?
CREATE TA..
I have a small and simple file in *.XLS with only one sheet, on this sheet just many cells with small text on number. (file size 24Kb)
But I made a lot of changes, copy and paste, extend formula, sav..
Could someone please advise the current "best practice" around Date and Calendar types.
When writing new code, is it best to always favour Calendar over Date, or are there circumstances where Date is..
My understanding was that Python strings are immutable.
I tried the following code:
a = "Dog"
b = "eats"
c = "treats"
print a, b, c
# Dog eats treats
print a + " " + b + " " + c
# Dog eats treats
..
I have a very simple functional component as follows:
import * as React from 'react';
export interface AuxProps {
children: React.ReactNode
}
const aux = (props: AuxProps) => props.child..
I'm having trouble parsing HTML elements with "class" attribute using Beautifulsoup. The code looks like this
soup = BeautifulSoup(sdata)
mydivs = soup.findAll('div')
for div in mydivs:
if (div[..
I'm storing an ArrayList of Ids in a processing script that I want to spit out as a comma delimited list for output to the debug log. Is there a way I can get this easily without looping through thing..
How do you fix the Subversion/Subclipse error "Attempted to lock an already-locked dir"?
Googling shows people routinely encounter this error, and the only solution I've seen posted is to run Subclip..
Without routing, HttpContext.Current.Session is there so I know that the StateServer is working. When I route my requests, HttpContext.Current.Session is null in the routed page. I am using .NET 3.5 s..
I have a problem with jenkins, setting "git", shows the following error:
Failed to connect to repository : Command "git ls-remote -h https://[email protected]/person/projectmarket.git HEAD" return..
I have written a filter function which will return data based on the argument you are passing. I want the same functionality in my controller. Is it possible to reuse the filter function in a controll..
I dont want to use html tag. This is my css. I am using bootstrap 3.0.
background:url('images/ip-box.png')no-repeat;
background-size:100%;
height: 140px;
display:block;
padding:0 !important;
margin:..
After reading this article about elapsed time, I wrote a simple code to calculate the execution time of a loop:
#include <stdio.h>
#include <sys/time.h>
int main (int argc, char** argv) ..
mydict = {"key1":"value1", "key2":"value2"}
The regular way to lookup a dictionary value in a Django template is {{ mydict.key1 }}, {{ mydict.key2 }}. What if the key is a loop variable? ie:
{% fo..
I am using cPanel of my website to increase maximum upload file size for wordpress media uploads. I have used the codes(found out from google) for this purpose wp-config.php, .htaccess but nothing is ..
I want to call myscript file in this way:
$ ./myscript -s 45 -p any_string
or
$ ./myscript -h #should display help
$ ./myscript #should display help
My requirements are:
getopt here to ge..
I need functionality in a script that will enable me to insert dates into a table.
What SQL do I need to insert a date of the format
01/08/2010 00:00:00
where the date is the first day of the curr..
After android installs an application from the Marketplace, does it keep the .apk file?
Is there a standard location where Android would keep such files?..
I've installed mongodb and have been able to run it, work with it, do simple DB read / write type stuff. Now I'm trying to set up my Mac to run mongod as a service.
I get "Command not found" in resp..
I've read the AngularJS documentation on the topic carefully, and then fiddled around with a directive. Here's the fiddle.
And here are some relevant snippets:
From the HTML:
<pane bi-title="ti..
When running Docker for a long time, there are a lot of images in system. How can I remove all unused Docker images at once safety to free up the storage?
In addition, I also want to remove images pu..
And the Kotlin newbie asks, "why won't the following code compile?":
var left: Node? = null
fun show() {
if (left != null) {
queue.add(left) // ERROR HERE
}
}
Smart ca..
I have a couple of buttons that acts as routes. Everytime the route is changed, I want to make sure the button that is active changes.
Is there a way to listen to route changes in react router v4?..
Is is possible to embed SVG markup into a ReactJS component?
render: function() {
return (
<span>
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmln ...
..
I am creating a figure in Matplotlib like this:
from matplotlib import pyplot as plt
fig = plt.figure()
plt.plot(data)
fig.suptitle('test title')
plt.xlabel('xlabel')
plt.ylabel('ylabel')
fig.savefi..
I design a function that may get/set a resource from SD and if not found from sd then take it from Asset and if possible write the asset back to SD
This function may check by method invocation if SD i..
I just learned that MySQL has a native CSV storage engine which stores data in a Comma-Separated-Value file per table.
Is it possible to create a table directly from a uploaded CSV file, something li..
I'm using pylint in Visual Studio Code to develop a Google App Engine (GAE) Cloud Endpoint API in Python. I'm unable to resolve a lint error. I don't know what's causing the error, but at a guess, pyl..
When searching for number of occurrences of a string in a file, I generally use:
grep pattern file | wc -l
However, this only finds one occurrence per line, because of the way grep works. How can I..
Xcode 6 GM now includes simulators for iPhone 6 and 6 Plus, and by default they run apps in a scaled mode.
To enable the new screen size I tried adding [email protected] which seems to do a part of..
I have a series of scripts running in parallel as a nohup on an AIX server hosting oracle 10g. These scripts are written by somebody else and are meant to be executed concurrently. All the scripts are..
public class PropHolder {
public static Properties prop;
static {
//code for loading properties from file
}
}
// Referencing the class somewhere else:
Properties prop = PropHolder.prop;
..
I kind of feel stupid, but I just can't get it to work....
I have an existing Android project copied from my other pc, in the folder
c:\projects\trunk\android\emergency
(I created that project on ..
I've always been unsure of where to start as a general best practice baseline. Yes, I know it depends on your design, but what's most common?
Here's what I currently have as a starter:
h1 { font-size:..
I have a backup from database in SQL Server 2008 R2.
When I want to restore this backup to SQL Server, I get this error:
"Error: Specified cast is not valid. (SqlManagerUI)"
How to I resolve this erro..
I am planning to connect to Facebook chat from my localhost. I will need to get the session key from Facebook. When I give the site URL as localhost:8080 or ip-address:8080 it does not work.
I read ..
I want to use a single font named "Algerian" across my whole website. So, I need to change all HTML tags and I don't want to write different code for different tags like:
button{font-family:Algerian..
#include <stdio.h>
int main()
{
int countch=0;
int countwd=1;
printf("Enter your sentence in lowercase: ");
char ch='a';
while(ch!='\r')
{
ch=getche();
if(ch==' ')
co..
I have one activity - MainActivity. Within this activity I have two fragments, both of which I created declaratively within the xml.
I am trying to pass the String of text input by the user into Fra..
I have been reading a lot of Javascript lately and I have been noticing that the whole file is wrapped like the following in the .js files to be imported.
(function() {
...
code
...
})()..
Upon reading this (archived) tutorial, they have not mentioned anything over creating tables in the DB. Does the Hibernate handle it automatically by creating tables and fields once i specify them.
He..
This works perfectly...but when I use foreach instead of for this doesn't works. I can't understand for and foreach are same.
namespace ConsoleApplication2
{
class Program
{
static vo..
I am trying to figure out how to append multiple values to a list in Python. I know there are few methods to do so, such as manually input the values, or put the append operation in a for loop, or the..
If there is a JavaScript object:
var objects={...};
Suppose, it has more than 50 properties, without knowing the property names (that's without knowing the 'keys') how to get each property value in a..
I'm developing using the GSSAPI, and I have code which works with a vanilla MIT Kerberos 5 server to do some client/server work. I'm now verifying it's functionality against Active Directory and I've ..
I just installed SQL Server 2012 Express, I can connect with database from VS2012RC.
Database is working :) I use Win7 SP1 64bit.
I download program from page
I choose ENU\x64\SQLManagementStudio_x..
I am new to AngularJS and gone through their tutorial and got a feel for it.
I have a backend for my project ready where each of the REST endpoints needs to be authenticated.
What I want to do
a.) I..
I currently work with OpenLayers and have a huge set of data to draw into a vector layer (greater than 100000 vectors).
I'm now trying to put all these vectors into a JavaScript hash map to analyze t..
I have a class that holds an "error" function that will format some text. I want to accept a variable number of arguments and then format them using printf.
Example:
class MyClass
{
public:
voi..
I am having trouble with my jquery script below, this is a basic stripped down version and even it will not work, I have the php file that the jquery script makes a call to, I have it set to encode a..
I was asked to explain the ASP.NET page life cycle in an interview some time back. I did explain it to him, but he was not satisfied with my answer. Could someone explain the life cycle to me please?..
I am working on catching errors in my app, and I am looking into using NSError. I am slightly confused about how to use it, and how to populate it.
Could someone provide an example on how I populate..
I am using rabbitmq and a simple python sample from here
together with docker-compose. My problem is that I need to wait for rabbitmq to be fully started. From what I searched so far, I don't know how..
I have incorporate SpatialIite into a Xcode project which uses a header file from Proj.4, just one header. Both are Xcode projects and have static targets.
I'm trying to migrate from git submodule to..
From git-clone(1) Manual Page
--branch can also take tags and detaches the HEAD at that commit in the resulting repository.
I tried
git clone --branch <tag_name> <repo_url>
But ..
I am trying to set the value of a $scope property using ng-init, and I am unable to access that value in the controller's javascript. What am I doing wrong? Here is a fiddle: http://jsfiddle.net/uce..
I have a button like the following,
<asp:Button ID="pagerLeftButton" runat="server" OnClientClick="disable(this)" onclick="pager_Left_Click" Text="<" />
When I use my button like that, onc..
I am getting this exception:
The communication object,
System.ServiceModel.Channels.ServiceChannel,
cannot be used for communication
because it is in the Faulted state.
The WCF service us..
I have an asp.net GridView:
<asp:TemplateField HeaderText="View Faktor" ShowHeader="False" Visible="True">
<ItemTemplate>
<asp:ImageButton ID="imgBtn1" CssClass="SelectRow"..
I would like to connect to the database specified in the connection string, without specifying it again in GetDatabase.
For example, if I have a connection string like this;
mongodb://localhost/myd..
On my index page, I want the h1 text color to be white and comes with shadow, but I don't want to change the default behavior the h1 on other pages. How can I achieve this?..
I get the following error when inserting data from mysql into postgres.
Do I have to manually remove all null characters from my input data?
Is there a way to get postgres to do this for me?
ERROR: ..
In my TextViewTableViewCell, I have a variable to keep track of a block and a configure method where the block is passed in and assigned.
Here is my TextViewTableViewCell class:
//
// TextViewTable..
I'm trying to draw with the mouse over a HTML5 canvas, but the only way that it seems to work well is if the canvas is in the position 0,0 (upper left corner) if I change the canvas position, for some..
I have the following statement:
printf("name: %s\targs: %s\tvalue %d\tarraysize %d\n", sp->name, sp->args, sp->value, sp->arraysize);
I want to break it up. I tried the following but i..
I'm trying to pass a variable into an include file. My host changed PHP version and now whatever solution I try doesn't work.
I think I've tried every option I could find. I'm sure it's the simplest ..
Using ASP.NET, how can I strip the HTML tags from a given string reliably (i.e. not using regex)? I am looking for something like PHP's strip_tags.
Example:
<ul><li>Hello</li></ul..
Please am trying to implement a filter on my listview. But whenever the text change, the list disappears.Please Help
Here are my codes. The adapter class.
package com.talagbe.schymn;
import java.ut..
what is the quickest/simplest way to drop nan and inf/-inf values from a pandas DataFrame without resetting mode.use_inf_as_null? I'd like to be able to use the subset and how arguments of dropna, exc..
I am having trouble working out how to get a class to change on a nested directive.
This is the outer ng-repeat
<div data-courseoverview data-ng-repeat="course in courses | orderBy:sortOrder | fi..
Question
Using dplyr, how do I select the top and bottom observations/rows of grouped data in one statement?
Data & Example
Given a data frame
df <- data.frame(id=c(1,1,1,2,2,2,3,3,3),
..
As a PHP programmer I'm used to using $_GET to retrieve the HTTP query string... and if I need the whole string, theres loads of ways to do it.
In ASP however, I can't seem to get the query.
Here i..
I can select the first customer node and change its company name with the code below.
But how do I select customer node where ID=2?
XDocument xmldoc = new XDocument(
new XDeclaration("1...
In C++11, is there a way to template a lambda function? Or is it inherently too specific to be templated?
I understand that I can define a classic templated class/functor instead, but the question is..
Instead of making a list of alphabet characters like this:
alpha = ['a', 'b', 'c', 'd'.........'z']
is there any way that we can group it to a range or something? For example, for numbers it can be..
How can you refer to a table number such that you get Table 7 for instance?
Sample data
Table \ref{table:questions} lorem lorem ipsun.
\begin{table}
\label{table:questions}
\begin{tabular}{| p{5cm}..
Given a template where the HTML cannot be modified because of other requirements, how is it possible to display (rearrange) a div above another div when they are not in that order in the HTML? Both di..
On the server, there is a text file. Using JavaScript on the client, I want to be able to read this file and process it. The format of the file on the server cannot be changed.
How can I get the cont..
My table looks like
create table try ( name varchar(8), CREATED_BY varchar(40) not null);
and then I have a trigger to auto populate the CREATED_BY field
create trigger autoPopulateAtInsert BEFOR..
I've been having some trouble with regular expressions.
This is my code
$pattern = "^([0-9]+)$";
if (preg_match($pattern, $input))
echo "yes";
else
echo "nope";
I run it and get:
Warni..
I have a problem where i'm initialising a variable on the scope in a controller. Then it gets changed in another controller when a user logs in. This variable is used to control things such as the nav..
I have a simple class written in Android Studio:
package com.mysite.myapp;
import org.apache.http.client.HttpClient;
public class Whatever {
public void headBangingAgainstTheWallExample () {
..
I wrote a piece of code that will give the user a prompt asking them to press back again if they would like to exit. I currently have my code working to an extent but I know it is written poorly and I..
How do I access a variable that was declared/init in my main.go in a different .go package/file? Keeps telling me that the variable is undefined (I know that global variables are bad but this is just ..
I have a file paylines.txt added inside the folder named TextFiles which resides inside the Resources folder of my iOS project in Xcode.
This is the code I use to access the file:
NSString* filePath..
Is there a method in the System.IO namespace that checks the validity of a filename?
For example, C:\foo\bar would validate and :"~-* would not
Or a little trickier, X:\foo\bar would validate is the..
I want to define two servlets in my Spring web.xml - one for the application html/jsp pages, and one for a web service that will be called by an external application. Here is the web.xml:
<servle..
Hi I am new to MVC and even asp..
I want to create a form in MVC. With the help of some examples I am able to create TextBoxes, but I now I don't understand how to create Select List./
I tried sear..
I often see comments on other Stack Overflow questions about how the use of except: pass is discouraged. Why is this bad? Sometimes I just don't care what the errors are and I want to just continue wi..
I'm messing around with touch events on a touch slider and I keep getting the following error:
Ignored attempt to cancel a touchmove event with cancelable=false,
for example because scrolling i..
Let's say that I have an Javascript array looking as following:
["Element 1","Element 2","Element 3",...]; // with close to a hundred elements.
What approach would be appropriate to chunk (split)..
Is there any way to have multi-line plain-text, constant literals in C++, à la Perl? Maybe some parsing trick with #includeing a file? I can't think of one, but boy, that would be nice. I know it'll ..
Is there a way to make grep output "words" from files that match the search expression?
If I want to find all the instances of, say, "th" in a number of files, I can do:
grep "th" *
but the output..
I'm wondering if/how you can add custom headers to a cURL HTTP request in PHP. I'm trying to emulate how iTunes grabs artwork and it uses these non-standard headers:
X-Apple-Tz: 0
X-Apple-Store-Front..
I found this Demo ,
The demo have a pretty effect, I wonder if any one have way to apply this demos to be easy to use with bootstrap Modal
specially the first one (Fade In & Scale)..
I need a conversion utility/script that will convert a .sql dump file generated on Mac to one readable on Windows. This is a continuation of a problem I had here. The issue seems to be with newline ..
If I have a source.c file with a struct:
struct a {
int i;
struct b {
int j;
}
};
How can this struct be used in another file (i.e. func.c)?
Should I create a new header file,..
I am doing a real estate feed for a portal and it is telling me the max length of a string should be 20,000 bytes (20kb), but I have never run across this before.
How can I measure byte size of a var..
What would be a more simplified description of file descriptors compared to Wikipedia's? Why are they required? Say, take shell processes as an example and how does it apply for it?
Does a process ta..
Could someone explain to me the meaning of @classmethod and @staticmethod in python? I need to know the difference and the meaning.
As far as I understand, @classmethod tells a class that it's a met..
I have been trying several approaches on how to find an object in an array, where ID = var, and if found, remove the object from the array and return the new array of objects.
Data:
[
{"id":"88"..
I'm running an application on localhost, it's been running successfully for at least a year now, but suddenly today wampserver isn't starting up. Whenever I rightclick on the taskbar icon and "start a..
I'm trying to figure out how I can specify a custom end time for an embedded YouTube video. I know that I can customize the start time by adding &start=30, but I haven't seen anything relating to ..
when I use node mysql, an error is appear between 12:00 to 2:00 that the TCP connection is shutdown by the server. This is the full message:
Error: Connection lost: The server closed the connection.
..
I am using CSS attrubutes :
filter: alpha(opacity=90);
opacity: .9;
to make the DIV transparent, but when I add another DIV inside this DIV it makes it transparent also.
I want to make ..
I'm a beginner with Vue.js and I'm trying to create an app that caters my daily tasks and I ran into Vue Components. So below is what I've tried but unfortunately, it gives me this error:
vue.js:1..
In an attempt to fully understand how to solve Java's multiple inheritance problems I have a classic question that I need clarified.
Lets say I have class Animal this has sub classes Bird and Horse a..
Good afternoon,
After updating to the latest version of Xcode at the moment (version 10.0) the project is unable to build because it found some errors regarding some "Command CompileSwift failed with..
I am trying to create mysql tables in Laravel 5. I created a file in /project/database/migrations called users.php:
[...]
public function up()
{
Schema::create('users', function(Blueprint $table)..
I have a form that is using markup from Bootstrap, like the following:
<form class="form-horizontal">
<fieldset>
<legend>Legend text</legend>
<div class="control-..
If I have two lists of type string (or any other type), what is a quick way of joining the two lists?
The order should stay the same. Duplicates should be removed (though every item in both links are..
I need a regex able to match everything but a string starting with a specific pattern (specifically index.php and what follows, like index.php?id=2342343)..
I read the Java tutorials on Sun for JAR files, but I still can't find a solution for my problem. I need to use a class from a jar file called jtwitter.jar, I downloaded the file, and tried executing ..
I'm trying to write a rather trivial program using open gl on linux, but at a compile time it says:
Compile thumb : egl <= cuberenderer.c
In file included from
/path/include/egl.h:36,
..
I have a dialog with EditText for input. When I click the "yes" button on dialog, it will validate the input and then close the dialog. However, if the input is wrong, I want to remain in the same dia..
I am inserting some values into a SQL table using C# in MVC 4. Actually, I want to insert values and return the 'ID' of last inserted record. I use the following code.
public class MemberBasicData
{
..
There are some methods in WebSettings related to zoom:
WebSettings.setSupportZoom
WebSettings.setBuiltInZoomControls
I noticed they work differently on some devices.
For example, on my Galaxy S pi..
I just got tomcat 7.0.27. I have kept the time to start tomcat 45sec. Also it was running fine with older version on tomcat.
but running it I get the following error :
SEVERE: A child container fail..
How to convert an integer number into its binary representation?
I'm using this code:
String input = "8";
String output = Convert.ToInt32(input, 2).ToString();
But it throws an exception:
Coul..
I have found plenty of information out there about this error: 'ERROR: Could not load file or assembly '*.dll' or one of its dependencies. Access is denied.’
But i haven't found answer specific to ..
Qns: Item Description and the treatment date of all treatments for any patients named Jessie Stange (ie GivenName is Jessie & FamilyName is Stange)
What I wrote:
SELECT DISTINCT Description, Da..
I'm trying to create a simple Bash script to check if the website is down and for some reason the "and" operator doesn't work:
#!/usr/bin/env bash
WEBSITE=domain.com
SUBJECT="$WEBSITE DOWN!"
EMAILID..
How do you iterate over each file in a directory with a .bat or .cmd file?
For simplicity please provide an answer that just echoes the filename or file path...
Probably, it is the simplest thing but I couldn't parse a string to Int in angular..
What I am trying to do:
<input type="text" ng-model="num1">
<input type="text" ng-model="num2">
Tota..
For example I have this array:
int a[] = new int[]{3,4,6,2,1};
I need list of all permutations such that if one is like this, {3,2,1,4,6}, others must not be the same. I know that if the length of..
I am building a web app using Bootstrap 4 and running into some weird issues. I want to utilize Bootstrap's table-responsive class to allow horizontal scrolling of the tables on mobile devices. On ..
I'm trying to create a simple Spring 3 application and have the following files. Please tell me the reason for this error
Below is my web.xml
<?xml version="1.0" encoding="UTF-8"?>
<web-app..
I am not sure how to implement a comparable interface into my abstract class. I have the following example code that I am using to try and get my head around it:
public class Animal{
public Stri..
I wonder why one of my projects has VDSERR.h listed under "External Dependencies" and another hasn't and gives me an "undefined symbol" compiler error about a symbol which is defin..
I can't make bootstrap dropdown to work.
Here is my html for nav:
<ul class='nav'>
<li class='active'>Home</li>
<li class='dropdown'>
<a class="dropdown-toggle" da..
I'm trying to update the password for a database user using the command line, and it's not working for me. This is the code I'm using:
mysql> UPDATE user SET password=PASSWORD($w0rdf1sh) WHERE use..
I recently installed rails in fedora 12. I'm new to linux as well. Everything works fine on Windows 7. But I'm facing lot of problems in linux. Help please!
I've installed all the essentials to my kn..
I am performing some tests on a HSQLDB server with a table containing 500 000 entries. The table has no indices. There are 5000 distinct business keys. I need a list of them. Naturally I started with ..
I have a dict and would like to remove all the keys for which there are empty value strings.
metadata = {u'Composite:PreviewImage': u'(Binary data 101973 bytes)',
u'EXIF:CFAPattern2': u''..
I've designed a page, where buttons look good when the browser zoom is at 90%, but by default other users view it at 100/125%+ in their browser which is resulting an overlap in buttons and input forms..
I am using a ListView to display some images and captions associated with those images. I am getting the images from the Internet. Is there a way to lazy load images so while the text displays, the UI..