mardi 14 février 2017

transition effect not working

Vote count: 0

I am trying to get button visibility with animated effect using CSS transition effect on hover but the effect not working.

I am unable to find my mistakes, can anybody help me to solve my issue.

My HTML & CSS Code is as under.

.prodiv3
{
        background-color:#d79e37;
        position:relative;
        z-index:999;
}
.product-box a
{
        text-decoration:none;
}
.prodiv3 h2
{
        padding:0px !important;
        margin: 0px !important;
        color: #fff;
        padding-left:15px !important;
}
.prodiv3 p
{
        color: #000000;
        padding-left:15px !important;
}
.link-icon
{
        position:relative; 
        bottom:120px; 
        left:10px;
        visibility:hidden;
        width:60px; 
        height:60px; 
        background:url(../images/link-icon.png) no-repeat center center #ff411c; 
        //display:block; 
        border-radius:100%;
}
.product-box a:hover .link-icon
{
        visibility:visible;
        -moz-transition: all 1s ease-in !important;
        -webkit-transition: all 1s ease-in !important;
        -o-transition: all 1s ease-in !important;
        transition: all 1s ease-in !important;
}
asked 25 secs ago

Let's block ads! (Why?)



transition effect not working

Checking mail id of distribution list

Vote count: 0

I am developing VBA automation which will forward specific mail to given distribution list which have been saved in one specific worksheet and also i have to check all mail id's of distro if it is correct or not. So Please help to develop a code which will check mail id if they correct or not..

asked 31 secs ago

Let's block ads! (Why?)



Checking mail id of distribution list

Python code required

Vote count: 0

I have a text file containing unstructured data which has record locators and passenger names..I want to fetch all record locators with passenger names. If a record doesn't have passenger name don't fetch it in result. Suppose my file has: Record 1 Record 2 Record 3 John Record 4 Smith

So output file should have Record 3 John Record 4 Smith As output

Please post a python code for the same.

asked 33 secs ago

Let's block ads! (Why?)



Python code required

how to get device active user with specific Time-stamp

Vote count: -1

How to get Active User in Android Multi-User Support Devices with Sending specific Time-Stamp?

asked 42 secs ago

Let's block ads! (Why?)



how to get device active user with specific Time-stamp

T-Sql Find the Employee Count as average by the number of months in the year

Vote count: 0

I have table called "Employee"

Employee table has below columns

Id (identity)
EmploymentStartDate (datetime),
EmploymentEndDate (nullable datetime),

My query:

DECLARE @FromYear int = 2010, @ToYear int = 2017;

WITH YEARS AS 
(
    SELECT @FromYear As TheYear
    UNION ALL
    SELECT TheYear + 1
    FROM YEARS
    WHERE TheYear < @ToYear
)

SELECT
    Y.TheYear,
    SUM
    (
        CASE WHEN
            YEAR(EmploymentStartDate) <= Y.TheYear
            AND (EmploymentEndDate IS NULL OR YEAR(EmploymentEndDate) >= Y.TheYear)
        THEN 1
        ELSE 0
        END
    ) WorkingEmployeeCount,
    SUM
    (
        CASE WHEN
            YEAR(EmploymentStartDate) = Y.TheYear
        THEN 1
        ELSE 0
        END
    ) StartedEmployeeCount,
    SUM
    (
        CASE WHEN
            YEAR(EmploymentEndDate) = Y.TheYear
        THEN 1
        ELSE 0
        END
    ) SeperatedEmployeeCount
FROM
    YEARS Y
    CROSS JOIN
    Employees E
GROUP BY
    Y.TheYear

If ı run above query i get below result

TheYear - WorkingEmployeeCount - StartedEmployeeCount - SeperatedEmployeeCount

2010    -  1                   -  1                   -   0
2011    -  2                   -  1                   -   0
2012    -  2                   -  0                   -   0
2013    -  2                   -  0                   -   0
2014    -  2                   -  0                   -   0
2015    -  4                   -  2                   -   1
2016    -  3                   -  0                   -   0
2017    -  6                   -  3                   -   2

Question:

I need to use below formula.First i want to find every year's months count than AVG of EmployeeCount per year.

EmployeeCount / MonthsCountPerYear than get AVG

If i try below query it is not working for me (I can not create a solution)

(AVG(EmployeeCount / (CASE WHEN TheYear = DATE(GETUTCDATE) THAN 2 ELSE 12 END))) AS AvgEmployeeCount

What i want should be as below

TheYear - WorkingEmployeeCount - StartedEmployeeCount -SeperatedEmployeeCount - AvgEmployeeCount

2010    -  1                   -  1                   -   0                      - 1,30
2011    -  2                   -  1                   -   0                      - 1,20
2012    -  2                   -  0                   -   0                      - 1,00
2013    -  2                   -  0                   -   0                      - 3,50
2014    -  2                   -  0                   -   0                      - 5,33
2015    -  4                   -  2                   -   1                      - 7-33
2016    -  3                   -  0                   -   0                      - 9-34
2017    -  6                   -  3                   -   2                      - 1,15

How can i find employee count avg for every year according to months in a year.Any help will be appreciated.Thank you

asked 30 secs ago

Let's block ads! (Why?)



T-Sql Find the Employee Count as average by the number of months in the year

Swagger editor doesn't offer relevant code completion

Vote count: 0

