Posts

Showing posts from January, 2010

subprocess - How do I spawn a shell sub-command, with its stdout bound to the parent's stdout in python -

I want a Python program to underlay Shell sub-command, as well as be written to the stdout of the shell stdout Python's parents have been Python scripts will be run as CGI so Shell output should be sent back to the browser. As is said (emphasis my) stdin, stdout And specify the stderr execute program handles standard standard standard output and standard error file, respectively valid values ​​are PIPE, an existing file descriptor (a positive integer), an existing file object, and none. Pipe indicates that a new pipe should be made for the child. With no default settings, no redirection will occur; The child's file will be inherited from the handle, parental. Additionally, stderr can be STDOUT, which indicates that the stderr data from the hair process as stdout should be captured in the same file handle. /P> Therefore, it should be as easy as subprocess.call (["your_shell_command", / * command line argument, if any / code> example sub...

VBA recordset issue -

Why is it that if the number in the bracket is more than 1272, then the function returns all NA values. However, if the number is less than 1273, then the function works fine. set db = open database (dbf -name) rs = db.OpenRecordset ("SELECT * FROM SGXIO_Database") Variable variation in dim arr as slow dim variable counter variable variant Number as integer r.moveLast counter = R. RecordsCount RMEEFest 'is the name of the BEd Function BDD = Appraisation. Tranzas (R. Gatoro (1272)) Set RS = None DB Closed set db = nothing Perhaps because the ADO is useless in all types of memory limits And runs, you will not expect. Maybe you can solve it your problem. Just process 1,000 records at a time to use the second parameter of GetRows to tell where you left the last time.

How to apply multiple function to data.table in R -

I tried to: dt But does this error, so there are ways to do this? Thank you Use lapply in other codes in the same context: ANS & lt; - DP [, lapali (SD), function (x) meaning (x) / sd (x)), = 'id'. SDCL = Name (DT) [- 1]]

google app engine - Datastore Query returns null -

I am trying to get a sorted list of scores of players with a datastore after executing "user" type Unit of: list & lt; Users & gt; Institutions = ofy (). Load (). Type (User.class) .order ("- score"). List (); By knowing that I have indexed the "score" attribute here "user.class" @ id string user name; String password; @index int score; Organizations appear to be futile and I can not get the details of institutions. What am I missing? I am still working on what I have succeeded on: Modify this method: @ Override public user performance } {List & lt; Users & gt; List = ofy () Load (). Type (User.class) .order ("- score"). Range (5) .list (); User U = list.gate (list.size () - 1); Return (! U.getUserName (.) Equals (empty)); Return tap; } I'm getting rid of the "empty" value by checking the username field, but the return value was always the first user in the unit, no matter how much I...

java - Can Find the error -

Then my Java online class, I must include the variable and provide the set and of course get the name of the instructor's course. Welcome to the grade book for: How to get the methods, and to display the message: And this course has been presented by: Class gradebook: public class gradebook {personal string string name; Public String Course Teacher; Public gradebook (string name, string teacher) {courseName = name; Course Teacher = Teacher; } Public ZeroServer Name (string name) {courseName = name; } Public string getCourseName () {return courseName; } Public Zero Setchers Teacher (String Teacher) {Course Teacher = Teacher; } Receive public stringTeker () {return course teacher; } Public Zero Display Message () {System.out.printf ("Welcome to the Book of Grade: / n% s! \ N", getCourseName (), "This course is presented as: \ n % S \ n! ", GetCourseTeacher ()); }} Main category: import java.util.Scanner; Public grade gradebook {public static zero ma...

lotus notes - Remove database reference from workspace -

I am struggling to find an answer in this one or the other, but do I affect the workspace from LotusScript Can i I am developing the Lotus Notes application which opens the other Lotus Notes database, although each time one of them is opened, it leaves behind the scrapping reference on the workspace. Is there any way that I am being made a Regenerator, it has been created once, or has a user's work area removed through a Domino policy? There is an alternative argument in the text "itemprop =" text "> NotesUIWorkspace.OpenDatabase () (see the document and note the 'temp' parameter) to prevent you from adding the database Workspace can be used.

javascript - How to close show button on click? -

$ (दस्तावेज़) .ready (function () {var $ p = $ ('div.striker') ; $ ("# शो")। क्लिक करें (फ़ंक्शन () {$ p.css ('अतिप्रवाह', 'दृश्यमान');});}); क्लिक बोनस पर कैसे बंद करें ??? HTML & lt; div class = "striker" & gt; यदि आप "छुपाएं" बटन पर क्लिक करते हैं, तो मैं गायब हो जाएगा। यदि आप "छुपाएं" बटन पर क्लिक करते हैं, तो मैं गायब हो जाएगा। यदि आप "छुपाएं" बटन पर क्लिक करते हैं, तो मैं गायब हो जाएगा। यदि आप "छुपाएं" बटन पर क्लिक करते हैं, तो मैं गायब हो जाएगा। यदि आप "छुपाएं" बटन पर क्लिक करते हैं, तो मैं गायब हो जाएगा। यदि आप "छुपाएं" बटन पर क्लिक करते हैं, तो मैं गायब हो जाएगा। यदि आप "छुपाएं" बटन पर क्लिक करते हैं, तो मैं गायब हो जाएगा। यदि आप "छुपाएं" बटन पर क्लिक करते हैं, तो मैं गायब हो जाएगा। यदि आप "छुपाएं" बटन पर क्लिक करते हैं, तो मैं गायब हो जाएगा। & Lt; / div & gt; & Lt; बटन आईडी = "शो" & gt; दिखाएँ ...

sql - cognos 8 - how to get a set of more sets -

I have created a report, and have encountered some problem I have a course reference number which has many classes and the meeting The type of course is a reference number in the reference number, for example course reference number meeting type 12345 class 12345 exam and some courses Reference number does not contain Itemprop = "text"> Spun that just a [Meeting type] that this "class", and two "class", "test"? If so, create a data item that counts ([meeting type]). After this, make a brief filter where counting ([meeting type]) = 1 If a course can have a [meeting type] that is a "class" or "test", then I Two questions. It can not be done in only one query (without the use of custom SQL) Conceptually, the first type of course is "Examination" type of course, the second question is that all courses connect them using the "leaving" operators in the toolbox.

