Posts

Showing posts from February, 2013

android - ActionBarSherlock Change Height? -

I'm trying to change the height of my action bar to feel more of it, but whatever I try Never think of to work. I currently have this: Is there any other solution? Or am I making some bone-head errors here that I'm not picking up? Thanks! Changing the height of the ActionbarSlock is not a solution. Transitional Experiment System Bars Now you can make the system partially transparent with new topics, check this project If you are creating a custom theme, set one of these topics as a parent theme or include more style properties in your subject. Hope that helps you get started.

c - How to make the below condition fail by giving inputs through stdin -

शून्य मुख्य () {float x; जबकि (scanf ("% f", & amp; x)! = 0) printf ("% f \ n", x); } उपरोक्त कोड stdin से इनपुट लेता है और इसे दोहराता रहता है लेकिन यह कैसे खत्म होगा? मुझे पता है कि scanf ईओएफ वापस कर सकता है, अगर मैं की तरह एक चेक जोड़ते समय (scanf ("% f", & amp; x)! = EOF) कौन से इनपुट stdin से ऊपर के किसी भी दो शर्त को विफल करने के लिए पैदा कर सकता है? Ctrl + d प्रोग्राम को समाप्त कर देगा लेकिन मैं जानना चाहता हूँ कि क्या कोई ऐसी विशिष्ट इनपुट है जो इस स्थिति को विफल कर सकती है? लिनक्स मैनुअल पृष्ठ देख रहे हैं: scanf: ये फ़ंक्शन इनपुट आइटम की संख्या को सफलतापूर्वक मिलान और सौंपा जाता है, जो कि कम से कम हो सकता है, या यहां तक ​​कि शून्य की स्थिति में प्रारंभिक मिलान विफलता। तो, अपने मूल प्रोग्राम का उपयोग कर: शून्य मुख्य () {float x; जबकि (scanf ("% f", & amp; x)! = 0) printf ("% f \ n", x); } इसका अर्थ है कि यदि आप कुछ भी दर्ज करते हैं जो परिवर्तनीय नहीं है, तो आपका प्रोग्राम समाप्त हो जाए...

c++ - HowTo print with Qt5 without driver (PostScript / PCL) -

I am developing an application that should run on an embedded device. That is why I came to know that PostScript or PCL is a good option for me. Since PCL or PostScript does not support Q5, I want to use another library for my export but I could not find a single library yet. I would also like to know, if there are other standards like PCL or PostScript to use the printer without installing a driver. Qt supports QP, which supports a flexible driver architecture, and postscript, PCL and PDF Supports printers, and many more.

javascript - How to check what was clicked in jquery? -

