Posts

Showing posts from April, 2012

windows - Emacs can't start server -

I try to start an emacs server on a Windows 8 machine. I downloaded vanilla imac, and run it using runemacs.exe . Then I run Mx server-start and executes this command takes approximately 3 minutes, followed by a ~ / .emacs.d / server / server file with the following Content: 127.0.0.1:65118 5868 R @ twizer] X-VJCB `G & amp; T; U1 & Lt; BJ3X]} 6! 8 XUUUS ~ P; {Q9'AIj322! W0O1XK [/ K4v & gt; ZOK * and the emacs server has not run: When I say emacsclientw.exe it does not call any server. Apparently emacs tried to start a server but failed. I am the owner of the ~ / .emacs.d folder. You are using a non-standard socket directory. By default, the socket is stored in / tmp / emacsXYZQ (where XYZQ is a number). emacsclient can not be detected where you placed the socket, so you need to tell it (if it is not a normal location). You can do this with the command -s . / P> EMACS_SERVER_FILE = ~ / .emacs.d and add more. / Server / ...

sql - Inner Join in Access Query not working -

यहां डीबी टेबल हैं समूह उपयोगकर्ता ग्रुपआईडी - यूजरआईडी -------------------- 00001 - उपयोगकर्ता 1 00002 - उपयोगकर्ता 1 00003 - उपयोगकर्ता 2 समूह समूह आईडी - समूहनाम - लॉक - हटाए गए ----------------------------- ---------------- 00001 - ग्रूप 1 - ट्रू - झूठी 00002 - ग्रूप 2 - झूठी - झूठी 00003 - ग्रूओप 3 - झूठी - गलत मैं हूं समूह यूज़र टेबल से नीचे दी गई क्वेरी में एक विशिष्ट समूह के लिए UserIds हो रही है, लेकिन मैं यह भी देखना चाहता हूं कि क्या समूह ID जहां खंड locked = true या delete = true में है समूह तालिका तब परिणाम समूह में इसका चयन नहीं किया जाना चाहिए। यहां मैंने जो भी कोशिश की है समूह का चयन करें GUU.UserId GroupsUsers से AS GU Inner Join Groups as G पर GU.GroupID = G.GroupIdWHERE ((G.GroupId) = 00001)) और (((जी। लॉक) = एफ Alse)) या ((जी। हटाए गए) = गलत)); लेकिन यह क्वेरी मुझे सभी उपयोगकर्ताओं को वापस लौटा देती है मैं सिर्फ किसी खास समूह के उपयोगकर्ताओं को प्राप्त करना चाहता हूं अगर यह लॉक या हटाए नहीं है आपके पास की क्वेरी यह है: च...

Ebay trading API - Where's the postage? -

I have been using eBay Trading API to retrieve a user's inventory. While Use I Granuliti = properly GetSellerList (), so I would like to reiterate through ItemTypeCollection for each item type. Products have £ 7.50 postage, but this item is nowhere in the type? How to find / find any ideas? Well I found wrong with it from the bottom: myItemTypeCollection [ x] .ShippingDetails.ShippingServiceOptions [x] .ShippingServiceCost.Value please nuts and how to bolt receiving seller lists from eBay: after you should mail address below called GetSellerList, I only target RoyalMail shipping service, but if you observe the object you will see other options: // eBay item type Choose from List item list = apiGetSellerList.GetSellerList (); // itemtype oItem in the loop each item foreach (itemLists through itemTypeCollection) {foreach (oItem.ShippingDetails.ShippingServiceOptions in ShippingServiceOptionsType shipType) {//// switch loop through the various shipping option...

command line - How to find and replace a character and apply on a large file -

I'm trying to change a fixed character found in the convert.txt. Now, convert. Each letter found in Txt will be converted into a file in Linefeed. I have this code: for / f "delims =" %% s in (convert .txt) (type c: \ PETER \% % A | repl.bat "\ %% s" "%% s \ n" X> c: \ PETER \ %% a) I replace.bat on this page Tried to use the suggestion. Now, when I am trying to convert the character of a large file into a line feed, the output is not complete. Do we have a limit to this matter? As MC ND said in his comment, you can read together and send the same file Write. You must type in a new file, and then change the original with the new one using MOVE. for / f "delims =" in %% (convert.txt) (type "c: \ PETER \ %% one" | repl.bat "\ %% s" %% s \ n "X" "c: \ Peter \ %% a.new" move / y "c: \ Peter \% div>

why i kill an application in android system,but it restart again -

I have to kill an application when I receive a major event in phonewindowmanager.java Try {ActivityManagerNative.getDefault (). KillApplicationProcess ("com.konka.fakestandby", 1000); } Hold (Remote Exception E) {} But restart it again I / ActivityManager (1737): process com.konka.fakestandby ( Pid 3571) It's dead. 10-17 16: 44: 12.448 I / WindowState (1737): Winning: Window {422cd068 u0 com.konka.fakestandby / com.konka.fakestandby.MainActivity} 10-17 16: 44: 12.472 I / Activityman (1737): Project Com Konka.fakestandby com.konka.fakestandby / for activity The main activity: pid = 3603 uid = 10024 gids = {50024, 1028} I'm confused, and hope someone helps me. Thank you If Falstandby is your own app, you must stop the activity and process Will not have to kill. If this is not your app then it may have to restart the service (sticky). If not, then the Android Framework is designed to relaunch an installed app, when it is free to allocate If...

c# - How can I get XMLRPC.NET to match perl speed? -

I have a xmlrpc server which is written in C ++ ( libxmlrpc ++ ). This getversion () is returning a string. Calling it from pearl (using), 100 calls 1.25s Calling it from C # (using XMLRPC.NET), 100 calls 50.322. It's running on Windows 7 Pro. Any thoughts on what is happening, and how to fix it? [XmlRpcUrl ("Http: // localhost: 9000 / RPC2")] Public Interface ICutControl: IXmlRpcProxy {[XmlRpcMethod] string reversal (); } Class program {public static zero} (ICTCTL proxy; proxy = XmlRpcProxyGen.Create & lt; ICutControl & gt; (); Int calculation = 100; try {for (int i = 0; i & lt; 100; i ++ ) {String version = proxy.getversion (); console.light line ("{0}: {1}", i, version);}} hold (System.Net.WebException pre) {Console.Error.WriteLine (" Exception: {0} ", prior.);}} Proxy = Null;} [Update] I compressed Tried, but it did not make any difference. Since it is happening on the client side, restart the server I...

winforms - C# Form - Property Change -

I have a form that has a property named car A class with many properties. The Properties is being displayed on the current car on the basis of some user actions that are being displayed. So I have to know whether the property has been allocated or set to zero. I'm aware of INotifyPropertyChanged , but in my case I'm not sure that since this change I have changed my car properties car do not want to monitor the property. Any idea how to accomplish this? In advance thank you If you have created a true asset in your class then You should be a great and setter, you can add the code directly to the form property in order to take action on the basis of "form": Public partial category Form 1: form {public form 1 () {InitializeComponent (); } // define car square public class car {public string name = string. Empty; } // private car to keep the value of the current car private variable _car = null; // Property of public form which you can ru...

c# - enable a disabled button by exiting off a form inside a form -

OK, I'm doing this. In the Start menu form, button 2- When button2 is clicked, brings a new look and is disabled Now the new look (InchMm conversion form) is up and when I'm done with that form I press the X button when it is done I want to enable Button 2 from StartMenu form. Down my code StartMenu Private Zero Button 2_Click (Object Sender, EventArgs e) {this.IsMdiContainer = true; InchMm_Conversion f = new InchMm_Conversion (); F.MdiParent = this; F.Show (); Button 2 Competent = valid; } Private Zero Button 3_Click (Object Sender, EventArgs e) {this.LayoutMdi (MdiLayout.ArrangeIcons); } Public Zero enableB () {button2.Enabled = true; } InchMm conversion form Private Zero InchMm_Closing (Object Sender, System.ComponentModel.CancelEventArgs e) {StartMenu.enableB (); } I am getting an error that says that the object reference for non-stationary area, method, or property is required. Now I know that it should be right in the form of my face, but I am still le...

Find a type of Device (It's android or iPhone) from device token using PHP -

इस सवाल का पहले से ही एक उत्तर है: 5 जवाब मैं एक PHP पर काम कर रहा हूँ आवेदन, कुछ ऐप के लिए पीएचपी एप के लिए मोबाइल ऐप का अनुरोध मोबाइल ऐप सर्वर को डिवाइस टोकन भेज रहा है। तो मैं यह जानना चाहता हूं कि मोबाइल ओएस से अनुरोध क्या आ रहा है? यह एंड्रॉइड या आईफ़ोन है? यदि आपको केवल अलग एंड्रॉइड और आईफ़ोन की आवश्यकता है, तो अनुरोध पैरामीटर एंड्रॉइड कोड में और एंड्रॉइड कोड में और & amp; os = iphone । जोड़ें: इसके अलावा आप $ _ SERVER [ HTTP_USER_AGENT '] ।

javascript - How to get Google Map zoom level to 23 -

I am creating a web page for study purposes which has Google Maps that I have implemented using Javascript. The problem is that I get only the zoom level of 15 (it shows the zoom zoom of the city). You can zoom in to show street names on most websites, such as how to get a zoom level of 23 (street level zoom) on Google Maps. I have never said anything, turn me into MTPP ID to get more zoom

python - convert date from numpyarray into datetime type -> getting mystic error -

I load a file f with the numpy.loadtxt function this type I and to remove some of the dates was on a format: 15.08 - 21.08.2011 numpyarr = loadtxt (f, dtype = str, delimiter = ";", skiprows = 1) alldate = numpyarr [:, 0] [0] data = Datetime.datetime.strptime (alldate, "% d.% M -% d.% M% y") And here is the full error: Traceback (most recent call final): File "C: \ Pithan \ Test DATETIME_2.py", line 52, & lt ; Module & gt; Dat = datetime.datetime.strptime (aldate, "% d.% M -% d.% M %% y") file "C: \ Python 27 \ lib \ _strptime.py", line 308, in _strktima format_regex = _TimeRE_cache .compile (format) file "C: \ Python27 \ lib \ _strptime.py", line 265, re_compile compilation returns (self.pattern (format), IGNORECASE) file "C: \ Python27 \ lib \ re.py" line 1 9 0, compile returns _compile (pattern, flags) file "C: \ Python 27 \ in lib \ re.py", line 242, _compile raise error, v # i...

javascript - Show elements from side of page with jquery as scrolling -

I want a jquery plugin, but I do not know what its name is! Check this page: As you scroll to the page, the elements are visible from one side of the screen. How can I do this with jquery? You can use scrooldeck.js Information found here: / P>

c++ - Print fully evaluated result of #define during compilation using #pragma message() -

Using a #pragma message, I have a quick question about printing evaluation values ​​of #defines, I used Visual Studio 2008 I am using MSVC ++ Below is a simple example: #define __STR2___ (x) #x #define___r1___ (x) __STR2__ (x)) #defined WIDTH 10 #defined HEIGHT 10 # The defined area (WIDTH * HEIGHT) #pragma message ("The area is:" __STR1 __ (ARA)) Now when I compile, I get the following output: & gt; The area is: (10 * 10) This is not what I need. Is there a way to print #define expression evaluation, which I found: & gt; The area is: 100 It is probably not possible during the compilation, eventually I would like to cause the compiler error if the evaluation value is very large. I.e. #if (region> 1000) #pragma message (__default ERROR__) #endif use some of my # definitions sizeof ( ) which I believe is the cause of issues in evaluating the conditions - but this is a problem for the future! I saw the following post which is defined as...

After setting loadonce to false multiple search for jqgrid , it is not loading the searched data. It is reloading the grid with all the data -

After setting the loadon to the wrong multiple search for jqgrid, it is not loading the data searched for all of this data With reloading the grid. The server depends on different data that you loadonce : True or use the default loadonce: false option. It appears that your server provides incorrect data for the part loadonce: incorrect . To understand. JqGrid sends some parameters to the server. These default names are pages , rows , sidx , sord , _search and more In the case of filtering, in case of advanced parameters, your parameter search filter . For the implementation of the server correctly, in the case of the use, loadonce: true one needs to use only sidx and The input parameter and returns all the data which need to be sorted now sidx and the sord parameters. To implement the server part correctly in the case of the use, loadonce: false requires you to apply a more sophisticated argument on the server side. The server should filter th...

How do I keep Delphi from automatically expanding folded code regions? -

I use {$ Regions} widely in my units, Ever since the VCL editor makes annoying decisions, by clicking on the button to expand all the areas on its own till I do not clarify, till then do not extend those parts to the editor Is there any way to tell? Updates from comments: Unfolding, Introducing a new nested "Process" header with nested procs / funcs As soon as you type the 'P' character, all the nested procs / funcs are coming out, this also happens, for example, by mistake, you can "expire" any nested proc / func (or some type) Remove If you start a comment with "{" with fields, then immediately open the area below. "(*" All provinces have been shown below to start a comment and it applies to all processes / fanks under those areas. Unfortunately this is one of the problems of Delphi, which exists since Delphi XE, even if not from the earlier versions and still not fixed . The fact that the code is officially e...

sql - MySQL results from keywords -

I am trying to create a simple search function in MySQL where a user can enter images by entering one or more predefined keywords Can filter. But whenever I add more than one keyword, I'm unable to get the right output. Here is a simplified version of database structure: Table: Images-id (PK) - Title - Link table: Keyword - ID (PK) - Keyword table: Image_keywords - image_id (FK) - keyword_id (FK) Example of data: Image: 1. Image 1 headline http://test1.com 2. Image 2 headline http://test2.com 3. Image 3 Title http://test3.com Keywords: 1. Photography 2. Landscape 3. Skyline image_keywords: 1. 1. 2. 2. 2. 1. 2. 2. 3. So what should I be able to do image_keywords For all images, Both Photography and Landscape are listed as a keyword and listed them. But can there be an unlimited amount of unlimited keywords with an image in Thermo? I think this might be what you want: Select I.id, from within i.title, include inside the interior image_keyword_keyword I...

routing - Mounting non-rack applications in Rails -

Assume that I have 2 web applications: 1) One is a regular rail app 2) Second, there is an intranet app (non-Ruby app), for example port 3333 is accessible only through the web server. Instead of going to the server and accessing it: http: // intranet: 3333 I want to expose the intranet app through a rail path. Like http://railsapp.com/otherapp . With ideas, what can we do with you, you can do this with a rail engine. thank you in advanced!

Add another UrlHandlerMapping to Spring data rest -

I have a normal Spring-MVC project and I am also building the rest module The target occurs as a separate jar file when I have jar left to map the general website for / and spring data - The rest of the repository has been mapped to / rest . For the rest module, I have defined a WebApplicationInitializer with the repository RASTMVC configuration and it all works well. So now I want to add the rest module (like / synchronize , and some more url ) / Certify , etc.) but as soon as I add the controller to the rest module, the original application context (website / ). I tried to designate them as bean in the repository RSTMVC configuration but they are still taken with other original references and the filters of the original reference are removed. And when I access spring data-rest by means of / rest no filter starts up So I was wondering: What is the method I repository RASTMVC configuration so that I add additional URL handler mapping? I believe...

java - re-do for loop again -

मेरे पास एक 2 डी सरणी है जिसमें निम्न मान हैं 1,2,3 1 , 0,2 0,1,2 और एक सरणी जिसमें निम्नलिखित मान हैं 0,1,2,3,4,5, 6,7,8 मैं क्या हासिल करना चाहता हूं पहले यह सरणी से शुरू होता है [0] मैट्रिक्स [0] [0] * सरणी [ 0] = परिणाम 1 मैट्रिक्स [0] [1] * सरणी [1] = परिणाम 2 मैट्रिक्स [0] [2] * सरणी [2] = परिणाम 3 मैट्रिक्स [1] [0] * सरणी [0] = परिणाम 4 मैट्रिक्स [1] [1] * सरणी [1] = परिणाम 5 मैट्रिक्स [1] [2] * सरणी [2] = परिणाम 6 मैट्रिक्स [2] [0] * सरणी [0] = परिणाम 7 मैट्रिक्स [2] [1] * सरणी [1] = परिणाम 8 मैट्रिक्स [2] [2] * सरणी [2] = परिणाम 9 उसके बाद यह वापस लूप को फिर से चला जाएगा, लेकिन इस बार सरणी से शुरू [3] सरणी [0] [2] * सरणी [5] = परिणाम 12 मैट्रिक्स [0] [0] मैट्रिक्स [0] [0] * सरणी [3] 1] [0] * सरणी [3] = परिणाम 13 मैट्रिक्स [1] [1] * सरणी [4] = परिणाम 14 मैट्रिक्स [1] [2] * सरणी [5] = परिणाम 15 मैट्रिक्स [2] [0] * सरणी [ 3] = परिणाम 16 मैट्रिक्स [2] [1] * सरणी [4] = परिणाम 17 मैट्रिक्स [2] [2] * सरणी [5] = परिणाम 18 इसके बाद वह वापस पाएं सरणी [0] [1] * ...

search - Applying "tag" to millions of documents, using bulk/update methods -

We have our elaborate search examples about 55,000,000 documents. We have a CSV file with User_IDs, the largest CSV has 9M entries in our document as user key in the form of the user_id, so it is convenient I am posting a question because I discuss this I want to discuss the best option and there are different ways to overcome this problem. We need to add a new "label" to the document, if it is not in the user document yet, such as tagging the user with "Stackworflow" or "Gitub". Classic endpoint It seems very slow because we need more than 9m of user_id and for each of them to issue an API call. There is, which provides some better performance but can be mentioned with limited 1000-5000 documents. Knowing more in a call when the batch is huge, some know that we have to go Need to know in Then there are too many traffic for the endpoint, but no confirmation was implemented in this standard release. There is a mention on this open issue for w...

cmd - Add sheet with column names to Excel spreadsheet -

How do I add a sheet to an existing Excel spreadsheet? This code overwrites the .cmd file and currently if the report.xls file is present with a new file. If EXIST% 1 \ Report.xls DEL% 1 \ Report.xls COPY% 1 \ ReportTemplate.xls% 1 \ Report.xls Surely it is not possible in CMD, if you have PowerShell available then you can write a PS script, You can start from the file (or just do everything in powers :)) If you want to try it, there is a COM object to work in excel files, its name is "excel. Application ". Here you make such an object in powers: $ xls = new-object -comobject excel.application then You can open your XL file and edit it (just Google for further instructions). Regards

PHP - explain REGEX expression -

Does anyone help me understand the following php regex expression I preg_match ("| store: (. * ) | ", $ K, $ matches) in PHP regex expressions '|' Represent? ... $ storevals = array (); Foreign currency ($ k = $ v as $ item) {if (preg_match ("| store: (. *) |", $ K, $ matches)) $ $ storevals [$ matches [1]] = $ V; }} ... The last CSV file of this function is to call the CSV header to change the keys in an array ( $ item ) I am trying to find out the format for the CSV file. Thanks in advance. Here's a complete explanation - Store: Matches the letter "Store:" Really (case sensitive) 1 Capturing group (. *) (grouped by parentheses) . * matches any character (excluding new line) Quantifier: * between zero and unlimited time, return as often as possible, as needed [greedy] Pipe | are the delimiter for regex.

tfs2013 - "[Me]" variable for custom field alerts in TFS 2013 -

I have added custom field (test headman) in TFS since I have valid TFS wanted users to drop down, so I have copied the set to assign to (string, dimension, ALLOWEXISTINGVALUE, VALIDUSER, and SYNCNAMECHANGES) . Test the major changes in [principal] or test the prime changes from [m] but I want to be able to set a warning I do not seem to catch the current user "[m]" or "@ m", it is under the assigned drop down menu, so I do not think why I can not use this variable. Is it for a non-core area and [m] is available only for core areas? If so, there is no remedy because I have not been able to find any. set syncnamechanges = "true" in the custom field definition If the working template can not be uploaded, use the widget tool to update the synced-change attribute. In the warning rule, use @@ MyDisplayName @@ placeholder instead of [m] or @Me .

c# - Cascade on delete - Complex type mapped to a table -

कृपया निम्नलिखित संबंधों पर विचार करें: कार (संस्था) 1 -------- --------------> * पहियों (इकाई) पहिया (इकाई) 1 ---------> 1 अखरोट (जटिल प्रकार) व्हील (इकाई) 1 ---------> 1 रिम (जटिल प्रकार) दोनों अखरोट और रिम जटिल प्रकार मैट किए जाते हैं जो कि पागल और रिम नामक टेबल हैं। मैं नट और रिम प्राथमिक कुंजी के रूप व्हील आईडी का उपयोग कर रहा अब, जब कोड का उपयोग कर कार को हटाने का प्रयास है, मैं निम्नलिखित अपवाद:। System.InvalidOperationException: ऑपरेशन विफल रहा: रिश्ते को बदला नहीं जा सका क्योंकि एक या अधिक विदेशी कुंजी गुण गैर-नाकाम करने योग्य हैं जब किसी रिश्ते में कोई परिवर्तन किया जाता है, तो संबंधित विदेशी-प्रमुख संपत्ति को शून्य मान पर सेट किया जाता है। यदि विदेशी कुंजी सुस्त मूल्यों का समर्थन नहीं करती है, तो एक नए रिश्ते को परिभाषित किया जाना चाहिए, विदेशी-प्रमुख संपत्ति को एक अन्य गैर-रिक्त मान निर्दिष्ट किया जाना चाहिए, या असंबंधित ऑब्जेक्ट को हटा दिया जाना चाहिए System.Data.Entity.Core.Objects.ObjectContext.PrepareToSaveChanges (SaveOptions विकल्प) System.Da...

javascript - TimeSpinner Check If Undefined Not Working -

I currently have an input text field that can be tied to a particular element of timepinner or, in some cases, Time-Painter's functionality needs to be removed completely (to oppose it inactive), to display it properly on the page Currently, I have a code to check if the timepinner element exists on or below: if ($ ("# Elementoff interrects"). Timepinner! == undefined) {$ ("# element of interrex"). Timepinner ("destroyed"); } This is the first time the page is first loaded , however, it throws the following exception: Can not call methods before starting on timers; For any reason, passes through the check for undefined and tries to timepinner on the element which is not in existence. So the only way my UI is running right this time is to wrap this try / catch block like this: If ($ ("# ElementOfInterest"). Timespinner! == Undefined) {try {$ ("# ElementOfInterest"). Timepinner ("destroyed"); } Catch...

Resize bitmaps vs multiple Images folders for Android resolutions -

I am developing an Android app, but I am still experienced with some SDK stuff. One of those things is more than one resolution. I know that the Android document talks about the use of multiple image folders for different screen resolutions. But I ask myself, how can I reduce my app size? And the place where I thought about changing the size of the images Also, I unpacked some apps and saw that they only used one folder for an image. My questions are, should I resize my images or should I use multiple images for many folders? What is the difference? What do people usually do? What are the advantages and disadvantages? I'm really thinking about getting the Android device density and shaping my image. But I do not know that this is a best practice. The size of Android images is best to be missing in the appropriate folder. For quality you should always scale down , not above So, if you use the highest resolution image in your folder, then it may be enough It is bet...

HTML breaking in iframe src -

We have a Coldfusion application with many legacy codes and many new codes when the inheritance code is provided which is now So, we display it in an iframe. However, a security scan of our software has reported the issue of breaking a few pages when you include html in the URL. Bringing example URLs: https://mySite.com/coldfusionPage.cfm?layout= true & amp; 67c26 "> bb6cb = 1 When iframe renders it, it breaks because the URLs and quotes of the URL end to the iframe tag , And the rest of the Url and iframe tags are sung in the form of html on the page. If you are adding that paragraph without scrubbing, it is for malicious content, then your scanner company is correct, you are open for any links that your page You do not want to pass things through the URL, which is then inserted into the URL. Think about an iframe. If you have a link like this Is: href = "https://mySite.com/myPage.cfm?include=someIframPage.cfm and after that you" Get page of...

How can I calculated the total sum of a repeat binding in polymer? -

उदाहरण: & lt; div id = "order" & gt; & Lt; टेम्पलेट दोहराने = "{आइटम के रूप में आइटम}}" & gt; & Lt; p & gt; & LT; अवधि & gt; {{item.id}} के & lt; / span & gt; & Lt; span class = "price" & gt; {{item.price}} & lt; / span & gt; & Lt; span class = "qty" & gt; {{item.qty}} & lt; / span & gt; & Lt; / p & gt; {{CpuTotal (item.qty * item.price)}} & lt; / टेम्पलेट & gt; & Lt; p & gt; कुल {{total}} & lt; / p & gt; & Lt; / div & gt; & LT; स्क्रिप्ट & gt; पॉलिमर ('my-form', {कुल: 0, cpuTotal: फ़ंक्शन (x) {this.total = this.total + x console.log (this.total)}}) & lt; / स्क्रिप्ट & gt; & Lt; / बहुलक तत्व & gt; क्या कोई ऐसा तरीका है जिसे आप एक गणनाबद्ध बाइंडिंग का उपयोग कर कर सकते हैं, ताकि मैं {{total = total + (item.price * item.qty)}} ? संपादित करें: अब समस्या यह है कि this.total प्रत्येक अलग आइटम की...

hash - CRC32 vs CRC32C? -

What is the difference between CRC 32 and CRC 32C? I know CRC 32 for a long time, but today the CRC 32C has heard. Are they basically the same method (ie both results in the same hash for the given data)? CRC found in zip 32 and many other places uses polynomial 0x04C11DB7; The mentioned form 0xEDB88320 is perhaps better known, which is often found in very low-endian implementations. CRC 32C uses a separate polynomial (0x1EDC6F41, reverse 0x82F63B78), but otherwise the computation is the same. The results are different, naturally it is also known as the Castagonoli CRC 32 and is found most clearly in the new Intel CPU, which can calculate a full 32-bit CRC step in 3 cycles. This is the reason why CRC 32C is becoming more popular because it allows advanced execution, despite a delay of three cycles, effectively implementing a 32-bit word per cycle (processing 3 streams of data in parallel And using linear algebra to combine the results).

ruby - Verifying searched text displayed is in a single line -

How can I test that a sentence (combination of four or five words) is displayed in a row? I have to search with a name or some other areas after the search results are displayed, I should check whether the text displayed is a single line or not. For example, the code below is used to verify the search result link: // ol [in (@ class, 'search result')] / li [ Contains (@ class, 'mod') result () and in it (@ class, 'XXXXXX')] / / [[[href ['href' 'trk = XXXXXX']] I'm not familiar, but the following approach should work in any language. Assuming that your "sentence" is completely contained in an element, you can get all the events with something like this: driver.findElements ( By.xpath ("// * [text () = 'your sentence']")) Then just test for the size of the array.

java - Selenium - why doesn't thread.sleep work in safari? -

In Firefox, I can slow down Selennium using the thread.sx (xx) I am, but I can not slow it down in Safari. Please do not wait for me to look for the element. There is a user who has faced the same problem: This honestly has not shown anything useful. Besides this, some other basic things like name_of_input_box are not working on Safari. Why are they doing this? Even basic code like breaking (in Safari, not Firefox): log ("search for input box"); WebElement emailInput = (New WebDriverWait (Driver, 10)). Unless (required conditions .resenceOfElementLocated (by .name ("email"))); Logs ("clear email input box"); EmailInput.clear (); Log in ("send key" + e-mail + "in input box"); EmailInput.sendKeys (email); The point where my code is breaking: emailInput.clear (); If I try to capture around it then there is a warning message The element is currently not interactive and can not be used My logs here: Search e...

Text from database - convert to html -

I have received a text from the database and I want to convert it to an HTML code. New lines are saved in my database, but when I ask it and echo it on my HTML code, there is no new line, because I need to put some code inside. I found it but it does not seem to work: $ html = str_replace ("\ n", " ", $ html); Thanks for someone else's help. Try $ html = nl2br ($ html);

javascript - Why is it that when I load this page, the href of an <a> tag is getting called? -

I am working on a project where I am using an organization's header on my website. ORG's website has been created on asp.NET , which I do not know about, the part that is tripping me, is getting the search bar on the header to work. What I have tried, it is the following (some things are anonymous) $ (document) .ready (function () (/ {search icon holder & lt; a & gt; Select element (usually a magnifying glass) and set it as a variable: * / var searchIcon = $ ('# id1'); / * Set a variable equal to the prefix of the URL request: * / Var urlRequestPrefix = "http: // www. Orgname.com/search/Results.aspx?k="; / * Search & lt; Input & gt; element and set it as a variable: * / var search Input = $ ('# id2'); / * & lt; a & gt; tag If you click on the search, search icon searches for input. Originally in href = "javascript: someFunction ()" * / searchIcon.attr ('href', function) (window.location = urlRequestPref...

ios - Strange error writing text to CGContext -

I am trying to write a CGContext text using this code NSString * text = NSLocalizedString (@ "Mytext", zero); NSDictionary * atributes = @ {NSFontAttributeName: @ "Helvetica Neu Bold", NSIAForFolder Attribute Name: [UIColor blackcolor]}; [Text drawAtPoint: CGPointMake (x1, y2) withAttributes: attributes]; but I am seeing this error Exclude the application due to exception exceptions' NSInvalidArgumentException ', Reason:' - [__nxststant string Point size]: Example sent to unknown selector 0x1001dfd40 Any clues? set NSFontAttributeName for the UIFont object. NSString * text = NSLocalizedString (@ "myText", zero); NSDictionary * atributes = @ {NSFontAttributeName: [UIFont fontWithName: @ "Hewlettia New Bold" Size: 17.0], NSIIFFold Entrant Name: [UIColor blackColor]}; [Text drawAtPoint: CGPointMake (x1, y2) withAttributes: attributes];

jedit - Find from last blank line to string using regex -

I need to search jEdit for a string that starts from the end of the last blank row to the second string : / P> blah blah blah blah blank line empty line empty line * start here * blah blah blah blah blah blah ------ running --- --- This idea is to do a search and place everything before the string (I have bolded) ------ move Yes ------ But there are no rows or strings before that last line. Can someone recommend the appropriate reggae to find the beginning of the string from the end of the last line------ running ------? Thank you! Use the regex below and then remove the matching string with an empty string. (? S) (? & Lt; = \ n) (?: (?! \ N \ n). * * \ N (? = [^ \ N] + - ---- Running - -----) Java will be regedx, (? S) (? & Lt; = \\ n ) (?:(?! \\ n \\ n). * * \\ n (? = [^ \\ n] + ------ running ------)

asp.net mvc - MVC C# Retrieving selecteditem intoDropdownlist on page load -

I have a view and a button dropdown list. Now when I click on the button, the value of this dropdown list value According to the data loads. The filtering works and displays the page fully but the dropdown list value keeps the setting again. I want to retrieve this last selected value. This is a view with my page AllDates.cshtml and will filter the buttons and return the same page again: @ {ViewBag. Title = "all cars"; } & Lt; Form name = "filter" action = "~ / home / alldates" method = "post" & gt; & Lt; Select id = "fly" name = 'fly' & gt; & Lt; Option value = 'any' & gt; Any & lt; / Options & gt; & Lt; Option value = 'plane' & gt; Aircraft & lt; / Options & gt; & Lt; Option value = 'kyte' & gt; Kyte & lt; / Options & gt; & Lt; / Select & gt; & Lt; Input id = "refine" type = "submit" value = "re...

ssl - Is there a way to redirect a user if a x509 certificate is not selected when going to website? -

I am currently working in IBM Domino (8.52). I have the website installed with SSL and to accept the certificate. For the time, I allow "benami" access over SSL. While trying to come to the web site, the user is asked to choose the certificate, but if the user selects the cancel button, then the user is returned to the web site as an anonymous user. Is there any way to control any method that a user certificate is not selected or not? I would like a server wide solution, but would like any potential coding ideas. V / R, Kew in VA How is the weather The problem is that you are using the promotionunknowncerttoanonymous = 1 ini setting; So you will not see the name on the user's name, unless the person does not correspond to x.509 in the dock. Remove the INI setting, ignore both anonymous and user name / password in server dock for both 80 and 443, make sure that your root x.509 certificate is in the keyring, and you should start looking at the username from the...

OpenGL is averaging all colors in the texture? -

मैं इस तरह opengl में मेरे बनावट पैरामीटर सेटअप: glTexParameteri (GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT); GlTexParameteri (GL_TEXTURE_2D, जीएल_TEXTURE_WRAP_T, जीएलयूपीईएटी); GlTexParameteri (GL_TEXTURE_2D, जीएल_TEXTURE_MIN_FILTER, GL_NEAREST); GlTexParameteri (GL_TEXTURE_2D, जीएल_TEXTURE_MAG_FILTER, GL_NEAREST); `// glGenerateMipmap (GL_TEXTURE_2D); glActiveTexture (GL_TEXTURE0); बनावट के लिए मेरा डेटा यह है: परीक्षक [0] = जांचकर्ता [1] = जांचकर्ता [2] = 255; चेकर [3] = चेकर [4] = चेकर [5] = 0; चेकर [6] = चेकर [7] = चेकर [8] = 255; चेकर [9] = चेकर [10] = चेकर [11] = 0; मेरा बनावट जीएल_आरजीबी में है और जीएल_UNSIGNED_BYTE लेता है I मैं बनावट की चौड़ाई और ऊंचाई 2 तक सेट और बनावट को बनाए रखने के लिए मेरे निर्देशांक दो त्रिभुज से बना है जो एक वर्ग बनाते हैं और पूरी स्क्रीन को भरते हैं। हालांकि मुझे दो के बजाय एक सफ़ेद रंग मिलता है काले और दो सफेद पिक्सेल आरजीबी में ग्रे रंग बेहद 128,127,127 है मैंने पढ़ा है कि मुझे प्रत्येक रंग के लिए जांचने वाला एक पैकेट जोड़ना चाहि...