When I use swagger editor (online or local) sometimes it offers code completion of the relevant level and often it starts offering code completion of the root level: definitions, swagger, info, paths, etc. while my cursor is not at the root level, for example when I'm entering properties. There are also no indications that tell that there is something wrong with the document. I cannot see the pattern to find out when this happens, it just happens and it makes the editor very difficult to use as I have to type almost everything.

I wish I could provide more details but for now this problem happens randomly. Does anyone know what can cause this behavior and how to fix it?

asked 45 secs ago

Let's block ads! (Why?)



Swagger editor doesn't offer relevant code completion

Can we deconstruct arbitrary type constructors?

Vote count: 0

In Haskell, or any other programming language supporting pattern matching, can we achieve the following:

Given a type constructor e.g. Left :: a -> Either a b I can extract its argument with

let f (Left x) = [x]

Is there any way to achieve the same thing for any type constructor, something like an operator (*) to lift Left x to Apply (λa.Left a) [x] or BinTree x y to Apply (λa,b.BinTree a b) [x,y], so we could do

let extract x = case *x of Apply _ xs -> xs

asked 33 secs ago

Let's block ads! (Why?)



Can we deconstruct arbitrary type constructors?

how do I rename tooltip of echart download icon

Vote count: 0

I am using echart

enter image description here

How do I rename download button tooltip in corner of top-right(written in Chinese language)

I can't find in echart option.

asked 33 secs ago

Let's block ads! (Why?)



how do I rename tooltip of echart download icon

How do i append another list within list comprehension

Vote count: 0

I am trying to find out unique elements and avoid duplicates , between the lists (using list comprehension)

`a = [10 , 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89,9]`
`b = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13]`

dup_list = []

This works , but with duplicates

`final_list = [uniq for uniq in a if a not in dup_list if uniq in b ]`

when i try to append the my dup_list in the last line of the comprehension statement it says invalid syntax i.e this doesn't work. "final_list = [uniq for uniq in a if a not in dup_list if uniq in b dup_list.append(uniq) " I am a newbie in python so apologize for any missed out basic facts .

asked 6 secs ago

Let's block ads! (Why?)



How do i append another list within list comprehension

ORACLE-Why WHERE clause is not working on UNION?

Vote count: 0

I am working on oracle 11g.But when I add WHERE clause in UNION of two table it shows error:

ORA-00904: "T8"."ENTRY_DATE": invalid identifier

This is my query:

SELECT * FROM
(
    SELECT T1.OUTLET_ID,T1.STATUS,T1.ENTRY_DATE  FROM T_ORDER_DETAIL T1 
    UNION 
    SELECT T8.OUTLET_ID,T8.REASON,T8.ENTRY_DATE FROM  T_NON_PRODUCTIVE_SALES T8 
) 
WHERE T1.OUTLET_ID = T8.OUTLET_ID AND T1.ENTRY_DATE = T8.ENTRY_DATE

Where's the problem?

asked 19 secs ago

Let's block ads! (Why?)



ORACLE-Why WHERE clause is not working on UNION?

create threaded class functions with arguments inside class

Vote count: 0

I have an object of class AI, which has a private non static void function which has a lot of arguments: minmax(double& val,double alpha, double beta, unsigned short depth, board* thisTurn); because this is a very time intensive function I want to use a number of threads to run it concurrently, therefor I must create a thread with this function inside another function inside the AI class;

According toThis question to make threads inside member functions containing non static member functions wiht no arguments of said class, one must call:

std::thread t(&myclass::myfunc,this);

And according to this tutorial threads of fucntions with multiple arguments can be created as such:

std::thread t(foo,4,5) 

where the function 'foo' has 2 integer arguments

However I desire to mix these to things, to call a function which has arguments, which is also a non static member function, from inside the class that it is a member of, and i am not sure how to mix these to things.

I have off course tried (remember that it is inside a function inside the AI class):

std::thread t(&AI::minmax,val,alpha,beta,depth,thisTurn,,this);

and

std::thread t(&AI::minmax,this,val,alpha,beta,depth,thisTurn,this);

But both cases fails with a compile error like this:

error: no matching constructor for initialization of 'std::thread'
candidate constructor template not viable: requires single argument '__f', but
  7 arguments were provided

My question is therefor, if or if not, it is even possiple to -- from inside a member function of a class -- call a non static member function which has several arguments as a thread, and if this is the case, how it is done.

asked 11 secs ago

Let's block ads! (Why?)



create threaded class functions with arguments inside class

Devexpress:aspxtextbox text validation

Parse mutually exclusive input arguments with MATLAB's input parser

Vote count: 0

I have a function that has at least two required input arguments. Depending on the value of the second argument, there might be a third required input argument. I am wondering what is the best way to code a robust function that incorporates these requirements using MATLAB's input parser?

The function may look like this:

function vout = test(ReqInpArg1, ReqInpArg2, varargin)

ReqInpArg2 may hold the following string content:

  • 'cash'
  • 'absHurdleRate'
  • 'none'

If the user chooses cash, than another input argument numCashTicker needs to be defined as part of varargin, e.g. 'numCashTicker', 4. If absHurdleRatehas been choosen, a different input parameter has to be defined, e.g. 'hurdleRate', 0.2. If, on the other hand, none has been chosen, none of these input parameter must be defined. As a matter of fact, numCashTicker and hurdleRate are mutually exclusive, i.e. they must not be defined at the same time. In addition, if the user didn't chose none, he must define one of the other varargin input arguments.

