Windows Forms Application C #: adding global variables:

Good day, I am trying to make a windows forms application that requires connectivity to one of our databases. I can get connected to the database with System.Data.Odbc objects. I have no problem creating OdbcConnection objects in local functions, ope

Python multiline lambda

I am wondering if there is possible to find some equivalent to C# multiline lambda function in Python. Let's say, that I have C# code like this: I want to write some equivalent python code for this method. But as far as I know there is no possibility

Entity Framework MVC Slow Page Loads

I have a web application running on Windows Azure. It is built with ASP.Net 4.0, MVC 3, Entity Framework 4.1, SQL Server 2008 using the Repository pattern. The app was performing very well until recently. Most of our customers have a few hundred rows

How to read the html string

I implemented ccavenue integration in my android app ccavenue returns html string I need to read html body content and table rows from that string Below is html string <head><head> <meta http-equiv="Content-Type" content="tex

Echo sqlplus command without using prompts or scripts

I have a script which I want to maintain as a single file, however I wish to echo the commands input into sqlplus without using either PROMPT <sql> or @script.sql can this be done? Current script: $ cat test.sh #!/bin/bash LOG=/home/oracle/output.lo

How do I get content from WPF ContentControl?

I'm using a ContentControl to render various UserControl derivations dynamically. I can't for the life of me figure out how to get the content to stretch when I resize the parent Window. I've found many references like this, but it's still not workin

Regular expression to divide & ldquo; / n & rdquo;

I want to split the /n from my string in Java. For example, I have one String field which has 2 lines space ( /n). I have to find out lines ( wherever mopre than one lines is coming) and should replace with one line spaces. "This is Test Message than

Get the action of the controller of url, laravel

Can I get the controller action from given URL? In my project, I will have different layout used for admin and normal users. i.e. something.com/content/list - will show layout 1. something.com/admin/content/list - will show layout 2. (But these need

Find a separate object in the table by es6

I have an array like below const data = [ { name:'AAAA', group: 'A', age:10 }, { name:'ABCD', group: 'A', age:10 }, { name:'DJSHDJH', group: 'B', age:15 }, { name:'FJHF', group: 'B', age:20 } ] I want to find distinct data by group and age by es6 exp

Do I need multi-threading for this project?

Target Platform: Windows XP high school computers Libraries Required: SFML, GLEW, ODE, Python (for embedding) Planned Features that lead me to believe I may need multi-threading: Up to a hundred robots all interpreting python scripts in real time. Al

Managing PHP errors in the WordPress plugin

I am a newbie to both PHP and Wordpress (but do ok in C#), and am struggling to understand the error handling in a custom plugin I am attempting to write. The basics of the plugin is to query an exsiting MSSQL database (note its not the standard MYSQ

T Column name alias SQL based on a query from a table

I have to display a column name from a select query from table, e,g, 'Column 1' is stored in table table1, I want to display 'Column 1' as column name. I cannot hardcode 'Column 1' as it might be unknown when the code is developed. Column 1 Column 2

jQuery: Add 4 weeks to date in dd-mm-yyyy format

I have a string which has a date in the format: dd-mm-yyyy How I can add 4 weeks to the string and then generate a new string using jQuery / Javascript? I have var d = new Date(current_date); d.setMonth(d.getMonth() + 1); current_date_new = (d.getMon

JNI and C ++ - UnsatisfiedLinkError

I'm using JNI successfully to call some C code, however when I want to change to C++ JNI throws an UnsatisfiedLinkError whenever I try to call a method. This one works: g++ -c -Icryptopp562 -O3 -fPIC -fpermissive CI3CppEncryptionToolsImpl.cpp gcc -I$

Recovering data from one-to-many relationship

I'm trying to retrieve data from a one-to-many relationship, in an ASP.NET MVC application. Let's say I have two tables Posts and Category with the following attributes: posts -id -title -category_id category -id -name -author I want to grab posts th

CSS Class Kentico Admin UI

I'm looking for Kentico provided CSS classes that I can use to make CMS specific CSS edits to a site that I'm building in Kentico. I'm using a position fixed layout for the header, which is overlapped in several places by Kentico's various admin pane

Mixing 32-bit and 64-bit managed assemblies

All, I have a .NET managed application which runs in 32bit machines. I am fine with compiling it to 64bit and port it on a 64bit machine. However I depend on some 3rd party DLLs which are 32 bit assemblies. Can I mix 64bit and 32bit assemblies togeth

class php to serve the properties of an object

I am new to PHP OOP (coded PHP in procedural style for some time now) and I think that I understood the SOLID principles and I understood that an object not necessarely is equal to an entity in a relational database. Anyway I have slight problems to

Codeigniter - Selection of database

Hi, I need a help related to Codeigniter very badly. I have some problems with a database query, i'am new to Codeigniter. I have 3 tables: 1) film(film_id, filmname) PK (film_id) 2) category(category_id, categoryname) PK (category_id) 3) film_categor

How to pass arguments as tuple to odeint?

I wanted to use odeint of scipy with a function def func(y,t,a=123,b=456) then use it as odeint(func,y0,t) If I want to change the values a and b using args odeint(func,y0,t,args=(a=1,b=2)) It complains that arguments are not tuple. It may be a very

align the labels with the input text

I have a form that should look like this one: http://jsfiddle.net/g6kQK/ but if I inspect the generated code this is what I get: http://jsfiddle.net/bxA5X/ The problem seems to be with display: block; float: left; but if delete those attributes nothi

Changing the background color of the tr element on mouseover

I want to have my table rows highlighted on mouse over, but I have yet to find a way to do it that isn't using Javascript. Is this not possible in CSS? I've tried this: tr:hover { background: #000; } But that doesn't work. Using td:hover works, but I

Codeigniter Pagination: Execute the query twice?

I'm using codeigniter and the pagination class. This is such a basic question, but I need to make sure I'm not missing something. In order to get the config items necessary to paginate results getting them from a MySQL database it's basically necessa

manipulate two ng-repeats in the same table

I have a list of images saved in var images, and a list of names saved in var searchName, now I need to display images along with name, but I could display it after all images displayed only. HTML: <div class="row col-sm-12" > <table cl