javascript - How to Disable browser stop button near to back button in Chrome and Firefox -

I'm loading a specific page, while I want to stop the user from pressing the Stop button in my browser. How can I do this in jquery or javascript? You can not disable the native functionality of the client browser Back, forward, pause, refresh, etc. . This is a good thing, because people will write web pages, from which you can not navigate - or close the window - and you will have to open the task manager to kill the process.

eclipse - Java, create runnable jar file including ONLY used dependencies. -

This question has been asked before, but there is no satisfactory answer yet! I have Java class in a project full of other non-affiliated sections in Java Maa. I want to export a Java executable to a jar file, in which it uses only dependencies. Is it possible, if so how? Both Eclipse (Create Runner Jar) and Intelligence (Artifact) will include all the dependencies defined in the menu with Java class. Instead of the people you provided in eclipses and IDEA by default, a dependency management system Should use. Many Java developers use (including me) if you are working in Eclipse, then it includes You do not want to have all dependencies in a project because it can actually be bloated though , If you have a Maven original pom which is & lt; Dependency Management & gt; tag, you can easily simply refer to this parent pom and then easily reference only the context of the dependency in that sub project, all this is different Which is really different, and prov...

android - Add new item in the Listview is already populate the start of app -

Using the My ListView ListFragment and BaseAdapter, there is a population at the beginning of the application. In the layout I have a button to add a new item, but when I add a new item to the list items item it is removed. My inventor Cs: Public Category TabItems: List Fraudmat {Adaptitum _ Adaptador; View public override octivity (layoutinfile inflator, view group container, bundle saved instenstate) {see View = Inflator. Inflight (resource layout, items, empty); See list view list = (list view) view. FundwidiId (Android.Resource.Id.ListItems); _Adaptador = new adapter (this activity, webservice, return list items); ListView.Adapter = _Adaptador; Return view; } Public Override Zero OnListItemClick (ListView L, See V, Int Position, Long ID) {Bundle Bundle = New Bundle (); Intent Activity = New Intent (v. Contestex, Typef (ChatActivivity)); Int value = (int) l.Adapter.GetItem (status); Bundle Point ("value", value); Activity.PutExtras (bundle); StartActivity (activit...

c# - DBNull error using combobox with entity framework -

Application in a window using the Entity Framework, I'm struggling with Cambodia a little bit. I is an entity device , which has 0,1 connections from any other entity person . Meaning, device can contain 0 or 1 person . To create / edit forms, I have the device , I have a Cambodia to choose Person I populate the Cumberbox like this: personComboBox.DataSource = context.People.ToList (); PersonComboBox.DisplayMember = "name"; PersonComboBox.DataBindings.Add ("SelectedItem", toolbanking source, "person"); If I select a person , but everything is working fine, but if I leave it blank, I get the following error : The object type 'System.DBNull' can not be changed to 'EMDataModel.Person'. If I remove the combo box from the form, then I insert the required zeros in a new device , person field. It tells me, that the model and the database are properly configured. What I have found is that for some reason, the b...

Swipe between tabs items, onsen-ui -

I am using the onsen-UI (v1.14), and I am trying to swipe between tabs I'm messenger on Facebook, but I'm not able to work it out. I have tried using the "setActiveTab" function with the on-price-detector, in many combinations, but none worked. Here I've done (to the tool bar) css .activebtn .ng-scope {color: blue; } html & lt; Ons-template id = "list.html" & gt; & Lt; Ons-toolbar var = "tb" & gt; & Lt; Div class = "center" & gt; & Lt; On-toolbar button class = "tbbtn" id = "btn_0" ng-click = "abc.setActiveCarouselItemIndex (0)" & gt; All & lt; / On-tool bar button & gt; & Lt; Online tool bar button class = "tbbtn" id = "btn_1" NG-Click = "abc.setActiveCarouselItemIndex (1)" & gt; People & lt; / On-tool bar button & gt; & Lt; Ons-toolbar-button class = "tbbtn" id = "btn_2" ng...

ruby on rails - How to solve byte order mark, BOM, in localization files -

Localization of my Rail app works fine locally, but when recruited in Harokuk, some words are not translated And "missing translation" "span tag. It seems that there is only one problem and by solving it but what does it mean, how do I recognize the BOM in my Yum-file and remove it How can I? or / and what do I need to do to check that I am editing in the album? If BOM is your problem, then you save file -> encoding -> UTF8 in the sublight. The UTF8 option is implied to be without BOM. You have with BOM There are options other than UTF8.

python - DJANGO Celery on Application Server + Mail server -

I am trying to configure DNAGOS + cialari on an aper server with different mail servers. Both servers share the same files: app_name / settings.py BROKER_URL = "SQS: //% s:% s @" (AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY) CELERY_TIMEZONE = 'America /': {'Queue': 'Scheduler' New_York 'CELERY_ACCEPT_CONTENT = [' Pickle ',' json ',' msgpack ',' yamail '] mail.tasks.send_reminder_email_end_user celery.schedules crontab import datetime import timedelta CELERY_ROUTES = { '}' mail.tasks.send_all_daily_new_user_email ': {' queue '' scheduler '},' mail.tasks.send_notification_email ': {' queue '' scheduler '},' mail. Taskss.send_new_post_daily_email ': {' queue ':' scheduler '},' insightstat Tasks. {'Work': 'mail.tasks.send_reminder_email_end_user', 'schedule': crontab (minutes = 0, hours = '' '':...

r - Making nicely formated tables in Markdown: knitr not compiling stargazer>html table -

I am trying to embed an output table, well formatted by the stranger function, in a markdown document. I tried to embed Stranger () in an R code block in the RMD document: `` r} Library (Sturgers) Struggers (Core (Attitude) Code = "html") `` The code runs correctly, but it outputs to the HTML code which is not parsed by knit in turn, hence the actual table The HTML 'source' code is shown in the rendered document Let me know about this similar question (IS). I am asking a different question because most answers tell that sterger does not support HTML output, which is no longer true HTML support was probably included in Strogger after running (and I would like to open a comment again or post Not to be an Anguigheth representative). This is related to a simple problem, which compiles the HTML table source code to make knit. Edit: @RRMRSMRT responded to me in the comment, which is: `{r result = 'asis'} Library (Sturgers) Sturgers core (Attitud...

string - Comparing content with file in Java -

I am trying to take as a word input and checking whether that word is in a text file Exists or not. But I ended up with this error import java.io. *; Public class spell checker {throws public static zero test (string SRR) IOException {FileReader fr = New FileReader ("wordsEn.txt"); Buffett reader BR = new buffed reader (FR); Int i = 0, j = 0, n = str.length (); Str + = ''; String floating = "", temp2 = ""; Do {for (i = j; str.charAt (i)! = ''; I ++) temp + = str.charAt (i); Println (temporary); While ((temp2 = br.readLine ()) = null!) {If (temp == temp2) System.out.print ("\ t \ t \ penis"); Else system.out.print ("\ t \ t \ tWRONG"); } Temp = ""; J = i + 1; } While (i & lt; n); Fr.close (); } Public static zero master (string [] args throws IOException {java.util.Scanner input = new java.util.Scanner (System.in); System.out.print ("Enter the string for which you want to check spelling:"); ...

r - Reshaping dataframe - two columns from correlation variables -

मेरे पास निम्न डीएफ है var1 var2 freq 1 अब 10 2 बीए 5 3 बीडी 10 से बना सहायता & lt; - data.frame (var1 = c ("a", "b", "b"), var2 = C ("b", "a", "d"), फ़्रीक = सी (10, 5, 10)) अब तक के संबंध बीए के समान हैं, और मैं उम्मीद कर रहा हूं var1 var2 freq 1 ab 15 2 bd 10 कोई भी विचार? यहाँ एक तरीका है: setNames (सकल ($ freq, as.data.frame (t # Var1 var2 फ़्राइक # 1 एबी 15 # 2 बीडी 10 (लागू करें [3], 1, सॉर्ट करें)), राशि), नाम (सहायता) एचटीएमएल>

binary search tree - Getting an object from a recursive deletion Java -

I have a binary search tree that contains nodes. Each node has a significant value and data value, and the nodes According to the key, I am trying to write a method to remove an object from my BST. Here's the code: Remove the public object (comparative theKey) {Remove the return (theKey, rootPtr) .data; } Removing the public node (comparative key, node node) {Object o; If (node ​​== zero) returns node; If (theKey.compareTo (node.key) & lt; 0) {// go to the left sub-section node. LeftChild = remove (theKey, node.leftChild); } And if (theKey.compareTo (node.key)> 0) {// Go to the correct sub-node node. RightChild = remove (theKey, node.rightChild); } And if (theKey.compareTo (node.key) == 0) {if (node.bumbled! = Null & node. Writebill! = Null) {node foundNode = findMin (node.rightChild); Node.key = foundNode.key; Node.data = foundNode.data; Node.rightChild = remove (node.key, node.rightChild); } Else {if (node.leftChild! = Null) {node = node.leftChild; } And {node =...

ffmpeg command to extract first two minutes of a video -

What would be the easiest ffmpeg command to shorten the video in the first two minutes (or nothing if the video is the least Is two minutes)? It can pass on any early video settings. $ ffmpeg - I in.mov -ss 0 -t 120 out. Mov

web services - WsOpenServiceHost returns WS_E_OTHER -

multithreading - using signal in multithread in python -

I am running at the lower extremities in many threads, in each thread, I need to give the thread a signal if it is 5 Idles second for for i category (n): # some networks are transferring work But I found this in Python documentation: if both signals and threads Is used in the same program. The basic thing to remember in using signals and threads is that: In the main thread of execution, the signal always operates. Since the multi thread should not be mixed with the signal, what other options do I leave a loop if it is idles for a very long time?

c++ - capitalizing characters, how toupper works? -

I have to use a character array and the characters must be placed in the array and they need to be capitalized and less case as needed. . I was looking at Tupper and his example, but I'm confused about how it works. Looking at the example given on Cplusplus.com I wrote int main () {int i = 0; Char str [] = "This is an examination."; While (str [i]) {Toucher (toupper (str [i])); I ++; } For (int i = 0; i And there are not two things about it. First of all, the program prints without the bottom coat, this is an exam. Is the screen printed on the screen? (Pushkar's usage has not been explained on the example) but my second and important question is why it does not print still on the bottom of the cout. This is an examination. Can not change the character in str []? Is there another way I should do this (keeping in mind I need to use character arrays)? Yes, caller () for a standard output of a program Prints. This is the purpose of this, it is the source ...

map - In Android, how do you programmatically access a user's default mapping application? -

When you open a link to navigate or find something on the map, then the Android OS asks which application To use the operation, you can make any of these applications "default" so that they do not ask you again in the future. What is a way to retrieve a user's default mapping app programmatically? I want to know how to do this because I switch the user to the map at some point in my app and show them the destination. The same thing to navigate is that I want to use the program that the user has chosen as their default to please them. PS-IOS / WindowsPhone also needs to know the answers if anyone knows that Is the user retrieve the default mapping application as a program? There is no such concept in the geo: URI on structures, such as There may be a default activity for ACTION_VIEW . > I switch the user to the map at some point in my app and show them a destination call startActivity () intent , ACTION_VIEW for destination at code> g...

c++ - setScale in cocos2d for a specific time Xcode -

I am trying to scale a phantom when the user gets extra life and it takes 1 or 2 seconds. I have this: if (_score == 2) {_life = _life + 1; String strLife = StringHelper :: ToString (_life); _labelUpperLifeCounter-> SetString (strLife); _labelUpperScoreLife- & gt; SetScale (2.5f); } This is working but I do not know how to set it up: _labelUpperScoreLife-> setScale (1.7f); Or better to revive it like 2-3 times pulse before going back to normal ... Thanks! I agree that the same is available in C ++. How could I do that obj -c id scaleUp = [duration with CCActionScale proceedings: .1f scale: 2.5f]; Id break = [ccdictiondeal actionwidth: 1f]; ID scaleBack = [Duration with CCActionScaleAt action: .1f scale: 1.7F]; Id seq = [CCActionSequence actions: scaleUp, pause, scaleback, zero]; [_labelUpperScoreLive Action: seq]; Just common thoughts :) Translation in C ++ is your expertise, it will scale the scale, stall a bit, then scale back to the initial stat...

jquery - Handling third-party javascripts quickly, so pages don't appear slow -

I'm doing some testing with today to see if my pages are slowing down loads. The short story is low, I have found that the third party scripts are getting noticeable recession in the shipment. I'm loading them all at the bottom of the page, using the async and see (see). I believe the main reason for the recession is not only to grab the third party files, but in fact to run different scripts, especially side-by-side I want to keep all the scripts, but I want them to be loaded behind the curtains after all the curtains are loaded. , And no noticeable display in the browser is low. For example, I would not like to "stutter" the browser or if I start loading third-party scripts, or many other small annoyances while scrolling down, then jump around. Has anyone ever had this with a good solution? So far I'm thinking that the best option might be to load third-party scripts by using jQuery.getScript (), after all my scripts have expired (literally located bel...

algorithm - Bin packing parts of a dynamic set, considering lastupdate -

A large set of objects is set dynamic: objects can be added or removed at any time. Let's call the total number of objects N Each object has two properties: mass ( m ) and time ( T ) each of them X A small bit of minutes should be selected for processing, which updates its T for the current time. The total of all items in the batch M is limited: no more than L I'm looking to solve three tasks here: Find a Next Batch Object Picking Algorithm; Object Classes Introduction: Simple , Priority (fit at least in each N - batch) and frequently (each Fit into batches); The forecast system capacity exhaust (time to add next server = increase l ). What type of model best describes such a system? The whole thing is about the service that processes "objects" in time intervals. Each object should be "measured" for each N hour. N can be different in one category X is fixed. Objects are added / removed by humans N due to public...