What is best practice / the best strategy in order to implement these requirements?

asked 14 secs ago

Let's block ads! (Why?)



Parse mutually exclusive input arguments with MATLAB's input parser

DCM4CHE, Network operations,Handling a C-Move call

lundi 13 février 2017

Which code can swallow interruptedException?

Vote count: 0

I read concurency in practice. Now I want to understand how to handle InterrruptedException

Advices from book:

- Propagate the exception (possibly after some task-specific cleanup), making your method an interruptible blocking method, too; or
- Restore the interruption status so that code higher up on the call stack can deal with it.
- Only code that implements a thread's interruption policy may swallow an interruption request. General-purpose task and library code should never swallow interruption requests.

First two statements are clear for me but I don't understand third. Can you clarify this? Providing example will be prefered.

asked 18 secs ago

Let's block ads! (Why?)



Which code can swallow interruptedException?

How to prevent react router from re-rendering a previously rendered page?

In firebase web i want to retrive multiple data in real-time

Vote count: 0

In firebase web i want to retrive multiple data in real-time. my code is

$(document).ready(function(){
   var rootRef=firebase.database().ref().child("users");
   rootRef.on("child_added",snap=>{
var name=snap.child("Name").val();
var email=snap.child("Email").val();

$("#table_body").append("
asked 35 secs ago

Let's block ads! (Why?)



In firebase web i want to retrive multiple data in real-time

S3 and Cloudfront throwing error on page reload

Vote count: 0

Somehow when I'm using the website URL (I've setup Amazon ACM as well), it works fine but when I try to refresh the page, it throws an error such as:

enter image description here

I'm using a reactJS SPA website to host the website on Cloudfront through S3. I've made the necessary changes on S3 for the permissions:

Bucket Policy:

{
    "Version": "2012-10-17",
    "Id": "Policy1485855809339",
    "Statement": [
        {
            "Sid": "Stmt1485855807310",
            "Effect": "Allow",
            "Principal": "*",
            "Action": "s3:GetObject",
            "Resource": "arn:aws:s3:::mydomain.com/*"
        }
    ]
}

I've created two buckets: mydomain.com and www.mydomain.com I've redirected all requests from www.mydomain.com to mydomain.com with the help of S3 redirect.

I've now created a Cloudfront distribution with the help of S3 as the origin and the following configuration:

enter image description here

Please let me know if more information is needed

asked 35 secs ago

Let's block ads! (Why?)



S3 and Cloudfront throwing error on page reload

Convert base64 png to jpeg image in Nodejs

Vote count: 0

I am using FabricJS module in Nodejs. There is a Canvas I am trying to export as jpeg but it wont(giving me a hard time). All I am getting is base64 png data.

Data that starts like

data:image/png;base64, iVBORw0KGgoAAAANSUhEUgAAAfQAAAH0CAYAAADL1t.....

Is there anyway in nodejs that I can convert this image to jpeg? I googled a lot but couldn get a solution

asked 32 secs ago

Let's block ads! (Why?)



Convert base64 png to jpeg image in Nodejs

Aspose formula detection

Vote count: 0

I am trying to create placeholders for fields in excel using aspose.cells for java. I know about smartmarkers. The user uses <> to specify placeholders and I would process that to then change it to the '&=' notation. How would I do this for formulae. If I have does aspose have functions to detect if given key is a formula?

asked 33 secs ago

Let's block ads! (Why?)



Aspose formula detection

Create JQuery Light Box With Slide

Vote count: 0

Hello I Work On Create Simple JQuery LightBox With Slide, So What is I Need That When I Click on Any Image, I Want This Image To Added to img Tag That it's Inside Div With Class .lightbox, And When Click On .next The Code Will Get The Next Image of The Current Image:


Note: Please Run Code Snippet In Full screen
asked 20 secs ago

Let's block ads! (Why?)



Create JQuery Light Box With Slide

How to drop the row?

Vote count: 0

I'm handling my data now.

I got a problems when I using pandas

Here is the code.

import pandas as pd
import numpy as np
import os

join_file2 = r'D:\raw data\서울시 공공데이터\5.16년7월분\17.상권-추정매출\tbsm_trdar_selng.txt\tbsm_trdar_selng_utf8.txt'
os.chdir(os.path.dirname(join_file2))
join_data2 = pd.read_csv(os.path.basename(join_file2),sep='|',
                header=None ,
                usecols=[0,1,2,3,4,11],
                names=['STDR_YM_CD', 'TRDAR_CD', 'TRDAR_CD_NM', 'SVC_INDUTY_CD','SVC_INDUTY_CD_NM','THSMON_SELNG_AMT'],
                dtype = { '0' : int},
                encoding='utf-8' )

join_data2_d = join_data2[(join_data2.SVC_INDUTY_CD != 'CS000000') | (join_data2.SVC_INDUTY_CD != 'CS100000') | (join_data2.SVC_INDUTY_CD != 'CS200000')| (join_data2.SVC_INDUTY_CD != 'CS300000') ]

When I print join_data2.head(), I got this data enter image description here

and print join_data2_d, I got this which doesn't drop rows. enter image description here

How can I fix it??

asked 21 secs ago

Let's block ads! (Why?)



How to drop the row?

Which is called first static constructor or private constructor

Vote count: 0

I was reading a tutorial for implementing Singleton and the code is

public class Singleton
    {
        private static readonly Singleton instance = new Singleton();

        static Singleton()
        {
            Console.WriteLine("Static");
        }
        private Singleton()
        {
            Console.WriteLine("Private");
        }

        public static Singleton Instance { get { return instance; } }

        public void DoSomething() {
            //this must be thread safe
        }
    }

When I write Singleton.Instance, the output is Private Static

I was expecting it to be Static Private

Reason being that when I read a MSDN tutorial "http://ift.tt/1W6pY2n"

I saw that public constructor was called before the static constructor.

Why is there a difference?

asked 32 secs ago

Let's block ads! (Why?)



Which is called first static constructor or private constructor

email confirmation link should expire after particular time period in servlets?

Vote count: 0

Little bit confused on how to implement the expiry timeout to email confirmation link..

As i'm fresher can you please help me in what way can we implement?

When i browsed came through the concept listeners,sessions

what is the best approach to implement?

asked 50 secs ago

Let's block ads! (Why?)



email confirmation link should expire after particular time period in servlets?

Twilio "0.11.1" getmessages with "anchor" parameter not working

Vote count: 0

We are migrating from javascript ipmessaging api version "0.1.5" to "0.11.1". We have been using "channel.getMessagesPaged" which is replaced by "channel.getMessages" in new javascript api.

Problem : The method call with passing parameter "anchor" has started failing now.

We tried to refer the following migration guide: http://ift.tt/2kNDR9Q The above link doesn't mention a changes in parameters for getMessages from getMessagesPaged.

Earlier, we have been passing the earliest message sid as the "anchor" value and keeping it same. We also followed the comments in un-minified(debug) version. (ref: releases/0.11.1/twilio-chat.js)

For your reference: * Returns last messages from channel * @param {String} [anchor] Most early message id which is already known, or 'end' by default

Every time, we are trying to call method getMessages() with anchor value, we are receiving following exception: "Invalid 'From' query parameter value. Expected an integer" Full exception for reference: http://ift.tt/2l2DhUi

Please look at the screen-cast above and help us know if we are missing something here.

It would be great if you provide us some reference for this method with anchor value.

asked 11 secs ago

Let's block ads! (Why?)



Twilio "0.11.1" getmessages with "anchor" parameter not working

How to show the "Design" category in a custom CollectionEditor when overriding CreateInstance()?

Vote count: 0

If I comment out CreateInstance, then the "Design" is showing, but if I override it it is not showing. How can I make it shown?

No override:

enter image description here

Override:

enter image description here

Code:

public class MyEditor : CollectionEditor
{
    public MyEditor(Type type) : base(type)
    {
    }

    protected override Type[] CreateNewItemTypes()
    {
        return new[]
        {
            typeof(TabPage) //TabPage is subclass of "Panel".
        };
    }
    protected override object CreateInstance(Type itemType)
    {
        var item = new TabPage(true);
        return item;
    }
}

Also, the title of the collection editor window is "Object Collection Editor", instead of my collection's name such as "TabPage Collection Editor". Not a big problem, but I would like to fix this, if possible.

asked 15 secs ago

Let's block ads! (Why?)



How to show the "Design" category in a custom CollectionEditor when overriding CreateInstance()?

Spring MVC + STS + Maven: WebSecurity cannot be resolved. It is indirectly referenced from required .class files

How to do a three column grid with bourbon neat?

Vote count: 0

I'm trying to create a three column grid, and have the columns evenly distributed across the row.

My markup is simple:

My scss is also pretty straight-forward.

 .row {
    @include outer-container ;
  }
 .service {   
    @include span-columns(4) ;
}

However the result is a mess:

enter image description here

What do I need to do to get a three-column grid?

asked 43 secs ago

Let's block ads! (Why?)



How to do a three column grid with bourbon neat?

How to differentiate value with existing value via hook in SugarCRM?

Vote count: 0

I am attempting to use an after_save logic hook to if i am update assignee in Leads then same assignee should be assigned to its related Notes. Below is the code I am using. I am currently on 6.5 enterprise. Does anyone have an idea of how i can compare both values?

In modules/Leads/logic_hook.php

$hook_array['after_save'] = Array();
$hook_array['after_save'][] = Array(1, 'Leads edited', 'custom/modules/Leads/ExtraLogic.php', 'ExtraLogic', 'saveAssigneeToNotes');

In custom/modules/Leads/ExtraLogic.php

    //check if a fields value has changed
    if ($assigned_user_id != $bean->assigned_user_id)
    {
        // execute logic
    } else {
        // Same value
    }

Thanks.

asked 29 secs ago

Let's block ads! (Why?)



How to differentiate value with existing value via hook in SugarCRM?

How to call the action method from angular service?

Vote count: 0

I'm trying to call the mvc controller in angular service.js file.

     public class HomeController : Controller
    {
        public ActionResult Index()
        {
            return View();
        }
        [HttpGet]
        public JsonResult GetAll()
        {
            using (EmployeeEntities datacontext = new EmployeeEntities())
            {
                var employeelist = datacontext.Employees.ToList();
                return Json(employeelist, JsonRequestBehavior.AllowGet);
            }
        }

} }

Angular controller:

app.controller("mycontroller", function ($scope, myservice) {
debugger;
GetAllEmployee();
$scope.divEmployee = false;

function GetAllEmployee() {
    debugger;

    var getData = myservice.getAllEmployees();
    getData.then(function (emp) {
        $scope.employees = emp.data;
    }),
    function(){
        alert('Error in getting data');
    }
}

}); Angular service.js

pp.service("myservice", ["$http", function ($http) {
this.getAllEmployees = function () {
    debugger;
    var response = $http({
        url: "/Home/GetAll",
        method: "GET",

        datatype:'JSON'
    })
        return response;
    });

So when i trying run call the Url, the "Home/GetAll" is not found error is coming. So how to call the url in service.

asked 49 secs ago

Let's block ads! (Why?)



How to call the action method from angular service?

what is the best way to update fragment view from activity

Vote count: 0

I have one fragment and that have some view element like textview buttons.

Now My problem is I have some service running background and it is checking data from server(Mysql) when these are some data it tells to Mainactivity.

Now on the basis of result I have to update fragment texeviews buttos.

asked 12 secs ago

Let's block ads! (Why?)



what is the best way to update fragment view from activity

Is there any replacement for vmax in IE?

Vote count: 0

Im using vmax for height and width.It works perfectly in firefox and chrome.It is responsive too. But in IE it is not working.Is there any replacement for vmax which i can use in IE too.It should be responsive.

asked 28 secs ago

Let's block ads! (Why?)



Is there any replacement for vmax in IE?

saving an object of LinkedList as an interface object

Cache - Java algorithm

Bash - Check if a file exists as part of a longer expression

Vote count: 0

In a bash script, I need to prompt the user for an email address, but only if git user.email is not set or there is no ssh key. I have very little experience with bash, so I've been coming to stackoverflow again and again for this project.

Based on this stackoverflow answer, I came up with this:

#if [[ ! -f "$HOME/.ssh/id_rsa" ]]; then
    echo "No File Found"
else
    echo "File Found"
fi

This has the expected behavior: If id_rsa exists, it says File Found; If I remove id_rsa, it says No File Found. However, I cannot get this to work as part of a longer expression. Here's what I have so far:

md_email=
echo `git config --get user.email`
if [[ "$md_email" = "" && "`git config --get user.email`" = "" || ! -f "$HOME/.ssh/id_rsa" ]]; then
    echo "No File Found"
else
    echo "File Found"
fi

asked 53 secs ago

Let's block ads! (Why?)



Bash - Check if a file exists as part of a longer expression

qtranslatex and yoast seo keywords

Vote count: 0

Having some trouble with the QTranslate and Yoast SEO integration plugin. http://ift.tt/2lJooW6

Apparently they are not going to update it and there is an issue with the Focus Keywords not working in each page. It is using the vesion 1.1.1 Attempting to use the version in the Github which is version 1.2 gave some Javascript errors.

Are there alternatives or other plugins to making it work?

asked 1 min ago

Let's block ads! (Why?)



qtranslatex and yoast seo keywords

How to close Inline Response

Vote count: 0

I want to close current Inline Response to do some behaviors
I have try this function: OutlookApp.ActiveExplorer().ClearSelection() but it cannot work under Conversation View and raise exception: The method you are invoking is invalid for a conversation view

So, what is right way to close Inline Response ?

asked 46 secs ago

Let's block ads! (Why?)



How to close Inline Response

how to use ggplot in R to draw a single graphic with two lines and one area with duo y axis?

Vote count: 0

I'd like to draw a combo graph where

  1. the x-axis is the hour of the day
  2. Two lines represent the average value of each hour
  3. A filled area represents the volume of the data points of each hour
  4. Two y-axis as the units of the avg. value and the count are different

here's some fake data:

 data = data.frame(x_hour=c(8,9,10,11,12,13,14,15), 
 y_linea=c(3,7,6,8,14,16,18,12),
 y_lineb=c(3,5,12,7,4,6,19,9),
 y_count=c(50,70,120,60,85,48,36,70))

and here's the ideal picture I wanted to draw

My thought was to draw two separate graphs and combine them together, but I cannot figure out how to create the graph with the area or how to combine those two graphs. I would appreciate it a lot if you could share your ideas with me, thank you!

asked 47 secs ago

Let's block ads! (Why?)



how to use ggplot in R to draw a single graphic with two lines and one area with duo y axis?

PHP: How to push an array into a 2D array?

Vote count: 0

In Perl, we could do like this:

foreach (....) {
   ..........
   ..........
   ..........
   my @tmp = ($x1,$x2,$y1,$y2);
   push(@target_array,\@tmp);  # Don't know how to translate this line to PHP, failed after several try with array_push
}

How to translate this into PHP?

asked 42 secs ago

Let's block ads! (Why?)



PHP: How to push an array into a 2D array?

How to scheduling multiple task through cron expression using Springboot?

Vote count: 0

I want to schedules multiple task using @schedule annotation using cron expression. I have three job which require to execute at fixed time. For example,Job-1 has been schedule every day at 11:PM, Job-2 has been scheduled every day 7AM-9PM in 1 hour interval and Job-3 has been schedule in every 1 hour. All the 3 schedule tasks are part of the same application.

I have tried the same but all three scheduling is not happening. My application is SpringBoot application.I am not new scheduling.Kindly help me out

asked 1 min ago

Let's block ads! (Why?)



How to scheduling multiple task through cron expression using Springboot?

OpenShift NextGen account deleted

Vote count: 0

My OpenShift NextGen account was deleted after 30 days and I lost my code. They want all users to move to NextGen before August but can't let us use the NextGen platform for more than 30 days. I am confused. If I want to work on a project which will last beyond this August, should I use NextGen or the original version?

asked 25 secs ago

Let's block ads! (Why?)



OpenShift NextGen account deleted

ckeditor error code editor-destroy-iframe in angularjs

Vote count: 0

This error is reported after I have called the destroy method of ckeditor,this is Official documentation anybody help me?

asked 30 secs ago

Let's block ads! (Why?)



ckeditor error code editor-destroy-iframe in angularjs

I want to rar multiple sub-folders in a main folder in windows not manually

Vote count: 0

I have a folder that contain so many sub folders. How can I do this ? If I have to write a batch file, help me with this. Thanks you.

asked 1 min ago

Let's block ads! (Why?)



I want to rar multiple sub-folders in a main folder in windows not manually

Google Calendar Events API for Insert throwing 400

Vote count: 0

I have checked out other posts related to this issue and they are not the same: I am using "response", I copied the date/time from the google api website so the format is correct, and I've played around with the headers. Any other ideas for why this is not working?

I'm getting the following error:

Error: failed [400] {  "error": {   "errors": [    {     "domain": "global",     "reason": "required",     "message": "Missing end time."    }   ],   "code": 400,   "message": "Missing end time."  } } [object Object]

My code below broken down into steps: the url i'm going to POST, the user access token, the options for the inserted calendar event including headers and the event with start, end and event summary, and the actual http post and callback function:

calendarSchedule() {
    if(Meteor.user() && moment(Meteor.user().services.google.expiresAt) > moment()._d) {
      var url = "http://ift.tt/1nyM66n";
      var userAccessToken = Meteor.user().services.google.accessToken;

      var options = {
        headers : {
          'Content-Type': 'application/json',
          'Authorization': 'Bearer ' + userAccessToken,
          'X-JavaScript-User-Agent': "Google APIs Explorer",
        },
        calendarId: 'primary',
        resource : {
          start: { dateTime: "2016-05-03T18:03:58+02:00" },
          end: { dateTime: "2016-05-03T18:03:58+02:00" },
          summary: "testSummar",
        }
      };

      HTTP.post(url, options,
        function(error,result) {
          console.log("posted to calendar? "+ error+ result);
        });
    }
  }

asked 1 min ago

Let's block ads! (Why?)



Google Calendar Events API for Insert throwing 400

Turn ActiveMQ JDBC Master-Slave off by adding config useDatabaseLock="false"

Referencing core data attribute from declared variable

Vote count: 0

I'm following a swift development course for beginners and am trying to make a very simple app that creates new tasks with an entered text once a button is pressed, but I am encountering a few errors that I can't seem to understand.

The errors happen in my ViewController and the editor tells me my Core Data Entity does not possess an attribute named "corename" while it very well does.

Here is a screenshot of the errors : 3 errors

And here is my code :

import UIKit

class ViewController: UIViewController, UITableViewDataSource, UITableViewDelegate {


@IBOutlet weak var tableView: UITableView!

var tasks : [Taskentity] = []
override func viewDidLoad() {
    super.viewDidLoad()
    tableView.dataSource = self
    tableView.delegate = self
    // Do any additional setup after loading the view, typically from a nib.
}

override func viewWillAppear(_ animated: Bool) {
    //Get the data from Core data
    getData()
    //Reload the table view
    tableView.reloadData()
}
func numberOfSections(in tableView: UITableView) -> Int {
    return tasks.count
}

func tableView(_ tableView: UITableView, cellForRowAt indexPath : IndexPath) -> UITableViewCell {
    let cell = UITableViewCell()

    let task = tasks[indexPath.row]

    if (task.isImportant == true){
         cell.textLabel?.text = "😅  \(tasks.corename!)"

    } else {
         cell.textLabel?.text = tasks.corename!
    }

    return cell
}

func getData() {
    let context = (UIApplication.shared.delegate as! AppDelegate).persistentContainer.viewContext

    do {
    tasks = try context.fetch(Taskentity.fetchRequest())
    } catch {
        print("Fetching Data")
    }
}
}

asked 1 min ago

Let's block ads! (Why?)



Referencing core data attribute from declared variable

Unable to deploy CVXOPT with Python Buildpack on Cloud Foundry

Vote count: 0

I am unable to deploy CVXOPT package into Linux environment. I am on Python 3.6.0. and using standard python buildpacks (http://ift.tt/2lJjo3F) which I am trying to deploy on Clound Foundry for my IBM Bluemix app.

Are there any special buildpacks for this or CVXOPT cannot be working on Cloud Foundry? Thank you a lot!

This is the error output when deploying:

2/14/2017 2:48:06 AM    OUT STG Running setup.py install for cvxopt: started

2/14/2017 2:48:20 AM    OUT STG Running setup.py install for cvxopt: finished with status 'error'

2/14/2017 2:48:20 AM    OUT STG Complete output from command /app/.heroku/python/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-pgi7qybb/cvxopt/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-6vk81aol-record/install-record.txt --single-version-externally-managed --compile:

2/14/2017 2:48:20 AM    OUT STG running install

2/14/2017 2:48:20 AM    OUT STG running build

2/14/2017 2:48:20 AM    OUT STG creating build

2/14/2017 2:48:20 AM    OUT STG creating build/lib.linux-x86_64-3.5/cvxopt

2/14/2017 2:48:20 AM    OUT STG copying src/python/cvxprog.py -> build/lib.linux-x86_64-3.5/cvxopt

2/14/2017 2:48:20 AM    OUT STG copying src/python/__init__.py -> build/lib.linux-x86_64-3.5/cvxopt

2/14/2017 2:48:20 AM    OUT STG copying src/python/_version.py -> build/lib.linux-x86_64-3.5/cvxopt

2/14/2017 2:48:20 AM    OUT STG copying src/python/printing.py -> build/lib.linux-x86_64-3.5/cvxopt

2/14/2017 2:48:20 AM    OUT STG UPDATING build/lib.linux-x86_64-3.5/cvxopt/_version.py

2/14/2017 2:48:20 AM    OUT STG set build/lib.linux-x86_64-3.5/cvxopt/_version.py to '1.1.9'

2/14/2017 2:48:20 AM    OUT STG running build_ext

2/14/2017 2:48:20 AM    OUT STG building 'base' extension

2/14/2017 2:48:20 AM    OUT STG creating build/temp.linux-x86_64-3.5/src

2/14/2017 2:48:20 AM    OUT STG gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -I/app/.heroku/python/include/python3.5m -c src/C/dense.c -o build/temp.linux-x86_64-3.5/src/C/dense.o

2/14/2017 2:48:20 AM    OUT STG gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -I/app/.heroku/python/include/python3.5m -c src/C/sparse.c -o build/temp.linux-x86_64-3.5/src/C/sparse.o

2/14/2017 2:48:20 AM    OUT STG src/C/sparse.c: In function ‘sparse_concat’:

2/14/2017 2:48:20 AM    OUT STG src/C/sparse.c:368:30: warning: variable ‘blk_ncols’ set but not used [-Wunused-but-set-variable]

2/14/2017 2:48:20 AM    OUT STG int_t blk_nrows = 0, blk_ncols = 0;

2/14/2017 2:48:20 AM    OUT STG gcc -pthread -shared build/temp.linux-x86_64-3.5/src/C/base.o build/temp.linux-x86_64-3.5/src/C/dense.o build/temp.linux-x86_64-3.5/src/C/sparse.o -L/usr/lib -L/app/.heroku/vendor/lib -lm -llapack -lblas -lpython3.5m -o build/lib.linux-x86_64-3.5/cvxopt/base.cpython-35m-x86_64-linux-gnu.so

2/14/2017 2:48:20 AM    OUT STG gcc -pthread -shared build/temp.linux-x86_64-3.5/src/C/blas.o -L/usr/lib -L/app/.heroku/vendor/lib -lblas -lpython3.5m -o build/lib.linux-x86_64-3.5/cvxopt/blas.cpython-35m-x86_64-linux-gnu.so

2/14/2017 2:48:20 AM    OUT STG gcc -pthread -shared build/temp.linux-x86_64-3.5/src/C/lapack.o -L/usr/lib -L/app/.heroku/vendor/lib -llapack -lblas -lpython3.5m -o build/lib.linux-x86_64-3.5/cvxopt/lapack.cpython-35m-x86_64-linux-gnu.so

2/14/2017 2:48:20 AM    OUT STG src/C/umfpack.c:23:21: fatal error: umfpack.h: No such file or directory

2/14/2017 2:48:20 AM    OUT STG #include "umfpack.h"

2/14/2017 2:48:20 AM    OUT STG ^

2/14/2017 2:48:20 AM    OUT STG 

2/14/2017 2:48:20 AM    OUT STG ----------------------------------------

2/14/2017 2:48:21 AM    ERR STG Command "/app/.heroku/python/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-pgi7qybb/cvxopt/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-6vk81aol-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-pgi7qybb/cvxopt/

2/14/2017 2:48:21 AM    ERR STG Failed to compile droplet

2/14/2017 2:48:21 AM    ERR STG Staging failed: Exited with status 223

2/14/2017 2:48:21 AM    OUT STG Destroying container

asked 28 secs ago

Let's block ads! (Why?)



Unable to deploy CVXOPT with Python Buildpack on Cloud Foundry

Remove RecyclerView Item from Dialog not updating

Vote count: 0

I have a simple RecyclerView for displaying items. Currently, from the RecyclerView.Adapter, I can delete items successfully using the following.

private void removeItem(int pos) {    
    filteredDataSet.remove(pos);
    notifyItemRemoved(pos);
    notifyItemRangeChanged(pos, getItemCount());
}

I call it from the onItemClick() function in the ViewHolder.The animations work, the view is updated, everything works. Pretty standard RecyclerView.

However, what I'd like to do is have the user verify the item deletion via a Dialog. Here's the basic setup for the Dialog (leaving out unnecessary code):

...

AlertDialog.Builder builder = new AlertDialog.Builder(v.getContext());
builder.setTitle("Delete this item?");
builder.setView(layout);

final int itemPos = pos;

builder.setPositiveButton("Yes", new DialogInterface.OnClickListener() {
    public void onClick(DialogInterface dialog, int id) {
        removeItem(itemPos);
    }
}); 

...

So, I'm just moving the method call into the onClickListener of the Dialog.

The problem I'm having is that when the RecyclerView animates away the removed item, it animates it back in the exact same position, and the list stays the same. Like it's still there.

But, if I scroll down I get a out of bounds error:

java.lang.IndexOutOfBoundsException: Inconsistency detected. Invalid item position

Which means it's not actually there, and when go back and come into the View again, it's gone. So, it seems like it's cached and not updating the adapter or dataset. I read that it needs called on the main thread, so I modified my method to this:

private void removeItem(int pos) {
final int itemPos = pos;

Handler handler = new Handler(Looper.getMainLooper());
Runnable runnable = new Runnable() {
    @Override
    public void run() {
        filteredDataSet.remove(itemPos);
        notifyItemRemoved(itemPos);
        notifyItemRangeChanged(itemPos, getItemCount());
    }
};

It's still not working, and I'm at a loss. I suspect it's a thread issue, but not sure where to turn from here.

asked 57 secs ago

Let's block ads! (Why?)



Remove RecyclerView Item from Dialog not updating

cfgmgr32.h in Universal Windows

Vote count: 0

I need to use SetupDiGetClassDevs function to communicate with HID device. But it's not possible in Universal Windows platform as SetupAPI.h is not supported.

So I found in MSDN about Porting code from SetupApi to CfgMgr32 which basically using CM_Get_Device_xx functions in CfgMgr32.h

However, in CfgMgr32.h, it defines #if WINAPI_FAMILY_PARTITION (WINAPI_PARTITION_DESKTOP | WINAPI_PARTITION_SYSTEM), and Universal Windows app is WINAPI_PARTITION_APP. So all the functions are inaccessible.

All the CM_Get_Device_xx functions' target platform is Universal though, according to MSDN

Does anyone have try out this in Universal Windows platform? Probably there is some pre-configuration in Project properties? Appreciate the help, thank you.

asked 1 min ago

Let's block ads! (Why?)



cfgmgr32.h in Universal Windows

OneNote page exist but resource link from OneNote API is expired

Vote count: 0

I'm build OneNote add-in and I need some export feature.

From my search, I found only I could use is OneNote API with preAuthenticate param.

It gave me html content and I confirmed it rendered properly with images within in browser yesterday. But today, image links giving below error. And calling above OneNote API gives same. I can't find any way to get renewed one.

{
   @api.url: "http://ift.tt/2l9Migs",
   code: "20130",
   message: "No HTTP resource was found that matches the request URI Resource not found, perhaps the public link has expired. Try a new public page content call.."
}

So, my question is

  1. Is there any way to get html content of OneNote page without expiration?
  2. How to get html content with renewed?
  3. Is there any add-in or OneNote API to export OneNote page as pdf file?

Thanks in advance!

asked 1 min ago

Let's block ads! (Why?)



OneNote page exist but resource link from OneNote API is expired

helpicon functionality on form element using Jquery

Vote count: 0

I am having below form with helpIcon for every form element with description. How we can show help when we are hover on help icon and mouseout using jquery? I am quit new for jquery. so please can someone give simple implementation?

Can anybody help with this issue? Thanks in advance.

asked 21 secs ago

Let's block ads! (Why?)



helpicon functionality on form element using Jquery

specific successRedirect in passport.js with local strategy

Vote count: 0

I have a question about successRedirecting in passport.authenticate. I'm using passport.js and local strategy in nodejs and express for user login and trying to make specific successRedirect route.

For example, if I log in with user id: gpaul(pretended to be successed logging in), then successRedirect route is wanted to be '?channel=gpaul'.

I made the code like below

var data_1 = {email:''};
app.post('/login',
  function (req,res,next){
    req.flash("email");
    data_1.email = req.body.email;
    console.log(data_1.email);
    next();
  }, passport.authenticate('local-login', {
    successRedirect : ('/status.html?channel='+ data_1.email),
    failureRedirect : '/login',
    failureFlash : true
  })
);

After implementing above code, the address comes out with blank , localhost:4000/?channel= from the console log it comes out correctly, but in successRedirect, it doesn't work at all..

Does anybody have any ideas for specific successRedirecting? Please help me out here..

Thanks.

asked 37 secs ago

Let's block ads! (Why?)



specific successRedirect in passport.js with local strategy

Natively implement $ in javascript

Vote count: 0

I was asked a question to implement the following in Javascript

$(div).css('color','red');

I've implemented the following, but I still need pointers.

var $ = new function(selector){

var css = function(){

  document.classList.add('color:red');

};

};

$.prototype.prop = function(){ //for $(div).prop('style', 'color:red');
// need to write code for prop
}

How can I implement in this case?

$(div).prop('style', 'color:red');

How can i natively implement this in javascript?

asked 45 secs ago

Let's block ads! (Why?)



Natively implement $ in javascript

Surefire is triggering jacoco, and that want a minimum coverage. I need to disable that for now

Vote count: 0

I need to disable jacoco for checking for a minimum code coverage amount. Simple reason is that we are just beginning to write unit tests now, retroactively. We can't just not ship because a product which currently works, can't pass some tests. We need to add these tests over time, or severely reduce the minimum.

How do I either disable jacoco, or lower the minimum to 0?

asked 1 min ago

Let's block ads! (Why?)



Surefire is triggering jacoco, and that want a minimum coverage. I need to disable that for now