I want to see what was clicked on the entire document and save this information to target variables . I want to make some arguments with knowledge about the goal clicked. Here is sample code: $ (document) .ready (function () {console.log ("document (event == last event) {event =" ";} =" ";" EVENT_NOTHING ";} If (event! = Previous event & amp; incident! =" EVENT_NOTHING ") {console.log (" EVENT: "+ event); // (...) Some arguments (...)} last event = Event;} Loop = set interval (loop, 100); // event $ (document) .Kiddown (function (e) {var key = e.which; if (key = Event = "EVENT_KEYPRESS_LEFTARROW"; if (key == "38") event = "EVENT_KEYPRESS_UPARROW"; and if (key == "39") event = "EVENT_KEYPRESS_RIGHTARROW"; and if (key == "40 ") Event =" EVENT_KEYPRESS_DOWNARROW "; other {d} No = "EVENT_KEYPRESS_UNBINDED";}} Click $ (document). (Function () ...

visual studio 2012 - Why is CodedUI TestMap very slow in Remote Desktop? -

I am using VSTS 2012 for UI automation on the client machine that is used for VMware Connected through the medium. The problem is with the UI Test Map whenever I try to capture or detect an object, VSTS takes a lot of time to find it. This is very time consuming. Can someone please help to overcome it or is it something with VSTS behavior? Please ASAP help. Regards Start a remote session using this command: mstsc / console You still get all the benefits like dynamic screen resolution, but control detection will be very fast

c# - Time Filter in GridMvc -

Image
I can not find the time filter properly, it displays calendar instead of time, however the calendar should only be displayed when Date filter is selected. Below is the code for my idea, I also attached the image I downloaded the sample source code from the following link View @ GridMvc @ GridMvc.Sorting @memel IEnumerable using HTML. & Lt; GridMvc .Site.Logging & gt; Add column (column = & gt; {/ * "Order ID" column: * / columns.Add (o = & gt; OID). Tetched ("number") .SetWed (100); column.ed (o = & Gt; O.Datetime, "Date"). Tetched ("Date"). Artificial Decision (Grid Associated Direction) Format ("{0: DD / MM / YYYY}"). Setwidth (110); Ed (o = & gt; o.tatme, "time"). Tetched ("time"). Artistic Direction (Grid Associated Direction). Format ("{0: hh: MMT}"). Setwid (110); Column.ed (o = & gt (O. Type). Setwidth (150). Then STRBDAndanding (O = & gt; OID); // Set Filte...

grails - Connecting to Active directory and searching user -

In the Grails project, I need to connect to Active Directory and search the user (authentication objectives). I am big in LDAP and Active Directory and using it. My company gave me a user credentials for testing OU = vendors, DC = company, DC = Net CN = test -2 sAMAccountName = test2 password = test123 Ip = LDAP: //xx.xx.xx.xx: 389 So what I have tried LDAP ldapConn = LDAP.newInstance (" LDAP: //xx.xx.xx.xx: 389 "," CN = test-2, OU = vendor, DC = company, DC = net "," test 123 ") {DEF result = ldapConn.search ('(' CN = Test-2) ',' OU = Vendor, DC = Company, DC = Net ', Searchzco .on) println "$ {results.size} entries found:" println result} hold (exception before) {println ex.printStackTrace ()} The above code works and I activate I am using CN = Testing -2 to force the directory, but the employees of the company always use sAMAccountName for login. Therefore, when I tried to bind Ith sAMAccountName =...

sockets - Button not apear in android device but shown in corona simulator and mobogini -

I can see buttons in the Corona simulator and genomes, but on Android devices I do not see anything and no console The errors in this are the main. Lua and server.lua, please help me fix my problem main.lua local S = {} local socket = requirement ("Socket") local clientList = {} local clientBuffer = {} S.getIP = function local S = socket.udp (): setpeername ("74.125.115.104", 80) Local IP, Sock = s: Getockname (), (IP: "IIP:", IP, Sock) Returns IP and S Socket Surce = Function () Local TCP, IRL = Socket.Bind (SAGTAP (), 1235) - Create a server object TCP: Set Timeout (0) Local Function sPulse (repeat) Local Client = TCP: Accept () - If the client Then enter a new client to connect the print ("Client"): settimeout (0) - just check the socket and keep going - -TO DO: Apply a way to see if the client has already Connected - Tell the client the session ID to the client and use it on reconnect. ClientList [# clientList + 1] = Customer cli...

tcl/tk: want to plot chart and histogram with tcl, what special package needed? -

I want to plot a chart with TCL / TK What special package do I need? If possible, then I do not want to use a special package. Does the default TCL package have plot functions? Although the original device ( canvas widget) comes with thanks, There is no special to conspiracy. You have to use the package or write your own (which may be a little stupid). Package in Tulleb is TCL pure and unless you are doing something really are not complicated then it is recommended.

ruby on rails - Locating uploaded file with Rspec 3 -

I am trying to find out my last uploaded file (using careership) and has_dimensions This is a mistake in my test result in the moment a Rspec method to run with failure / error. Expect (@ uploader.large_animal_image) to have_dimensions. Campaign (555, 365) Errno :: ENOENT: Any such file or directory @ rb_sysopen - My test looks like this (after example Github tried on page but did not work as file upload.). Test :: Matchers included: Each) AnimalImageUploader.enable_processing = true @animal = FactoryGirl .create (: image) @uploader = AnimalImageUploader.new (@animal, image) A Mr. (@ uploader) @ Aploderkstor! End (: each) do @ uploader.remove! AnimalImageUploader.enable_processing = false End Reference 'Image Version' is the 'scale should big_animal_image to 555 x 365' (@ uploader.large_animal_image) has_dimensions (555, 365) end end end ap (@uploader) output # & lt; AnimalImageUploader: 0x000000080ae738 @model = # & lt; AnimalImage ID: 50,...

mysql - Update table without using REPLACE INTO -

My application stores some logs in a table locally, but it also stores the same data on the remote server database Does. If for some reason the connection to the remote server is broken, the application continues locally to the data storage. At the end of the work, the application has to copy the local data to the remote server. The tables on either side have the same structure but no primary key is defined so replace it in Another way to copy data from the local database to the remote database Is not there a copy of existing records in the remote database? How this table looks: + ------------- + ------------ + ------------ + | ProductionID | Get started | Factor | + ------------- + ------------ + ------------ + | 1123 | 1 | Y + ------------- + ------------ + ------------ + | 1123 | 2 | En | + ------------- + ------------ + ------------ + | 1123 | 3 | Y + ------------- + ------------ + ------------ + | 2212 | 6 | Y + ------------- + ------------ + ------------ + | 2212 | 4...

set and retrieve auto increment value from mysql to java (set in jlabel) -

Table A has two fields: ID, name. I value id, java mysql. Open Form 1 and click New jbutton display jlabel1 value = id (autoincrement value) from mysql.and user (name) input value jtextfield.and asusual stored. Here's my problem: How can I get automatic increase value from mysql to java (id set in jlabel). You can fire the query to get the next. The value of the maximum id, for example: - Select Max (ID) +1 from table_name;

etl - Source in my SSIS package isn't picking the float values with preceding zeros -

I have a package that takes the source as a text file and has a article The column is the source. It is numerical and has a float in the destination, so if a value comes to 0000123 then it goes to destinations like 123 (before zero). However, in the same package, the same stuff in a different column is the numerical source and float destination but the value of this column in the source is before zero, it fails. Example - 123 will be loaded in destination 0123 will not be identified and will fail on the source Can any of you please help me? How do I fix it. Did you confirm that the columns which are failing have any leading or back "white The location is not " This column will fail because it is trying to change the numerical white space form.

javascript - jQuery On click wont fire -

मेरे पास एक textbox , एक चेकबॉक्स और span टैग है जब मैं चेकबॉक्स पर क्लिक करता हूं, तो उसे span टैग में अपनी स्थिति दिखानी चाहिए। जब टेक्स्टबॉक्स नवीनीकृत हो जाता है, तो वह चेकबॉक्स ब्लॉक फिर से करता है जब आप अब चेकबॉक्स पर क्लिक करते हैं, तो यह राज्य को अपडेट करने में विफल रहता है। मैं चेक बॉक्स क्लिक ईवेंट के लिए पर ईवेंट हैंडलर का उपयोग कर रहा हूं, इसलिए मुझे उम्मीद है कि यह काम करेगा। कोई भी विचार क्यों यह अपेक्षित रूप से काम नहीं कर रहा है? $ ('div [भूमिका] इनपुट [type = checkbox]')। पर (' क्लिक करें ', chg); $ ('Div [भूमिका] इनपुट [प्रकार = पाठ]')। पर ('इनपुट', स्रोत परिवर्तित); फ़ंक्शन chg () {var isitiki = $ (this) .is (": चेक"); । $ ( '# Upd') एचटीएमएल (istiki); } Function sourceChanged () {$ ('span', $ (this) .closest ('इनपुट-समूह'))। Html ('& lt; इनपुट प्रकार = "चेकबॉक्स" & gt;'); } & lt; script src = "https://ajax.googleapis.com/ajax/libs/ jQuery ...

optimization - Using MATLAB with AMPL -

I have a collection of optimization problems written in APLL and GAMS. And I have an algorithm in Matlab. How can I solve these problems with algorithm in multab? I have read about the GDSXRR interface for GAMS, but as I have understood it is only Matlab & amp; GAMS? So is it necessary to calculate all the gradients, derivatives etc in GADA and then give these results to Matlab? Maybe someone knows how to connect it? "post-text" itemprop = "text"> You can add AMPL to MATLAB using amplfunc.mex and Spamfunc.mex These Mac files are available for download by amplfunc function by amplfunc.mex . The provided by can be calculated automatically. An AMPL interface for matrices has also been developed.

shell - find the second word in first line which starts with specific word and replace the next line first word in linux -

I need to convert the following files to a new file ... I have a file with me .... uid = GESCHELP1, or = special user, DC = domain, DC = com different: C1: Ind variations: SO1: REC UID = GESEXHP2, oo = special User, DC = Domain, DC = Com Separate: Country 1: United States Separate: given name 1: Raj should follow the output file ....... DA : UID = GSEXHAP1, OU = Special User, DC = Domain, DC = COM Change Type: Change Change: CC: ING - CC: SOP SR: REC UID = GESEXHAP2, OA = Special User, DC Please help me get the solution. P> This command will give the necessary results awk -F ': *' -v OFS = ":" '$ 1 == "Replace" {r = $ 2; Print; Next} r {$ 1 = R; R = ""} 7 'file

javascript - CKEditor plugin - How to have a span within a span, by using editor.applyStyle -

Image
Currently, I have a custom plugin dialog with drop down box selection, which I Apple Or Samsung between the tags. Here's how onClick function looks like this. onOk: function () {var dialog = this; // Drop Down box selection can be either "Apple" or "Samsung" var brand = dialog.get value ('tab-brand', 'brand'); Var style = new CKEDITOR.style ({element: 'span', attributes: {"brand": brand}}); Editor. App style (style); Console.log (editor.getData ()); } Suppose the following code does not work within my expectation, I have the following text My little sheep is step 1 "Small" was highlighted. "Apple" was selected right pressed One small lamb in Mary I got the following console output will get. My a & lt; Span brand = "apple" & gt; Slightly & lt; / Span & gt; Lamb kids phase 2 "little lamb" was highlighted. "Samsung" was se...

css - Understanding the flexible padding -

page Ethan Marcote in responsive web design under regular box model. 35, wrote: When setting flexible padding on an element, your reference is the width of the element . Please take a look at the following example: .main-wrapper {width: 98%; / * 960px - to give some space on viewport * / .box-one. Box-two {width: 44.7 966666667%; / * 430/960 * / float: left; Margin: 30px 0 20px 0; Padding: 2.083333333333%; / * Padding 20px * / text-alignment: center; }. Box-A {margin-right: 2.083333333333%; / * Margin is relative to the container (960px here), therefore: 20/960 * / background color: red; }. Box-two {background-color: blue; } & lt; Div class = "main-wrapper" & gt; & Lt; Div class = "box-one" & gt; & Lt; P & gt; One box here & lt; / P & gt; & Lt; / Div & gt; & Lt; Div class = "box-two" & gt; & Lt; P & gt; Two box here & lt; / P & gt; & Lt; / Div & gt; My qu...

push local branch to remote repository but download fails in git -

I created a Bayer-Barre project in GERIT In my local GIT repository I $ git branch -a * Master Remotes / Original / Head - & gt; Original / Master Remote / Original / Develop / BSP / Master Remote / Original / Develop / BSP / Kernel-310-DR Remote / Original / Master Remote / Original / Task / Ed / Colonel After that I can do the following commands like $ git push --all ssh: // admin @ localhost: 29418 / kernel-test View in Garyit Server Gereit / Kernel Test $ git branch -a * Master Remotes / Original / Head - & gt; Original / Master Remote / Original / Develop / BSP / Master Remote / Original / Develop / BSP / Kernel-310-DR Remote / Original / Master Remote / Original / Task / Ed / Colonel But when I clone the git for the same project, then I only $ git branch -a * master remotes / origin / HEAD - & gt; Can see Remote / Origin / Kernel, Remote / Origin / Devell / BSP / Kernel-3.10-Dev and other branches Gereit / Kernel-Test repo > Remot...

oracle - in package, how we can create a nested function using PLSQL -

I tried to create a package. And in the package body I defined a function. In that fun I tried to make another function. I used this argument because I need to call the process that is in my process. Can you help me. create or replace L2C_pkg_limit package as GET_CUST_PROBLEM_DETAILS return number; End L2C_pkg_limit; Or function nested GET_CUST_PROBLEM_DETAILS return number p_cust_diagnostic_cursor_lmt constant number (2): = 1; Creating or replacing package body L2C_pkg_limit in the form of creating or changing functions; Function p_cust_diagnostic_cursor_lmt Return number returns starts p_cust_diagnostic_cursor_lmt; End; Start Return p_cust_diagnostic_cursor_lmt; End Nested GET_CUST_PROBLEM_DETAILS; End; Do not use or change In a package body - just declare the function using the keyword function . Any keyword in Oracle is not "nested" A nested function is only one that has been declared in the declaration section of another function or process. The f...

php - Why is XAMPP not suited for production? -

I have been running XMPP on Windows 2008 R2 for many years, I'm just using Apache, MySky and FileZilla I am I've made many custom adjustments and upgraded it several times, I have addressed all the security issues that I can get. As the services are running, the servers are never below the bottom until Windows Server is above. They are incredible, why do people tell me why should not I do this on earth? None of Q or A are related to the features here, most of them usually end in "not recommended", "this is what XAMPP says on the Web site, so this is bad". I understand that you should not use XAMPP outside of the box because it is not safe for production, but by changing all root users, instead of plain HT using https / certificate, using MySQL users in my scripts With Limited Privileges, the statement made (either PDO or Myculty) in php MySQL queries, catching expetions, handling errors, etc. Protect Ail folders and can not NTT gritty I see PPP programmi...

avr - atmega8 UART- doesn't show character in realterm [Solved] -

Hi I'm new to this and should help me It seems that instead of just showing 's' in reality What is the 'empty' problem? Can this be a registration? Or code itself? #include & lt; Avr / io.h & gt; # Include & lt; Use / delay.h & gt; Zero UART_Init (unsigned int ubrr) {UBRRH = (unsigned integer) (ubrr & gt; & gt; 8); UBRRL = (unsigned int) ubrr; UCSRA = 0x00; UCSRB = (1 & lt; TXEN) | (1 The speed is 9600 baud on the host running with 14745600 Hz on System xtal. All settings should be 8 N1. You need to set ursel while typing in the UCSRC register. Change UCSRC = (0 to UCSRC = (1 The UBRRH register shares the same I / O location as the UCRC register. Therefore, there should be some special consideration when accessing this I / O location. When a written access to this I / O location, then the high bit of written value, the USART Register Register (URSELL) bit, one of the two registers which will be written in cont...

jquery - Internal server error while processing AJAX request in MVC5 -

I have something inside a MVC 5 app and my _Layout.cshtml file like this: & lt; Div class = "input-top" & gt; & Lt; One class = "gobtn" href = "" & gt; & Lt; Img src = "~ / content / img / GOBtn.png" class = "gobtn-position" & gt; & Lt; / A & gt; & Lt; Input id = "homezip code" type = "text" class = "form-control input-position-2" placeholder = "zip" & gt; & Lt; Input id = "home system" type = "text" class = "form-control input-position-1" placeholder = "What do you need to do today?" & Gt; & Lt; / Div & gt; And the point is that when the user fills the above input and presses the href attribute, then I want to open a new watch page and send the data with the view. The verb method that is related to the vision is defined as: [authorized] public action service request () {...} [authorize] [h...

Powershell Regex extracting values not ending with mid string -

I need a regex, which will work with powershell. It's like string .. .. .. .. \ packages \ Microsoft.Samples.Security.SSPI.1.0.0 \ lib \ net11 \ Microsoft .Samples.Security.SSPI.dll .. \. \. \ Packages \ Antlr3.3.4.1.9004 \ lib \ Antlr3.Runtime.dll Vacancy number and name removal in these cases: samples. Security. SPI and 1.0.0 AntRR3 and 3.4.1.9004 I believe packages \\ (& lt ;? Name & gt; [^ \ \\\] (& lt;?!. \ [0-9] + \).) (\ Lt & gt; version & gt; [0-9] + (\ [[0- 9] +) + ) [\\\ /] should do the trick but it does not seem to look like a window power shell to look for a job. > I'm not familiar with the regex taste of powershell, but it seems like you need to start with is not. Are you a lazy quarantine +? Use to stop at the first place: package \\ (? & Lt; name & gt; [^ \\] +?) \. See (? & Lt; version & gt; \ d + (?: \. \ D +) *)

javascript - How to hide certain elements in angular, based on the ng-class? -

मेरे पास निम्न कोड है: & lt; tr ng-repeat = "सभी संस्करणों में संस्करण "एनजी-क्लास =" {{संस्करण ['सक्रिय'] == 'सच'? 'सक्रिय': 'निष्क्रिय'}} "& gt; & Lt; / टीआर & gt; मैं ऑब्जेक्ट के आधार पर एनजी-क्लास बना रहा हूं और इसके ठीक काम करता हूं। मुझे अपेक्षित उत्पादन मिल रहा है। लेकिन मैं यहाँ जो चाहता हूं, ng-class जिसका मान है निष्क्रिय को शुरू में छिपाने की आवश्यकता है एक कहें बटन के क्लिक पर, उसे दिखाया जाना चाहिए मूल रूप से एक टॉगल बटन की तरह, फिर से क्लिक किए जाने पर, केवल सक्रिय फ़ील्ड दिखाता है मैंने यह कोशिश की: & lt; tr ng-repeat = "सभी संस्करणों में संस्करण" एनजी-वर्ग = "{{संस्करण ['सक्रिय'] == 'सच '?' सक्रिय ':' निष्क्रिय '}} "एनजी-शो =" संस्करण [' सक्रिय '] ==' सच '' & gt; & Lt; / टीआर & gt; जो केवल सक्रिय दिखा रहा है, लेकिन अगर मैं बटन क्लिक पर निष्क्रिय दिखाना चाहता हूं, तो कैसे आगे बढ़ना...

python - Multiple Numpy random shuffles does not add up -

I am trying to generate an array of neighbors, each neighbor is different from previous neighbors in the previous random shuffle, Either a line or column shuffle should be prepared only when a certain line or column is greater than K1, and if so, then a neighbor should be reversed by this row or column. Shuffle should be added, which means if the first row is rotated and then one column; Two neighbors should be built, with a resizing line and a line and a column. However, it seems that the array is only two times, one for the column loop and one for the other loop, and the shuffle is not added. In this example, column index 1 and 2 should be shuffled, and row index 3 and 4. Here is an example, showing the population generated. [[0 1 1] [0 0 0 0] [0 0] [0 1 1 0] [1 1 1 0]] [0 0 1 1] [0 0 0 0] [0 0 1 0] [0 1 0 0] [1 1 1]] [[0 1 1] [0 0 0 0] [0 0 1 0 1] [0 1 0 0] [1 1 0]] [[0 1 0] [0 0 1 0] [0 1 1 0 0] Here is the code: k = 2 tmp = np.array ([, 0, 0, 1, 1], [0], 0, 1, 0, ...

Creating two virtual networks in Vagrant -

I need 2 virtual passionate networks to talk to each other through a 'gateway'. I am modeling multi-level applications that will be deployed on multiple servers. I need something like this: DB-Server - - DB-Server | | - Distributor **** Distributor - | | Make app-server-apple-server db-server , app-server and distributor private network. This network should be accessible from the other virtual network's distributor . I have to do Vagrantfile : VAGRANTFILE_API_VERSION = "2" Vagrant.configure (VAGRANTFILE_API_VERSION). Config | Config.vm.box = "ubuntu / trusty64" # db-server config.vm.define "db" do | Db | Db.vm.hostname = "db" db.vm.provider to "virtualbox". V | V.customize ["modifyvm": id, "--cpus", "1"] v.customize ["modifyvm", id, "--memory", "512"] end db.vm.network "private_network "," IP ":" 192.168.10.11 "and #...

c++ - Adding a QLabel to a QWidget -

Image
I am trying to add using. I am setting the label's text to something but it is not visible in the label. Here is the code snippet: setStyleSheet ("QWidget {background-color: RGBA (160, 160, 160, 255); boundary-radius: 7px;} "); QLabel * label = new QLable (this); QHBoxLayout * layout = new QHBoxLayout (); Label-> Set text ("random string"); Layout & gt; AddWidget (label); SetLayout (layout); is for the stylesheet widget in which QLabel has been added. The string is not displayed inside the "random string" label. Please help. Your code contains a typo, it is not QLabel , not QLable ... Assuming this will inform you in the compilation of time, I do not know what the problem is, code you probably have with us your project mynewwidget.h #ifndef MyNEWWIDGET_H #define MYNEWWIDGET_H #include & lt; QWidget & gt; Category MyNewWidget: Public QWidget {Q_OBJECT Public: Clear MyNewWidget (QWidget...

c# - Is it possible to return all columns data of an entity in Entity Framework -

क्या यह इकाई वर्ग के लिए संभव है class mytest {public int id {get; Entity Framework के साथ इस इकाई को क्वेरी करने के लिए और अपने सभी स्तंभ बाहर उन्हें सी # वर्ग में उपस्थित होने के बिना प्राप्त करें? एक मेज को देखते हुए मैं चाहता हूँ मुझे पता है कि कुछ कॉलमों पर आधारित फिल्टर मौजूद है और फिर सभी अन्य स्तंभों को अभी भी वापस लौटाएं, ऊपर के मामले में मैं तालिका को आईडी कॉलम के रूप में जानता हूं। आपको सभी गुण हैं जो आप चाहते हैं कि आपके .Net कोड में इकाई वर्ग में परिभाषित किया गया हो, लेकिन आप" ज्ञात "फ़ील्ड को परिभाषित करने के लिए वर्ग पर एक अंतरफलक सेट करते हैं पर क्वेरी करना चाहते हैं, जैसे कि आईडी: सार्वजनिक इंटरफ़ेस IEtity {int id {get; सेट; }} और उसके बाद आप उन परिभाषित क्षेत्रों की क्वेरी के लिए ईएफ का उपयोग कर सकते हैं, या आप ईएफ प्रसंग पर जेनेरिक विधियों का उपयोग कुछ फ़ील्ड के लिए क्वेरी करने के लिए कर सकते हैं, जिनमें प्रत्येक संस्था का होना चाहिए, जैसे कि आईडी: context.Set & lt; TEntity & gt; ()। ढूँढें (आईडी); या context.Set ...

c++ - Catch exception in boost::property_tree::read_xml -

I am trying to capture the exception which is boost :: property_tree :: xml_parser :: read_xml . Here is my example program: #include & lt; Iostream & gt; # Include & lt; Boost / property_tree / ptree.hpp & gt; # Include & lt; Boost / property_tree / xml_parser.hpp & gt; Int main (int argc, char ** argv) {boost :: property_tree :: ptree pt; Std :: Court & lt; & Lt; "123,123" & lt; & Lt; Std :: endl; Try {std :: court & lt; & Lt; "Read" & lt; & Lt; Argv [1] is referred to as & lt; & Lt; Std :: endl; Read_xml (argv [1], PT); } Hold (const boost :: property_tree :: xml_parser :: xml_parser_error & ex) {std :: cout & lt; & Lt; Argv [1] & lt; & Lt; "Failed, Reading" & lt; & Lt; Argv [2] & lt; & Lt; Std :: endl; Read_xml (argv [2], PT); }} Output is: 123123 read 123.xml [1] 9 7028 abort ./a.out 123.xml 345.xml What am I doing wrong? Obviously the ...

c - How can I make scalable GTK_IMAGE -

I have to display an image inside the window that changes the window size by the user. I have tried to use the size-allocated event like this: Fixed gabolian allocation (GtkWidget * w, GtkAllocation * a, char * data) {/ * pix. Is * / Gtk_image_set_from_pixbuf (GTK_IMAGE (picture), px); / * Scale_image scales the picksbuff of GTK_IMAGE while keeping the height / / scale_image (GTK_IMAGE (image), A-> the width, A-> height;} the description is false;} In the main: g_signal_connect (G_OBJECT (window), "size-allocation", gcolblack (alaukack), null); It only works when you make it big, but you can not shorten its estimation because the image has been allocated size. I could only use the width -100 or something else but There is a better way to breathe.Another thing that does not work in my solution is going back to the maximum window, I would like to go back to the size where it was maximized Now it simply prevents the window But the image is still the same wi...

sql - MySql query group by day and by time -

I am trying to create a SQL query to solve my problem. My table: + ---- + --------------------- + ------- + | ID | Date | Price | + ---- + --------------------- + ------- + | 1 | 2014-10-10 05:10:10 | 10 | + ---- + --------------------- + ------- + | 2 | 2014-10-10 09:10:10 | 20 | + ---- + --------------------- + ------- + | 3 | 2014-10-10 15:10:10 | 30 | + ---- + --------------------- + ------- + | 4 | 2014-10-10 23:10:10 | 40 | + ---- + --------------------- + ------- + | 5 | 2014-10-11 08:10:10 | 15 | + ---- + --------------------- + ------- + | 6 | 2014-10-11 09:10:10 | 25 | + ---- + --------------------- + ------- + | 7 | 2014-10-11 10:10:10 | 30 | + ---- + --------------------- + ------- + | 8 | 2014-10-11 23:10:10 | 40 | + ---- + --------------------- + ------- + I want to The time period in the day by group and on this day in three sub groups 'morning' (06:00 - 12:00), 'noon' (12:00 - 18:00) and 'night' (00:00 - 06:00 and 18:00 - 24:00) Som...

sql - How best can I recreate an Oracle database? -

Oracle 11 GR2 (x86 Windows): I have a DB with 250 tablets with indexes and constraints I I need to re-create these tables, indexes and hurdles in new db and load the data. I need to know how to do the following in SQL Plus and / or SQL Developers, unless this is a magical utility that can automate all this. thank you in advanced! Unload all data from 250 tables. Create a SQL script file containing the create table statement for 250 tables. Create a SQL scripts file containing the CREATE INDEX statement for 250 tables Create a SQL script file containing the ALTER TABLE ADD CONSTRIENCE statement for 250 tables. Run the script to create tables in the new DB. Load the exported data in the table in the new DB. Run the script to make all indexes. Run the script to add all the controls. Edit: I am connected to a remote desktop that links to source db on a Windows Server 2008. Only one Oracle client is installed in the remote. For security reason...

matlab - Extracting lower Triangular matrix without considering diagonal element -

मेरे पास 5x5 मैट्रिक्स है ए = [0 0 0 0 1; 0.36 0 0 0 1; 0 0.25 0 0 1; 0.35 0 0 0 1; 0 0 0.28 0 1]; मैं विकर्ण तत्वों पर विचार किए बिना मैट्रिक्स के निचले त्रिकोणीय तत्वों को निकालना चाहता हूं। इसलिए, परिणामस्वरूप मैट्रिक्स होनी चाहिए सी = [0.36 0 0.35 0 0.25 0 0 0 0.28 0] मुझे ये बताएं कि मैं यह कैसे प्राप्त कर सकता हूं। मैं यह मान रहा हूँ कि मैट्रैक्स के प्रारूप के आधार पर यह मैटलैब है। यदि आप एक सदिश वेक्टर में निचले त्रिकोणीय हिस्से के तत्व चाहते हैं, तो आप इसे एक पाश के साथ कर सकते हैं (हालांकि मुझे यकीन है कि किसी के पास निफ्टी वेक्टरयुक्त दृष्टिकोण होगा): C = []; N = 1 के लिए: आकार (ए, 1) सी = [सी, ए (एन + 1: एंड, एन) ']; आउट आउटपुट है: सी = 0.36 0.00 0.35 0.00 0.25 0.00 0.00 0.00 0.28 0.00 यदि इसके बजाय आप पूर्ण 5x5 मैट्रिक्स चाहते हैं, तो आप इसका दूसरा तर्क का प्रयोग करेंगे: सी = त्रिल (ए, -1); आउटपुट है: सी = 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.28 0.00 0.00

php - Mocking an Eloquent Model -

I have really seen through hundreds of pages, and I do not know how my position differs from work I have found examples on these pages. I am using the latest Mokery from LARVEVER 4.2, PHPUnit 4.3.1, and composer. I am running a PHPUnit test on my controller, operator, and I want to stop to save an enlightened database while joking the model. When I do not have any errors throwing while making fake, fake also is not related to my model, so even now the rows are being created. What am I missing here? Thanks! My error with jokes: joke \ exception \ InvalidCountException: Mockery_0_EventRsvp should save the method (save) 1 times, but 0 times should be called. // /app/tests/app/AppControllerTest.php class located in AppControllerTest TestCase Extended {Public Function Setup () {parent :: setup (); Session: start (); Mail :: play (); } Public Function TireDown (originally: Tyrardown (); \ Mock :: pass (); } Public function testPostApp () {$ myvar = array (); $ This- & gt; ...

ios - ABNewPersonViewController to save contact locally -

I have seen everyone else somewhere else and I think what I am trying to do is not possible. I am thinking that it is possible to use ABNewPersonViewController to make any person and save it locally (either in the address book or not as a file). Or anyone else is also aware of an open source library. That's the manual I've created manually for filling a person object currently I'm writing it to a similar class from scratch ... but if I am thinking I'm rebuilding the wheel - (zero) newPersonViewController:. (ABNewPersonViewController *) newPersonView didCompleteWithNewPerson: (ABRecordRef) person; {If (person) {ABAddressBookRef Address Book = RF = ABRendresBook with option (zero, zero); BOOL result = ABAddressBookRemoveRecord (addressBookRef, person, NULL); If (result) {BOOL SAVE = ABDressbook alert (address book, RF, tap); If (Save) {NSLog (@ "Successfully Delete"); }}} [Self. Navigation Controller PopWebControllerUnited: Yes]; } and extract in...

jquery - Ready event that takes place after dom has loaded but before the user can see the dom -

I am using a window or document ready function, that is, in some browsers, the user can see the DOM The page is loading while being manipulated. For example, if I was drawn to prepare an element in the window, then the user can see the image load first, then be removed. I understand that I can hide everything in the CSS and after that I can show it after executing my code, but in reality it is not the solution I am looking for. And it does not always work for one, because JS is asynchronous, there is no way to know that after the end of all other domain joints, your show's function is going to fire. Basically what I want is a function that works like a document / window ready, except that before the DOM is visible before the DOM is loaded, but it appears Before - this happens when I want to manipulate me There is no such event that you Are looking for . It is called one. A Google search will show you more techniques. However, the most common way with JQuery is to jus...

c# - Insert image to local SQL Server database in ASP.NET -

I want to add an image from the local SQL Server database in ASP.NET to FileUpload . I have many read the same question, but they did not help me: ( int length = FileUpload.PostedFile.ContentLength; byte [] picSize = new byte [ length]; HttpPostedFile uplImage = FileUpload.PostedFile; uplImage.InputStream.Read (picSize, 0, length); SqlCommand comm = Insert new SqlCommand ( "[table] (name, image) values ​​(@Name, @Picture) in" thief); com.Parameters.AddWithValue ( "@ name", TextName.Text); com.Parameters.AddWithValue ( "@ picture", picSize); com.ExecuteNonQuery (); So if I just add the column name - OK, but whenever I want to add an image to the database Mr. I do not fault: A type of exception 'System.Data. In SqlClient.SqlException' System.Data.dll but user code Additional Information Was not handled: Type the wrong syntax '. Picture' in my local database image in a image in the keyword. Please help me. You h...

css - How to create a data:application link for a web font? -

Since web fonts have some in-in-out connection with crow-domain hosting, a developer for a crowd Code provides clients who want to use such web fonts to take advantage of the beauty of their beauty, especially when trying to expand the technical steps to host a file can be challenging And make sure that Uarel path is pointing correctly on the Recently, I came across a Vebfont which data: application / font-Vif; Charset = UTF-8; Base 64 uses "Lambhash" Naming and I'm not aware of this. One of the major advantages of this is that it seems that it does not have the cross-domain loss to use the URL for the URL. Font, example here: If you can see this link, then you can see that it is a series of Alphanumeric characters, where the length is quite long. I wonder, how does one make such a way? Help is always appreciated! There is an encoding scheme for base 64 binary. You can use a decoder to get binary content of alphanumeric text coming after base64,...

json - How can I use Jackson mapper for java.io.Serializable type fields? -

I have a situation where POJO extends an intangible super class, which is getId () And setId () using the java.io.Serializable type (the code shown below). Whenever I deserializing JSON string to its solid POJOs, I except the following: thread "main" com.fasterxml.jackson.databind.JsonMappingException exception: do not build say Java Can. Iio.Serializable, Problem: Abstract type should either be mapped to concrete type, custom deserializer, or [source: java.io.StringReader@6fd90825; To be instantiated with additional types of information; Line: 1, Column: 2] com.fasterxml on (through the reference range: com.demo.jackson.AClass [ "id"]) com.fasterxml.jackson.databind.JsonMappingException.from (JsonMappingException.java:164) On. Com.fasterxml.jackson.databind.deser at com.fasterxml.jackson.databind.deser.AbstractDeserializer.deserialize (AbstractDeserializer.java:140) at jackson.databind.DeserializationContext.instantiationException (DeserializationConte...

C++ pointer to class method -

मुझे कुछ ऐसा करना है: struct cLI_Command {CLI_Command (char * s) , शून्य (* एच) (शून्य)) {command_string = s; हैंडलर = एच; } चार * आदेश_स्ट्रिंग; शून्य (* हैंडलर) (शून्य); }; वर्ग सीएलआई {सार्वजनिक: सीएलआई (); निजी: CLI_Command cli_table [NO_CLI_COMMANDS] = {CLI_Command ("कमांड 1", हैंडलर 1), CLI_Command ("कमांड 2", हैंडलर 2)}; शून्य हैंडलर 1 () {}; शून्य हैंडलर 2 () {}; }; मुझे पता है कि मुझे CLI :: * हैंडलर के समान कुछ की आवश्यकता है, लेकिन मुझे सिंटैक्स अधिकार नहीं मिल सकता है। मैं इस तरह की त्रुटियों में चल रहा हूं: "त्रुटि: कॉल करने के लिए 'CLI_Command :: CLI_Command (const char [4], & lt; अनसुलझे ओलोडेड फ़ंक्शन प्रकार & gt;) कोड> यह सही वाक्यविन्यास दिखाता है: class CLI; संरचना CLI_Command {CLI_Command (char * s, शून्य (CLI :: * h) (शून्य)) {command_string = s; हैंडलर = एच; } चार * आदेश_स्ट्रिंग; शून्य (सीएलआई :: * हैंडलर) (शून्य); शून्य बढ़ा (CLI * the_cli) {वापसी (the_cli- & gt; * हैंडलर) (); }}; वर्ग सीएलआई {सार्...

python - Trying to find follower count in Instagram API -

I followed like to find love count for a particular user if you were using Instagram API Console m: instagram.client import InstagramAPI ACCESS_TOKEN = "access token" API = InstagramAPI (ACCESS_TOKEN = ACCESS_TOKEN) user_info = api.user (user_id) Print user_info "Data": {"username": "data": "i.e.", when I am using the user_id search API console {"meta": {"code": 200} IGname "" Bio ":" Comment, "Website": "http: // instagram," Profile_picture ":" photo "," FULL_NAME ":" IGRealname "" counts ": {" media "Number 1," followed_by ": No. 2," follows ": No. 3}," id ":" IGUserID "} I want to follow the user name with field to output the dragon, as follows, and after that. All I'm getting is the username and that's it. You can use this: user_followers, next_ = ...

sql - MySQL join 4 tables -

I have a problem connecting to 4 mysql tables for my call management. My tables are: Call: callId | ContactId | Company ID Numeric | Timestamp | Call Note | Period. State Contact: contactId | First name Last name | Company ID Email | Contact note number: Number ID | ContactId | Number companies: Company ID | Company name I need a query that gives me: callId | Timestamp | Period. Number | Call Note | State | ContactId | First name Last name | Company | Email | I think this is possible, but I do not know how. try it select o.callId, o.timestamp , O.duration, o.callNote, o.state, o.contactId, j.firstName, j.lastName, j.company call company, JEmail, J. ID as contact note, rnm; O Skip to external contacts, contact j.contactId = j.contactId j.contactId = r.contactId;

authentication - Nginx: Grant access by comparing a header value with the contents of a file; possible? -

Text after " I have access to some stable file by comparing a custom header value with one example Actually I want to generate such a token in another (restricted) application and Nginx denied all requests with non matching header and header values ​​(token). What I have read so far, along with it is possible that it is possible to enlarge the Engex writing Lea code. But I have no idea that my idea is working on any occasion. So, what is a simple solution using the standard NGNX module (Favorites)? Or re-install / module mentioned before, is the Lua module installed by nginx compilation including its own chance? You can easily do so by checking out the docs by Lua, as mentioned by Aki All you need is - just enter your logic in the request stage, such as: location / {lua_need_request_body on; Client_max_body_size 100k; Client_body_buffer_size 100k; Access_by_lua '- Check the customer's IP address in our black list if ngx.var.remote_addr == "132.5.72....

linux - command line arguments to docker run -

I'm slowly trying to create a dock image for my needs What I want to do, my original image Mono is run, and then Mono runs executable in the background. From the normal command line, without trying to run it in the container, it will look like this: / usr / local / bin / mono /home/crystal/downloads/backgroundProcesser.exe & amp; It works fine but if I try to do this then when I run the container: Sodu Docker Run-i -T Crystal / Mono-Base / USR / Local / Bin / Mono / Home / Crystal / Download / BackgroundProceaseer EXE & amp; I do not get any such file or directory . Is there a way in which I have the & amp; Can I pass ? After all, I & amp; To run this background picsocer in the background, and then run the second app in the foreground. I saw this post for a different solution, but I thought I can run some stuff from the command line to prove the concept material for my app. Use bash to give the -c option to the command line as a string: Sudo...

enthought - What directory should packages/modules be written to? -

जीएलपीके (से) से स्थापित करते समय, मुझे निम्न त्रुटि मिलती है: libtool: install: / Usr / bin / install -c .libs / libglpk.36.dylib /usr/local/lib/libglpk.36.dylib install: /usr/local/lib/libglpk.36.dylib: अनुमति अस्वीकृत मैंने अन्य स्थानों पर सफलतापूर्वक स्थापित करने का प्रयास किया है, लेकिन अजगर को पैकेज नहीं मिला। मैं भागना चाहूंगा नोट: मैं मैग ओएस एक्स संस्करण 10.9.4 पर अजगर चलाने के लिए एनगॉट कैनोपी का उपयोग कर रहा हूं। आप डॉन पायथन में एक गैर-अजगर पैकेज स्थापित नहीं कर सकता आप इसे अपने सिस्टम पर स्थापित करें (कोई अजगर समस्या नहीं, शायद किसी और के पास कोई सुझाव होगा), और उसके बाद एक अजगर पैकेज स्थापित करें जो इसे "लपेटता है" - इसे अजगर में पहुंच प्रदान करता है यदि आप पहले से ही सफलतापूर्वक जीएलपीके स्थापित कर चुके हैं, तो आपको कैनपी टूल्स मेनू से एक कैनोपी टर्मिनल विंडो खोलने में सक्षम होना चाहिए, और टाइप करें: pip install glpk संपादित करें: ऐसा लगता है कि इसका उपयोग करने के उदाहरणों के लिए यह सबसे अच्छी जगह है:

c# - Re-defne a Paragraph Range to Include a Subset of Words in the Paragraph -

I am using Microsoft. Interp. To create a Word document for the Word / C # program. In a given paragraph, I need to change the color of the words between "[" and "]" The words are variable. As I understand, I need to set a color to set the color I am using the following code, which does not work: // paragraph Add. Microsoft.Office.Interop.Word.Paragraph pgf = document.Paragraphs.Add (); // Enter the text in paragraph. Pgf.Range.InsertBefore ("JIRA Issue:" + jiraIssueId + "[" + statusName + "]"); // Get the starting and ending locations of brackets. // These will define the location of words on which I will apply color. Int startPos = pgf.Range.Text.IndexOf ("[") + 1; Int endPos = pgf.Range.Text.IndexOf ("]") - 1; / * Limit is an attempt to change the position of start and end, so there are only words between the brackets in the range. I have tried two ways * / // The following line does not work. Pgf.Range...

spring - disable (or change port) for web interface of neo4j embedded? -

I have several small web service projects that use embedded neo4j 2.x. Any combination of them can be deployed in a tomcat insent, and therefore I do not need all the efforts to start the web service on port 7474. Acceptable solutions either disable the web interface on them, or use each one separate port, whether the first option is possible through spring configuration? if so, how? I have tried with a config map: & lt; Util: map id = "config" & gt; & Lt; Entry key = "enable_remote_shell" value = "wrong" /> & Lt; Entry key = "org.neo4j.server.webserver.port" value = "7475" /> & Lt; / Util: map & gt; & Lt; Bean id = "graphDbFactory" class = "org.neo4j.graphdb.factory.GraphDatabaseFactory" /> & Lt; Bean id = "GraphBiblebuilder" factory-bean = "graphfbffifter" factory-method = "new embedded database builder" & gt; & Lt; Construc...

javascript - How to correctly wrap a one time jquery call inside an AngularJS directive? -

मेरे पास एक सरल निर्देश है, जो रूपांतरित करता है & lt; एक कारसिस्टिकिज़ = "विशेषताएं"। "& gt; & lt; / a & gt; सही मूल्यों के साथ अधिक विस्तृत टैग में: template.html & lt; a ng-href = "regles # {{Caracteristic.name | lowercase}} "class =" ui मिनी {{caracteristic.color}} लेबल "डेटा-शीर्षक =" {{caracteristic.name}} "डेटा-सामग्री =" {{caracteristic.description}} " & Gt; {{caracteristic.name | | अपरकेस}} & lt; / a & gt; यहां निर्देश है: 'सख्त प्रयोग'; Angular.module ('myApp')। डायरेक्टिव ('कारेंसिस्टिकिस', फ़ंक्शन () {रिटर्न {templateUrl: 'components / caracteristic / caracteristic.html', प्रतिबंधित करें: 'ईए', दायरा: {caracteristic: '='}, प्रतिस्थापित करें : सच, लिंक: फ़ंक्शन () {$ ('। Mini.label')। पॉपअप ({ट्रांज़िशन: 'फीड अप', विविधता: "बड़ा"});}};}); तो मूल रूप से मेरे मॉडल में बदलाव नहीं होगा और अगर मैं ...

error handling - Correct way to respond to client on Node.js? -

This is my first attempt on creating a server ... I have installed a server Handle contact form submissions, including predefined captcha strings. When the server receives a contact form, then the captcha string is expected, so I want it to be only JSON response.end (JSON.stringify (parsedURL) of the parsed contact )) Using the query form; If the captcha string is wrong, then I want the server to say "Captcha" was incorrect, so ask the client user to try again. But I do not know how to do it. On the server: var httpServer = http.createServer (function (request, response) {if (/// contactform \ ?. ..... /. Test (request.url)) {var parsedURL = url.parse (request.url, true); var name = parsedURL.query.name; var email = parsedURL.query.email; var topic = ParsedURL.query.subject; var Inquiry = parsedURL.query.enquiry; var CAPTCHA = PERSEAD URL.query.captcha; if (CAPTCHA! == "TEST") {// Send a "bad" response to the client and message "bad...

jquery - Call javascript function multiple times -

Therefore, I have some problems finding a way to solve this problem. I know that it is silly , But I'm really stuck on this. I have something like this: & lt; Div class = "tdate" & gt; Sat October 11 01:11:01 +0000 2014 & lt; / Div & gt; & Lt; Div class = "tdate" & gt; Sat October 11 01:10:44 +0000 2014 & lt; / Div & gt; & Lt; Div class = "tdate" & gt; Sat October 11 00:51:03 +0000 2014 & lt; / Div & gt; and this javascript function: function parser date (tdate) {var system_date = new date (date.ps (tdate)); Var user_date = new date (); If (K.E.) {system_date = Date.parse (tdate.replace (/ (\ +) /, 'UTC $ 1')}} var diff = Math.floor ((user_date - system_date) / 1000); If (diff & lt; 20) {return diff + "seconds ago";} (diff & lt; 40) {return "half minute first"; } If (difference and LT; 60) {"less than a minute ago";} (diff & lt; = 90) {retur...