## Use & ldquo; Global-namespace & rdquo ;;

I just wonder if there's a way to make a class behave as if it is in global namespace using a "use" keyword, so this class would behave as namespaced class only from outside of the class. Something like: namespace wherever\somewhere\deep\deep\in

## Need xpath to locate 2 buttons with almost the same properties for use in the Selenium automation script

Both these buttons have almost similar ID (the number on the ID may change and so is not reliable) Both have same classes They both reside under the same parent Except for the span nothing is different All the UI elements of the application I am tryi

## App.Config escaping

I have this app.config which contains FolderPath under AppSettings node. During testing, the QAs used the path: C:\directory\test & test on FolderPath value that made the application crash on startup. I know it's the unescaped character (specifically

## The VB.NET Array Contains method does not work

In VB.NET I am trying to determine in a given string exists in a String Array. According to my research the Array has a 'Contains' method that I can use, so the Code looks something like this: Dim fileTypesZ As String() = {"PDF", "TXT"

## Where can I find Visual Studio style tabs in an embedded or third-party component?

I want to get Visual Studio style tabs (you know, the ones where you can tab through the currently opened files). Is there a 3rd party component that does this? How hard would it be to do myself?Try http://devexpress.com/free - they have a bunch of c

## Telerik kendo ui mvc dropdownlist in grid in edit mode and display the value in display mode

So i have a Kendo UI grid and i have one column that is a int basically have a int column and 1 means good, 2 means best, 3 means top, Its kind of thing that a Enum would be the right thing to use but i cant (internal business rules) so i need to mak

## Focus on any application with Java (OSX)?

How can I set the focus (e.g. cmd+tab) of an arbitrary application (Java or not) from a Java program, on OSX? Looking for an answer to this question, I came across this question, but it doesn't really help for OSX. EDIT: one possibiltiy seems to be t

## The graph for a polar equation is incomplete in matplotlib

I'm currently trying to graph the equation r = 4 * sin(2 * theta) in the polar plane using matplotlib, based off of the linked example. Here's my code: import numpy as np import matplotlib.pyplot as plt from math import sin, pi def plot_polar(f, star

## How to create a new window in the mfc project

hi im using c++ mfc. i have main window which works all the time and i want to make new window. how can i do it? thanksHi you can create your own dialog by VS master and then do // on some event CMyDialog dlg; dlg.DoMoDal(); link http://www.codersour

## Evaluate a sequence of conditions and stop when the condition has met

This is just a "best practise" question... I have a function that takes an input string and then has to change it based on the content but once a particular condition is met, then all further processing stops. At the moment, I use a "while(

## Problem with the Akrabat zend framework tutorial

I have asked this question earlier today but I didn't provide enough information and therefore it was migrated to the serverfault forum. Well since I think it's not really a server releated problem rather a php related problem i woul lik to ask it he

## SetPosition

Task: grabbing arbitrary frames from mpeg2 video files. Now I use custom render filter for grabbing, but problem with positioning video on required frame. I use SetPosition(), after Pause() for passing frames through graph, wait for filter receive fi

## Powershell: C style function overloaded with parameter sets?

In C#, function overloading has historically appeared something like the following, where each overload adds some amount of parameters on top of the simpler signatures: public void Initialize(int version); public void Initialize(int version, string w

## url rewriting in php localhost with .htaccess does not work

I want to rewrite url from http://localhost/Ent/Movie/Info.php?year=2011&movie=any_movie to http://localhost/Ent/Movie/Info/2011/any_movie I have tried many code in .htaccess,like Options +FollowSymLinks RewriteEngine on RewriteCond %{REQUEST_FILENAM

## & ldquo; invalid use of null & rdquo; for the vba function that returns a variant

I'm trying to write a VBA function that gets a value from an Access table using a SELECT query. Here's the code: Function getTableValue(uniqueID As Long, tableName As String, _ idField As String, tableField As String) As Variant Dim db As Database Di

## Arrival date Difference in Javascript

I've been searching to get the date difference in Javascript, but I am not quite getting the answers I need. When I compare 2015/12/02 to 2015/11/30, the date difference should be 2. But with my code, I get -28. how do I resolve this issue - also con

## heroku & mdash; npm script postinstall to run the grunt task according to the environment

I've got two heroku node.js apps, one for prod and one for dev, and I also have a Gruntfile with dev- and prod-specific tasks. I know you can set up package.json to run grunt as a postinstall hook for npm, but can you specify somehow different tasks

## How to publish data with jQuery

I'm using PHP to submit a very simple data to db. On my page.php, I have a link, by clicking it I insert its id and some other data in the database. For example: echo "<a href='".$base_url."?submit=$page_id'> Submit it</a>"

## Is it an anti-model? If yes, why? Otherwise, why not?

I'm working on a bit of code where we're creating object models but the models have generic keys. For example class myContact { var key; var value; } And then in the code instantiating them as follows myContact = new myContact() myContact.key = 'addr

## Are there any APIs for parsing / extracting text in Java?

I want to know if there is an API to do text analysis in Java. Something that can extract all words in a text, separate words, expressions, etc. Something that can inform if a word found is a number, date, year, name, currency, etc. I'm starting the

## Ignore branch branches as origin / private_ *

When I do git log --decorate --oneline --graph --all I would like to see a graph for all the branches but private branches of other developers. Can I tell git log to ignore branches matching a pattern, like git log --all --ignore-branches="origin/pri

## Can you create a complete Winforms clone ComboBox.ObjectCollection

I am trying to filter out certain items in my winforms combo box. I have a piece of code that obviously does not work since the assignment makes a pointer/reference copy not a deep content copy. I think I am probably using the wrong approach here, th

## Like Stackoverflow, a floating text box at the top of the web page

I am not sure whether Stackoverflow is the right place for this question, but I think it has something to do with Javascript. Here is what I want to add to my webpage: a floating text box at the top of the webpage, you can close it by clicking the "X

## How to link the text as different and a different value from DataTable?

I want to bind text as different and value as different from DataTable in CheckBoxlist In my DataTable I have two columns UserName UserID AAAAA 12 BBBBB 13 I binded this datatable in Checkboxlist this.CheckList.DataSource = dataTable; this.CheckList.

## Asp.net mvc layer division

I am new to asp.net mvc. I want to divide presentation layer with logic layer. I know it is already done in asp.net mvc but I want to have presentation layer on another machine. I don't know if this what I want to do, is possible, but just wanna ask.

## How to make TensorFlow + Keras fast with a TFRecord dataset?

What is an example of how to use a TensorFlow TFRecord with a Keras Model and tf.session.run() while keeping the dataset in tensors w/ queue runners? Below is a snippet that works but it needs the following improvements: Use the Model API specify an

## Unable to open some html files in chrome (mac)

There are some HTML files (no pattern that I've figured out) that I can't open via the terminal, GUI or right clicking Open in Browser via Sublime Text 3. The default browser to open the file is definitely set to Chrome. When I say to open the file i

## JS and PHP - Load php data after js signal without sending back

Alright so basically I have a flash login, which I handled to work with JS using ExternalInterface. I want the php to load only when the user has logged in, how is it possible to do this without sending a new postback (reloading the page)? What I bas

## Passing a hidden field value to a user control in javascript

I have a HiddenField which changes value depending on what the user clicks. On the same page I have an invisible Panel with a User Control inside of it. I want to pass this value to the control when the Panel becomes visible. The code: <asp:HiddenFie

## Where to make an initial AJAX query in ReactJS

I have a page where I need to load some initial Ajax data. I read on this Reactjs page that I should make the call in componentDidMount. What is the advantage of making the request from componentDidMount rather than componentWillMount ?Since react is