database - how to use OleDbDataReader -

I am totally new to vb.net, I am trying to create a database connectivity using the access database I am Everything goes well, but whenever I create an object of OleDbDataReader it shows an error. OleidiDidder is not available in this context because it is 'friend' Here is my code: New OleDbConnection con = new string as OleDbConnection (connectionString) string = "My query" Dim cmd New OleDbCommand (Query, con) con.open () New as a reader in the form of dim ODDDITER // here as a reader Uti comes. Read () is the end of my code while my import import system.Data.Oldibi Anyone can tell me where I am wrong . --text "itemprop =" text "> You can not create a reader by yourself - a command object For your: Dual CMD in the form of new OLED COMM (query, choice) con.open () dim reader = cmd.ExecuteReader () while reader.read ()

sql server - Take Average of two columns sql -

Select the age; average (shoes size) from (dbo) [Transactions] T2 Where t2.age = T 1. Edge and T2. Childgen = 'Male') In avg_male, select average (shoes size) from [dbo]. [Transaction] T2 where T2ege = T1 .ge and T2. Childgender = 'female') avg_female [dbo]. [Transaction] T1 Group Age ORDER Age Hello, I have two columns, and I know how I take the average of two columns and displayed in the third part I would. Please help Just use simple math: choose Edit with avg_male, avg_female, (Avg_male + avg_female) / 2 transactions: I think this should work. Not a SQLFiddle, but it should: Select the age, the amount (case when childgender = 'male' happens then zero to the rest 0) / zodiac (in case when the child-gender = 'Male' then 1 Avg_male, avg_male, avg_male, avg_male, (sumg_male), sum (in case when hair-gender = 'female' then shoe size and 0 end) / zodiac (case when child-gender = 'Female' then 1 and 0 in the form of av...

jquery - Knockout Js - ko.utils.arrayFirst does not work -

I have the following knockout code I try to return the food each line This function takes ID of current available mileys - and should return some object self. Function (item) {return item.id == id;}); }; & Lt; Span data-bound = "text: $ root.getMealById (meal.id)" /> For some reason he did not do this, why? array first will return an object and you will place an object in the input field Trying to bind the text value, which will not work. If your function is a string value, it will work fine, updated bella here: New function To get the name of the food as the value, note the .emailName; at the end of the array self.getMealNameById = function (id) {var meal = ko.utils.arrayFirst (self .availableMeals (), function (item) {Return item.id == ID;}). Nickname; Meal of return; }; In addition to this, the data-dam has been updated to input to use the new function: data- Bind = "Value: GetMealNameById (1)"

c# - how to take the part of a string -

मैं इस स्ट्रिंग का एक हिस्सा कैसे ले सकता हूं: string = "& lt; ArrayOfArrayOfKeyValueOfstringstring Xmlns: d1p1 = "http://www.w3.org/2001/XMLSchema" i: प्रकार = "d1p1: base64Binary" xmlns: i = "http://www.w3.org/2001/XMLSchema-instance" xmlns = "http://schemas.microsoft.com/2003/10/Serialization/Arrays" & gt; 0RuHA6OkPMP7myQPAR4ZDMoB8mo = & lt; / ArrayOfArrayOfKeyValueOfstringstring & gt; "; मुझे इस भाग को "0RuHA6OkPMP7myQPAR4ZDMoB8mo" लेने की आवश्यकता है, मैं प्रोग्राम को किस प्रकार भाग की आवश्यकता कर सकता हूँ? यह एक XML नहीं है, इसकी स्ट्रिंग प्रणाली मुझे दे रही है वापस जब मैं टेलीफोन के ब्योरे पूछता हूं, मुझे केवल आईएमईआई का हिस्सा प्राप्त करने की आवश्यकता है: वस्तु obj = DeviceExtendedProperties.GetValue ("DeviceUniqueId"); बाइट [] objByte = ऑब्जेक्टटैबेटअरे (ओबीजे); IMEI = System.Text.Encoding.UTF8.GetString (objByte, 0, objByte.Length); यह ऑब्जेक्टटॉबेटअरे (): निजी बाइट [] ऑ...

dblink - Scheduling a job in oracle to drop and create table -

I am trying to delete and create a table using a scheduled job. How do you do this? drop table registration; You are probably looking to obtain physically, select the table entry * Registration_mv @ D3PROD_KMDW to View instead of table? Create physical visual registration in the form of registration * MV @ d3prod_kmdw as registered * registration and then refresh it in the job dbms_mview.refresh ('Registration'); This is better than leaving and making the table because PL / SQL objects will be invalid after leaving the table. With Mview it will be silent and without loss

c# - Asp.net web api routing issue? -

I am using Web API in my MVC application. I have a problem when calling the Web API using the Jquey.get function. Consider the following scenario: I have 2 controller names: Home MVC controller Li> / li> TestApi controller has 1 operation Received When I am indicating the homemcc controller The view was on > http: // localhost: 1025 / home and when I call $ Get the expected Jason response from the Get ("api / testAPI / get") browser. But when I call homemcc controller ie http: // localhost: 1025 / Home / About I $ Get the error from the browser ("api / testapi / get") , the resource is not found, and to find out what the resource is trying to do: Http: // localhost: 1025 / home / about / api / testAPI / get instead of http: // localhost: 1025 / Why the About Home / was added to the API in the AP I / TestAPI / get URL and why it was not added Home / Index See when I was on the index view...

Excel to MySQL dec2hex -

I need help in swapping Excel formulas in the MySQL formula. I have the following number which will be in the column called DEC = 005341009450614 I have to break it into three parts and make DEC2HEX conversions on each and insert the result. I can do this in Excel: = CONCATENATE (DEC2HEX (MID (A1,1,5), 4), DEC2HEX (MID (A1,6,2), 2), DEC2HEX (MID ( A1, 8,8), 6)) My question is how can I repeat this in MySQL? I have tried: SELECT CONCAT (hex (SUBSTRING (`DEC`, 1,5)), hex (SUBSTRING (` DEC`, 6,2) but it gives me "303032373830373039343430333437" where the result should be Should: "02160A903476" Thank you for your help! In MySQL, just change the hex to any integer, simply HEX Function: SELECT HEX (& lt; number & gt;); The input parameter is a BIGINT or a string, so that it is enough for a large number.

css - DOMPDF background color and image issue -

I got some issue with background in the DOMPDF. Please assume an element with both a color and image background. When I try only with color or image, both works but when I want to, both, the background image works but the background color is black. I tried these syntax: Background: # ff000 url ('path / to / image'); // or background color: #FFFF; Background-image: url ('path / copy / image'); The result is the same I tried to check the HTML render without PDF and obviously it works. Element is a div picture is a transparent PNG. EDIT: After this post I thought of something: Does the IPDF also support transparency in PNG for background? dompdf v0.5.1 Alpha does not support transparency Most recent release () does, as you do Can see here.

java - How do I break down a large merge with conflicts into more manageable chunks? -

I maintain a large GIT repository with 50,000 files in it. The main line development branch is called "development". I have a branch called "feature" which is working almost independently for about 5 months, due to the complexity of work it is not possible to merge with "development", but Now it is close to completion, it wants to re-sync with "development". Usually this means that "in the original / evolved" feature "fix", fix conflict, test, commit, and push but there is a large number of disputes in this merge point. That ~ 4000 changes in mergers and ~ 450 unused changes Some of these conflicts are quite trivial (eg, giltinger files and so forth) but many concrete rewrites and difficult to solve In addition, these conflicts have been crossed over different software domains. Developers of each domain must resolve the conflicts in their own areas. It will take several days for at least a concerted effort to remove an...

performance - JavaScript: Is it is possible to preload external sites? -

I could not find an answer to this special question on stack overflow. Not particularly looking for an implementation (unless it already does not exist), but ... I have an intranet app that loads very quickly, with many external sites There are links to, all of which we can assume to load slowly, the user will definitely not do this by going to all the links on the page (we do not but it is unlikely that They are the first ten seconds Itr loading open a linked page). Before clicking on a link, would you like to start downloading these external links without opening a new window / tab? I've noticed that there is such a capability, but especially against external sites (or, sites with different CSS / JS files) are warned against loading Anyhoo, what with JS Is it possible to start an external site caching (or anything else for that matter)? Would it be possible, say, to load the HTML page first but not to fix any associated CSS / JS files. Click OK. Even if it is an on...

java - Table/Report Format Using PDFBox -

I am formulating issues with the PDF box. My goal is to print the PDF in table style format as a report. Content format will be similar to name code description value , Retrieve the result set and I have a list of Java objects. I extract the required information and format them as the list of stars in the form below. I create circles through objects, construct a string and add them to an arrayList that I have to implement the formatting in PDF I am making a list of exact same length / style strings. (MyObject obj: dbresults) {// format as below and add to list} StringBuilder sb = new stringbilder (); Formatter Format = New Formatter (SB); Formatter.format ("% - 25.25s", "It has some text with more than 25 characters."); Formatter.format ("% - 25.25s", "some text with less."); Formatter.format ("% - 25.25s", "some other text."); Println (formatter.toString ()); Output: | This is some text with Mo. At least t...

gcc - throwing away tens & hundreds columns of an int in C -

I want to test an integer value for my unit column value, I do not care about tens or hundreds of columns. The int value is a countdown timer So when the units column is 0 to 4, I want to display something in the screen, when the units are from 5 to 9, then I want to show the screen a bit more. I basically want to separate the units column value without thinking of dividing by 100, one can not think of a quick and dirty way to do this and reduce the number of 100 to 10 with the number . So far I am trying: int zero_count_units = a_zero_count - (an easy way to transfer and test for 0 to 4 or 5 to 9 in the unit column Is ((A_zero_count / 100) * 100) + ((a_zero_count / 10) * 10)); If ((zero_count_yats> = 0) & amp; amp; amp; amp; amp; (0x;) // 5-9 unit column {} My brain is not working very well this morning! Thanks very much any advice! You must use the % () operator for expression n and m n% m is separated by n . In your case m will be 10, because ...

Lower case all then capitalize - pure CSS -

इस सवाल का पहले से ही एक उत्तर है: 2 जवाब मैंने यहां यह विषय देखा है: लेकिन यह शुद्ध सीएसएस नहीं था। मेरे पास एक ऐसा डिवि है जिसमें यह पाठ होता है: & lt; div & gt; राउर आरएआरआर & lt; / div & gt; मैं इसे "रावत रावत" की तरह देखने के लिए सीएसएस का उपयोग करना चाहता हूं। कट अगर मैं सिर्फ पाठ-रूपांतरण को कैपिटल बनाने के लिए इसे "राउर आरएआरआर" बनाता है, तो पहले से बड़े अक्षर बड़े हैं। तो मुझे कम मामले की जरूरत है, पहले सभी को कैपिटल बनाना, यह डिव में लपेटने का समाधान है? मैंने इसे दूसरे डिवा में लपेटने की कोशिश की लेकिन यह काम नहीं करती: & lt; शैली & gt; # Test3 {text-transform: लोअरकेस; } # Test3 div {text-transform: capitalize; } & Lt; / style & gt; & Lt; div id = "test3" & gt; & lt; div & gt; राव आरएआरआर & lt; / div & gt; & lt; / div & gt; दुर्भाग्य से, आप यह शुद्ध सीएसएस के साथ नहीं कर सकते। अब आपकी सबसे अच्छी उम्मीद है कि मध्यवर्ती / अंतिम राजधानियों से बचने या ज...

c# - Starting up several programs at once -

I have written a small program (processed) to launch another program that is defined in .txt file ( new line ). The code is mostly taken from MSDN. I am just starting my programming adventure but I want to write something useful. I do not know how smart it is to run two programs simultaneously from my processesmemployment program. In my .txt file, I have the path to the program with .exe. It is working fine but my program is running a program only at the time. I thought I would run forward, but of course it will not work here because it runs the first program and as long as I do not exclude it, then it waits, then it will run the next part. So I know the reason why this is not working, I just want to know how I would like to work it. My C # code: using the system; Using System.Diagnostics; Using System.Threading; Namespace process sample {class process monitor sample {public static zero main () {Console.BufferHeight = 25; // Define variables to track extreme memory usa...

Java program is still running. How to stop? -

I wrote an application to use sftp-client. In the main method, I am calling a method that downloads a file from a sftp server when the file is downloaded, the program is still running. How can I stop it? public static zero main (string [] args) {downloadFile (); } Use System.exit (0) Download DownloadFile () inside the method, is complete. SidNote : Make sure you resolve the resources and closed buffers before doing this.

html - CSS: How to center element that is bigger then the container? -

I have an element of 800px and the container is small (it is responsive so that the width is changing), I have such a code : & lt; Div id = "container" & gt; & Lt; Div id = "popup" & gt; & Lt; / Div & gt; & Lt; / Div & gt; and CSS: # container {width: 400px; Status: Relative; } #popup {width: 800px; Status: Completed; } I tried left: 0, right: 0, margin: auto; But it is not working Box is aligned to the left. / P> here You can use margin-left: - ( Half width) PX and left: 50% Then your code popup css code will look like this: #popup {position : Absolute; Width: 300px; Background-color: # 0a; Height: 20px; Top: 100px; Left: 50%; Margin-left: -150px; Z-index: 100; }

Launching QTP after key-in the logon detail -

I am trying to launch the QT using VB code below: Dim qtpApp set QtpApp = CreateObject ("QuickTest.Application"). QtpApp.Launch This was working in some other environments, but in my existing environment when I used Key-in logon Details will be opened in That is, if we click on the QP Shortcut / QTP icon from the Laupe bar, then it will open some prompts for the initial username and password. After completing the initial screen of that quick ONT KTP. My code above does not include this logon description, I tried for many possibilities and searched for the log. But it can not be made possible, so please help with it? go to File->; Enable automatic login by providing ALM / QC connection and required c credentials. Enable 3 checkboxes in this window too.

javascript - How to extract the value passed in through onclick function event? -

I have an onclick = "ShowSingleNew (299)" event for this one link Opens a new popup, what I would like to do is to remove 299 (which is an id of the given new item) and pass it to my PHP script so that the item belongs to that user Read The php bit looks like this: if (empty ($ _GET ['news_id'])) Select {SKL ..} and select {SLL} where News_id == $ _GET ['news_id']; } How can I pass this ShowSingleNew ID on the next page and give it in the $ _GET variable? Do you have to pass a news ID using the query string as the URL? NewsId = 104 format. The sample code looks like this in the original format: ShowSingleNew (newsId) {var url = "Your URL goes here"; Window.open (url + "? NewsId =" + newsId); // other code} On the php side, you can use $ _GET ['newsId'] to bring the News ID. Note: How many values ​​to pass in the query string here: Reference:

mysql - foreignKey in model based on condition in cakephp -

मुझे foreignKey अवधारणा से संबंधित एक मुद्दे से मारा गया है मेरे पास दो तालिका उपयोगकर्ता & amp; user_relations । उपयोगकर्ता उपयोगकर्ता के संबंध आईडी उपयोगकर्ता नाम आईडी user_id friend_id स्थिति 1 एबीसी 1 1 2 स्वीकृत 2 डीईएफ़ 2 2 3 स्वीकृत 3 जी 3 1 3 स्वीकृत यहां friend_id है foreign_key और मेरा user_relations मॉडल जैसा दिखता है सार्वजनिक $ BelongsTo = array ('मित्र' = & gt; सरणी ('className' = & gt; 'उपयोगकर्ता', 'विदेशी कि' = & gt; 'friend_id')); मेरी स्थितियां समान होंगी 'conditions' = & gt; सरणी ("OR" = & gt; सरणी ('UserRelation.user_id' = & gt; $ iLoggedUserId, 'UserRelation.friend_id' = & gt; $ iLoggedUserId,), 'ViewerRelationship.status' = & gt; 'स्वीकृत') अब जब उपयोगकर्ता "1" लॉग इन किया गया है, तो उसे उपयोगकर्ताओं की जानकारी मिल जाएगी "2" & amp; "विदेशी" के आधार पर "3" ...

oop - Polymorphism, what it is and what it is not -

इस सवाल का पहले से ही एक उत्तर है: 28 जवाब मैं oop पर काम कर रहा हूं अलग-अलग प्रोग्रामिंग भाषा पर, मैंने अलग-अलग मैनुअल का इस्तेमाल किया है और मुझे एहसास हुआ कि व्यावहारिक रूप से सभी ने बहुरूपता को अलग ढंग से समझाया, हालांकि मैं इसका इस्तेमाल करने के मामले में अपने सभी स्पष्टीकरण के साथ ठीक हूं लेकिन कोई भी इस अवधारणा को मनुष्य के सामान्य शब्द में समझा सकता है और व्यावहारिक उदाहरण के साथ अवधारणा धन्यवाद उत्तर की सराहना की विकिपीडिया से एक सीधे कॉपी पेस्ट है जो एक्सवि लोपेज़ उदाहरण समझाते हैं: "वहाँ बहुत सारे हैं। उदाहरण के लिए, यह एक शास्त्रीय है: एक पशु सांड () बना सकता है। मेक सैंड () को लागू करते समय कुत्ते की छाती होगी और कैट म्यूवू नामक एक अन्य Ound () विधि किसी जानवर के लिए अलग तरह से व्यवहार करती है, इस पर निर्भर करता है कि उदाहरण के वास्तविक उपवर्ग क्या है। ए???? ज़ावी लोपेज " अमूर्त वर्ग पशु {सार स्ट्रिंग बात ();} वर्ग बिल्ली का विस्तार पशु {स्ट्रिंग बात () {वापसी" म्याऊ! ";}} वर्ग कुत्ते पशु प्रदान करता है {स्ट्रिंग बात ( ) {Ret...

c++ - Error expected identifier before token "<" -

I'm starting in C ++. I have this header file, which is shared data. Is called. It has been given below. Add // SharedData.h # Shared_ptr is being defined in Shared_data.cpp so that I get a copy of the object in the memory and external declaration, wherever I I tried a lot, but I do not know how to solve this error. Please help ..... Regards, Techototí You must include the header memory .

linux - Fixing the line-endings in a Git repository using the `.gitattributes` file -

What's the need for fixing: I have a .md File, which contains an essay that I am writing to. I edit the file from some different computers, running a Linux and running a pair of Windows. Git diff Now in Windows, where I made some changes, I can show my essay as well as separate lines of text ... to be removed Everything has been replaced and replaced by a long line where the paragraphs ^ m s. I know that ^ M refers to Windows' CLRF line end Diff means that I have started the file (fully possible, I do not remember) in Linux and since then it has been saved in Windows and all The end of the line has been changed. D To be able to open files in both OSs, as they should be displayed, and displays a diff result, which shows the line breaks ( ^ M placeholders) and only the actual content changes. What I have tried: I did something, read line-endings and tried to follow the Geet settings, and even the commands. As it stands, I have a .gitattributes...

how to overlay a new div over entire body of HTML using Jquery? -

I have a problem similar to the post. During the Ajax request, I am trying to insert the background image of the loading icon and the background of the depth, any kind of gray background does not spread to the bottom of the page. As I scroll, it goes away. I had given suggestions in that post, but none helped, I thought about replacing a brand new device that covers the entire HTML and is deeply with loading the background. But I do not know how to do it. Make existing content invisible or with any help? Any help? Actually, you'll need the div which was hidden most of the time Is not better than display: any , and then you will call $ (".cover all"). Show (); When you want to cover the screen the styles for the div are below by z-index'ing, located above your remaining content, you effectively hide that content behind it. HTML: & lt; Div class = "coverAll" & gt; Loading ... & lt; / Div & gt; CSS: .cover a...

vb.net - Color-picker showing color names -

Detects color-picker for any Visual Studio (Visual Basic) Shows standard colors? For example, in Visual Studio, you can change the color of the control by using the color picker , which contains the tab of "custom" , "web" and "system" . the web & amp; System options show a list of color names, while custom supplies (primarily) RGB (which controls VB color picture). Thank you! is too short for any of these unless you are VS With the designated colors, use it as a popup or some such example background as the background: names the name of the private (_Colors) as the name of the string () to leave 'SystemColors leave the qualifiers Or 'need' function as the GetColorNames string (as for each) in the transparent colorName KnownColor.GetNames string (GetType (KnownColor)) as the _Colors.Add (colorName) end, then the next 'Post One CBO's name: cboBackColor.Items.AddRange (_Colors) If you set the DrawMode Ow...

c# - Parameterized SQL UPDATE command causes Declare Scalar Variable Error -

I am trying to run an UPDATE query that receives new values ​​from user input. As a practice in caution, I chose the parameterization but there should be an error in which the parameters in which stating the block is used to declare the scalar variable '@WF_IDUPDATE' according to the manufacturer to do this SqlParameter (string, object) should create a new parameter identified by the string and take the value of the value passed in the form of the object. There is a reference to updating the table's schema for you: ID integer not accepted NIT BIT NO nULL First NVARCHAR (255) No nULL Last name NVARCHAR (255) No nULL title NVARCHAR (255) Zero departmentID integer no nULL department NVARCHAR (255) No nULL timestamp DATETIME zero primary key (id) Here is the code related to the SQL query conn.Open (); SQL_Command.CommandText + = "Update WFMembers_Staging Set" + "= @Approved, [Accepted]" + "[First] = @First," + "[Last Name] =...

php - Regex not capturing properly -

Here is a query that I want to create an array of parameters: $ subject = "SELECT * a_table with WHERE something = 'col1 =: param1' and col2 =: param2 or col3 =: param3"; I tried: $ pattern = "^ ([\" ']) (?: (? = (\\\\?) ) \\ 2.) *? \\ 1 ^ "$ subject = preg_replace ($ pattern," "$ $ subject"); and $ Pattern = '# [:] [A-zA-Z0-9 _] + # '; preg_match_all ($ pattern, $ theme, $ matches); print_r ($ matches); Unfortunately, I only want to Param2 and param3 found as output I would like to see my dump like this: Array ([0] = & Gt ;: param1 [1] = & gt;: Ultimate 2 [2] = & gt;: param3) You can just use this regex = (: \ w +) $ query = "SELECT * to a_table Where some = '$ 1 = $; & I; $ I ++) resonate {$ params [1] [$ i]. "

c# - Index cannot be 3, only 0 or 1 -

This error code does not prevent it from running, but I would like to fix it. Here is the code, error appears under HtmlElementCollection rows = Y [3]. Get Elementsbaigenem ("tr"); Any information will be appreciated. doc.LoadHtml (content); Binding source datasource = new binding source (); Binding source data2 = new binding resource (); HtmlElementCollectionY = Web Browser 1 Document. GetElementsByTagName ("Table"); {HtmlElementCollection Rows = Y [3] .GetElementsByTagName ("tr"); thanks this HtmlElementCollection Y = Web Browser 1. Document. GetElementsByTagName ("Table"); Returns an array of tables, this array has only 2 items, so your index can only be 0 or 1. You can not w [3] because your array does not have 4th element.

java - Difference between abstract class with all method abstract and interface? -

I had an interview where the interviewer asked me first that all the methods between the intangible class are summarized and the difference with an interface What is it I replied that if there are some things to be successor in the future, then you will not be able to do this, if you have already increased the class. Then he said that it was a situation where no one would have to expand any other class and you have to implement a contract in this situation, which would be better, an abstract class or an interface? I told them that you can use any of them but they were not satisfied. I could not understand why - I believe it's a developer / design choice. Explaining that an interface represents an agreement, is not acceptable. This is the answer we give to Junior because it can be complicated to understand the difference without having much interface experience between abstract abstract and abstract of interface and without reading many classic books. Any abstract class...

ElasticSearch to search in MySql databse -

What is the idea of ​​using the database as a search server and ISA? I am putting in ES areas by which I want to link search and field to mysql (for example ID). When I execute the search in ES, I will get a list of IDs in mysql and then I will meet all the objects given by ISD by IID, am I right? If I correctly understand your question, then you should index the area that you You want to put 'search' in elastic search, along with a non-analysis primary key that will allow you to get the record. For the searches you searched for from the database, you can see the index settings To not by defining its PK , you can read about it. Another way to synchronize your ES cluster with your MySQL database, which means that any CRUED operation against your DB will be repeated in your ES cluster. If you have an eye on you then you can choose your DB at pre-determined intervals.

ios - How to replicate a sentence with line breaks in between with an NSString? -

I was changing some old UIWebViews with UILabels and I realized that I had a string that looked like the following: NSString * eaten = You ate & lt; B & gt;% @ & lt; / B & gt; % From This sentence was being called as: NSString * warning = [NSString stringWithFormat: eaten, "cake", "janine "]; It was displayed in this form: You were drawn from Jenin How do I do this Want to display. How do I add line breaks for NSString now? I have tried the following and they do all the work: NSString * warning = [NSString stringWithFormat: @ "% @ \ R% @ \ r% @ ", Ate," cake "," jenin "]; NSString * Warning = [NSString stringWithFormat: @ "% @ \ n% @ \ n% @", eaten, "cake", "jenin"]; NSString * Warning = [NSString stringWithFormat: @ "% @ \ r \ n% @ \ r \ n% @", eaten, "cake", "jenin"]; and self.warningLabel.numberOfLines = 0; But the outp...

javascript - Get all elements of a select tag -

I have two choices-multiple lists and I have to get all the elements of the correct list, if they are selected or No . Just let me know what's going on in my code You will see that I will only get back the data that has been selected which I am An attempt to do that forms the form with all the elements of the correct selection list. Note: $ ('. SubmitForm'). Click (function (e)) Required I can create a new function to do this and then click on $ ('. SubmitForm'). Click (function (e)) but it will create an extra step in the process So my question is actually if I in any way correctly create a new function for this box Without the right selection can get all the data from the box. And without changing the $ ('. SubmitForm') (Function (e)) which is being used by 8 different forms. Update On a second thought, I do not think I can click on $ ('. SubmitForm') Click (function (e)) from a new function so that additional problem ar...

r - Using Rcpp headers in C++ -

Trying to learn C ++, because I have seen the huge improvements you've been using using the C ++ code. Within R, I am trying to play with the RCPP library, and I have found examples to work in R. However, I would like to write some C ++ code in my C ++ Editor and get a better understanding of using the RCPP package) I tried to compile the following code in my C ++ editor (codeboxes): include & lt; /path_to_r/R/win-library/2.15/Rcpp/include/Rcpp.h> But then it fails because it can not be found in the first few lines of the following: % ... #ifndef Rcpp_hpp #define Rcpp_hpp / * It is important that it comes before / / # include & lt; RcppCommon.h & gt; ... Is there a better way to include all RCPP codes? Do I need to go through the RCPP file and replace all the files with my path? I know this is a new question, and I'm sorry ... I'm sure the answer is somewhere in the document, but I do not know how to find it. Thanks for the help! You can...

mysql - Aggregating a column by multiple date ranges in a single query -

मेरे पास 5 कॉलम के साथ एक MySQL तालिका है: डिवाइस | नाम | दिनांक | स्रोत | आय न तो डिवाइस और नाम और स्रोत अद्वितीय है। I निम्नलिखित के लिए एसक्यूएल लिखने की कोशिश कर रहा हूं: डिवाइस | नाम | स्रोत | आय (पिछले 3 दिनों के लिए) | आय (पिछले 9 दिनों के लिए) | आय (पिछले 12 दिनों के लिए) ऐसा करने का सबसे अच्छा तरीका क्या है? आपको सशर्त SUM () के माध्यम से मामला कथन प्राप्त कर सकते हैं: चुनें उपकरण, नाम, स्रोत, SUM (मामला जब UNIX_TIMESTAMP के बीच की तिथि (अब () - INTERVAL 3 दिन) और UNIX_TIMESTAMP (अब ()) आय के अंत में) Last_3_Days, SUM (केस के समय के बारे में दिनांक UNIX_TIMESTAMP (NOW () - INTERVAL 9 दिन) और UNIX_TIMESTAMP (अब ( )) THEN आय ईडीडी) अंतिम रूप से आपके डिवाइस के नाम से, स्रोत

node.js - Mongoose find all documents with a given ObjectId -

I have a photo model and each picture has a vehicle associated with it: Var object id = mongoose Sema Object ID; Var photoSchema = mongoose.Schema ({name: {type: string}, path: {type: string}, vehicle: {type: object, ref: 'vehicle'}}); What can I do to return all the photos matching the given vehicle _id ? I think the query looks like a normal search, but I'm not sure how to convert _id into an ObjectId. You do not have to change anything, your ObjectId The same is _id but in the string format when you send it anywhere via JSON try the following: Photo.find ({Vehicle: id}, function (fault, result) {...}); above id is just your vehicle 's user interface

Data truncated for column, but the data truncated is a empty C#/MySql -

I am trying to insert values ​​into a MySQL table via C #. My string is like CMD text to send MySQL to the last step: sistema1 (* some columns here *, Octitm, * here one more column *) in INSERT * (* value * The problem is set in column column, and the value that I am trying to input is empty. How can I fix this? Thank you! Solution 1: If your column AktivesTeam Supports NULL when you insert the values ​​you can skip that column. Try it: Skip the AktivesTeam Column name and value in sistema1 (COLUMN1, COLUMN2) value in INSERT (VALUE1, VALUE2); Solution 2: If your column does not support AktivesTeam then NULL Try it double value 0.0 try it: sistema1 (COLUMN1, AktivesTeam, COLUMN2 in INSERT) ) Value (VALUE1,0.0), VALUE2); To avoid SQL injection attacks Suggestions: / div>

emacs24 - How are the packages installed with 'package-install'(elpa) in Emacs loaded? -

/ em> > पैकेज-इंस्टॉल का एक हिस्सा है package.el - जो आप वर्णन समारोह के साथ देख सकते हैं package.el से प्रलेखन: ;; सक्रियण समय में हम लोड-पथ और सूचना पथ स्थापित करेंगे; ;; औ औ पै पै पै पै ेंगे ेंगे ेंगे ेंगे. यदि कोई पैकेज ;; निर्भरता उपलब्ध नहीं हैं, हम उस पैकेज को सक्रिय नहीं करेंगे. इसलिए प्रत्येक पैकेज में एक फाइल है NAME-autoloads.el और यह फाइल लोड हो चुकी (Setq package-user-dir) ~ / (पैकेज की आवश्यकता है) प्रत्येक पैकेज में पैकेज संस्करण के साथ NAME-pkg.el भी शामिल है और विवरण. उदाहरण के लिए, टैबबार पैकेज से संबंधित फाइलें हैं पैकेज-इंस्टॉल # जो कि मेरा पैकेज-उपयोगकर्ता-निर्देशिका है एक ??? ???? ???? एक टैबबार -2.0.1? # प्रत्येक पै ेज डायर अलग-अलग डायरेक्ट में है. Tabbar-autoloads.el # इस फाइल को शुरू में लोड किया गया है ???? ???? ???? ???? Tabbar.el # पैकेज खुद इस मामले में यह सिर्फ एक फाइल है, जो कि एक "????" ???? पैकेज प्रबंधन के लिए पैकेज के बारे में # tabbar-pkg.el जानकारी # मैनुअल को उद्धृत करने के 15 यदि सं...

Selenium (Python) - Get webdriver's page_source after page is fully loaded -

I want to get data from a dynamic page (many of them). I can access the page using Selenium in Pennathan. However, driver.page_source is incomplete. Even if I try the driver. Implicitly_wait (100) Nothing changes I also tried: selenium.webridr.com from Selenium Import WebDrive. By Import: Selenium.Vebriador. Support WebDrivewight is available from UI since # 2.4. Selenium.webitter From 0,26.0, import the desired_andition as available as EC # available. WebDriverWait (driver, 10). (Unless. While I'm waiting / waiting for something, more than enough to load the page, I do not see any effect on the driver. Page_source after waiting. Is there a solution? Thanks. If you really need it Its solution is to use something else to grab the page source. Webdrivers' getPageSource just on the back page of some Some states will return to Veronan (Java) from Docs, but most likely applies in other languages: getPageSource java Lang.String getPageSource () Get the so...

javascript - How to extend a primitive type in typescript? -

I want to create an interface like this: Show interface {show (): String; } Function doit (s: show) {return 'shown:' + s.show (); } Then we can use it with a new class: square fu {s: string; Creator (S: String) {this.s = s; } Showing () {Return 'with Foo' '+ + this.s +' ''; }} Console.log (doit (new foo ('hello')); I want to do the same for the number s in plain javascript i number , for example, please satisfy this interface like this: number.prototype.show = function () {return '' + this ;} But typecript does not allow me to: show.ts (18,18): error TS2094: property 'shows' does type The value of 'number' is not present at is there any way to do this Simply tell the typewrite by adding it to number : Interface number {show (): string;} number. Protopp. Show = function () {return "'+ this;} var foo = 123; foo.show ();

How to resolve the issue modal confirm dialog not working twitter bootstrap datatable sorter? -

I've added a column for the delete option (with confirmation) to delete the record in each row of the DATAT. The dataset page, when I do not click the deleted icon in the second page of the datalet, which is not working. Please help me to solve this problem Here I tried the code. & lt; Table class = "table table-stripedatable" id = "example" & gt; & Lt; Thead & gt; & Lt; TR & gt; & Lt; Th & gt; State & lt; / Th & gt; & Lt; Th & gt; Options & lt; / Th & gt; & Lt; / TR & gt; & Lt; / Thead & gt; & Lt; Tbody & gt; & Lt ;? Php $ query = mysql_query ("SELECT id, state from state_list"); While ($ line = mysql_fetch_array ($ query))? & Gt; & Lt; tr class = "odd grade X Order-delete" id = "ordrrow- & lt ;? Php echo $ row [ 'id'] ;? & Gt; & Lt; td & gt; & lt ;? Php echo $ row [ 'State'];? Gt; & lt; / td> g...

performance - when it is better to use constructor for android application -

I'm new to Android development. Still, I'm looking at the constructor in many codes. I do more research on Google about it. Answer is now the basic idea about it. I want to be a good signer, so it is important for me to know that when using the constructor for any android application development It would be better to do So if someone has a good suggestion for me whether I should use the constructor or not. The constructor is used to be able to set dynamic values ​​for objects on its construction. Or to ensure that the needs of the object are started at construction time. For example: class item {Private int a; Item (at value) {this.a = value; } Public int getValue () {// You can operate on returns; }} You can create an object using the above code and start the variable at the same time. Or there are other ways to do this: class item {Private int A; Public Zero Set Value (Int Value) {this.a = value; } Public int getValue () {// You can operate on returns; }} ...

showing incorrect answer for total physical memory size in java -

यह कोड है import java.lang.management.ManagementFactory; सार्वजनिक कक्षा मेमोरीज़ सिज {सार्वजनिक स्थिर शून्य मुख्य (स्ट्रिंग [] आर्ग्स) {com.sun.management.OperatingSystemMXBean mxbean = (com.sun.management.OperatingSystemMXBean) ManagementFactory.getOperatingSystemMXBean (); System.out.println (mxbean.getTotalPhysicalMemorySize () + "बाइट्स"); उपरोक्त कोड मुझे 2147483647 बाइट्स के रूप में आउटपुट मान देता है जो 1.99 जीबी के बराबर है। लेकिन वास्तविक स्थापित मेमोरी (रैम) 3.00 जीबी (2.30 जीबी प्रयोग करने योग्य) है। मैं सही मान कैसे प्राप्त कर सकता हूँ i।, 2.30 जीबी कृपया मदद करें। 32 बीट प्रक्रिया को अधिकतम स्मृति में लेने की अनुमति केवल 2 जीबी है यदि आप 64 बिट जेवीएम का उपयोग करते हैं, तो आपको पूर्ण आकार दिखना चाहिए।

android - Error when usig back button from Action Bar -

I have an activity called A, which takes extra on startup. The problem is that when the back button If pressed, then use B setDisplayHomeAsUpEnabled (true); I get an error setDisplayHomeAsUpEnabled (true); How do I send extra to B to A while using the back button? Activity A starts this way, the main activity says that creates a protected void (InstanceState saved from bundle) {// Tudo auto-generated method stub super. Contents (Saved Instantstate); SetContentView (R.layout.activity_subscreen); Bundle Extras = Milentant (). GetExtras (); TitleTask = extras.getString (DatabaseHelper.COLUMN_TITLE); Titid = extras.getLong (DataShelper.COLUMN_ROWID); ActionBar = getSupportActionBar (); ActionBar.setTitle (titleTask); ActionBar.setDisplayHomeAsUpEnabled (true); } The log error is as follows: 04-26 12: 39: 54.355: Back button pressed from E / AndromedaTime (15573): Java KlangkRuntimeException: activity unable to start ComponentInfo {com.group.RedPanda.FinalProject / com.gr...

python - Writing an HTTP query with Tornado? -

Can I use the Tornado features to write HTTP client queries? Contrary to the use of the http.client module in the standard library What will be the equivalent storm code: curl 'http: // localhost: 2222 / Foo? Bar = 1 ' verbal equivalent python -m tornado.httpclient 'http: // localhost: 2222 / foo? Bar = 1 ' or a coroutine in print (unproductive HTTP) (fetch) (' http: // localhost: 2222 / foo? Times = 1 ')).

How to add xmlns="MyNamespace" to AuthSOAPHeader in gSOAP -

I am creating client applications to access the web service from a third party server. This server WSDL: & lt; S: element name = "authSOAPHeader" type = "tns: authSOAPHeader" /> & Lt; S: complex type name = "AuthSOAPHeader" & gt; & Lt; S: Sequence & gt; & Lt; S: element minOccurs = "0" maxOccurs = "1" name = "user" type = "s: string" /> & Lt; S: element minOccurs = "0" maxOccurs = "1" name = "password" type = "s: string" /> & Lt; / S: Sequence & gt; & Lt; S: any specialty / & gt; & Lt; / S: complexType & gt; And these commands: wsdl2h -k -o svc.h. \ Svc.asmx.xml soapcpp2 -i -C \ Svc.h My GSOP-based client application is generating this XML: & lt; SOAP-ENV: Header & gt; & Lt; Ns1 also: AuthSOAPHeader & gt; & Lt; Users & gt; Users & lt; / User & gt; & Lt; Password...

python - Search Index for user articles -

I am creating a note in which users can create notes, add photos, add tags to create applications And can share with friends. I am using Python Flask Framework to make tools. I want to provide a feature in which a user can search through his notes. How do I go about creating an index, is there a library that can do it fast? I am using Mongodi as a backend DB You have tried to use flask-violet alkki. Flask-VioletAlky is a flask extension that integrates Wooth's text-search functionality with SORKK ORM's in Flask applications. Install Install pip flask_whooshalchemy Quickstart import flask.ext.whooshalchemy # whoosh index app.config ['WHOOSH_BASE'] = 'Set path for the path / in / whoosh / base' category BlogPost (db.Model): __tablename__ = 'blogpost' __searchable__ = ['title', 'content'] # this area will be indexed by whoosh id = app.db.Column (app.db.Integer, primary_key = true) title = app.db. Column (app.db....

javascript - How to make the current element toogle, instead of getting the toggle all element -

I have three different types of checkboxes and I am disturbing to toggle them, but all the checkboxes Toggling I just want to toggle the selected element. My code is as follows: CSS ==== Oter-box {background: none repeat scroll 0 0 # ea5700; Padding: 1px; Width: 55px; Height: 23px; Box-Shadow: 2px 1px 2px # 888888; } .poly-box {Infection: All .2s ease-in-out; Background: Any repeatable scrolls 0 0 # DDDDDD; Width: 15px; Height: 20px; Margin-right: -2px; Margin-left: 0 pixels; Display area; Correct: -32 pixels; Padding: 4px 5px 3px 3px; Status: Relative; Border: None; Border-radius: 2px; Box-Shadow: 2px 2px 2px # 888888; } # Right box Winner-box {LEFT: 37px; Top: 0; } .txt {padding: 2px; / * Font-family: 'robot slab', serif; * / Font-weight: bold; font size:; White color; } # Right box .txt {float: left; } #left-box Winner-box {top: 0; Left: 0 pixels; } #left box .txt {float: right; } JS === $ (function () ($ ('. $' External box '$' ('.txt'). $ (...

javascript - If 'this' in function is a particular class -

I have a representative who is called when some DOM elements are clicked using their ID or class And I'm inside this 'function', but how can I find out which class or id is it really? Here's my code: $ (document) .delegate ("#BLE-Menu Li, #xs-menu, lilist-item", "click" ("(") "; (=" (")"; (= "(") ";" Div> > this dome object , Which triggers the event so that you can use only DOM methods or jQuery methods to monitor it or its parent: $ (document) .delegate ("# Lg-menu LE, #xs-menu LE, .list-item "," click ", function (e) {var item = $ (this); // see if item matches what item if (item .is ("# Lg-menu li") {// # lg-menu li} else if (item.is ("# xs-menu li") {// should be #xs-menu li} other {// .list-item}} .is () prepares the entire selector assessment for you. You can also inquire the different properties of the element. Such as: ...

logging - Fail to inject log4j using CDI - WELD-001408: Unsatisfied dependencies for type Logger with qualifiers @Default -

I have the same problem as explained here: This is probably the same setup (Wildfile 8.0). Despite having a resource class with the manufacturer, I can not present a wooden example. Neiter in the controller, nor in EJB [Question 1] Should I be correct if I am wrong, I should be able to inject them into @nodel beans and @Stateless (EJB) in annotated beans, should not I? package com.doe.webapp.service.auxilliary.cdiproducer; Import javax.enterprise.context.Dependent; Import javax.enterprise.context.RequestScoped; Import javax.enterprise.inject.Produces; Import javax.enterprise.inject.spi.InjectionPoint; Import javax.faces.context.FacesContext; Import org.apache.log4j.Logger; @Dependent Public Sector Resources {@Produces Public Logger productionLog (InjectionPoint injectionPoint) {Return Logger.getLogger (injectionPoint.getMember () getDeclaringClass () getName () ..); } @Produces @RequestScoped Public FacesContext yields FacesContext () {back FacesContext.getCurrentInstance (); ...