Posts

Showing posts from September, 2010

How to build .appx file for Windows 8.1 Phone app, in Visual Studio Express? -

Image
I have finished developing my first Windows Phone-Silverlight app and have successfully tested it on the emulator A payment developer account has been created and now I am in the stage of uploading my app, the .appx file is expected in the store, but only in the "Store" menu in Visual Studio Express 2013, only "Launch Windows App Certification Kit" How do I get the rest of the options or if I have another way of exporting such extensions, I can only .xap file in the project's bin / release folder I can see, but the store is not accepting it You accidentally buy windows phone Can be in the Windows Store. The two have now become integrated. Just make sure you submit XAP in the Windows Phone Store and accept it.

laravel - Filtering Eloquent Collection -

Trying to filter the collection object based on any combination of multiple values, as far as I have found Not happening. Any clue for me? Public function search () {$ posts = posting :: All (); $ Type_id = Input :: find ('type_id'); $ Country_id = input :: find ('country_id'); $ Province_id = input :: get ('province_id'); $ Post = $ posts- & gt; Filter (function ($ post) {if (empty! ($ Type_id) & amp; amp; $ type_id> 0) Return to {$ post-> where ('type_id', '=', $ Type_id) ;}}) - & gt; value (); $ Post = $ post- & gt; Filter (function ($ post) {if (empty ($ country_id) & amp; amp; amp; amp; amp; country country & amp; id; $ country_id}}}) & gt; value (); $ Post = $ posts- & gt; Filter (function ($ post) {if (empty! ($ Province_id) & amp; amp; amp; $ province_id> 0) {back to $ post-> where ('province_id', '= ', $ Province_id);}}} - & gt; value (); Return $ post; } Any h...

cmd - Dynamic user home directory on Windows (changing %HOMEDRIVE% and %HOMEPATH%) -

How can I "redirect" (symbolic link?) Or temporarily % HOMEDRIVE% and % HOMEPATH% (Maybe the values ​​which change based on two batch scripts when I start working on the machine and Reset everything later)? Background Many Windows programs either choose a combination of system variable % USERPROFILE% or % HOMEDRIVE% and % HOMEPATH to find out that the user has a "home" directory that needs to be used (like C: \ users \ JohnDoe ). Being a fan of the portable app (see below what I mean), I am thinking that I can make my home directory portable in any way, that is, it is pointing to a directory A portable device or, in other words, I would like to "change it dynamically" I tried that I have read a bit and have tried it : What is the current variable value : C Set East Home Homdaiv = C: HOMEPATH = \ user \ & lt; Username & gt; Set them: C: \ Users \ John doo> Sachs HomeDrive "d:" C: \ Users \ John Do & gt; S...

How to turn off auto-complete block comments in NetBeans in PHP? -

Image
This question is about PHP only, not for Java . When I type / * in Netbeans PHP, block comments are completed when typing in this way: / ** After typing * * / / * or * / , I really do not want to auto-complete any. I know but I could not find any for PHP. Is it possible to turn off this feature? As you can see that he submitted a bug report but scrolling down in the provided link reveals that it is still fine for Java Has been done:

SAS Subquery in Proc Sql -

I have a table that lists libnames and their tables. I would like to create a subquery to return the minimum build number for each listed table, which is used as the libname.table libname.table in the alias I have created the following: proc sql; Select as CREATEDON_FRM from all tables *, select cats ("Select min (createdon)" from "strip (libname)") ". Strip" (table_name) || ")"), where freq = "DAILY" and part_date = "CREATEDON"; No errors have been generated, but created_fm values ​​are not executed, it only creates string values ​​such as "(pvaprov. Select min (createdon) from the institutional). " Oblamben and table are properly resolved, but I get the statement to execute as a subquery You can not dynamically call SQL queries from any other SQL query. Uses datesteps and execes executable to proc SQL and adds result to the base dataset. data wants; length is milked 8; stop; run; data; data_nul...

What is the most efficient way to populate an array based on other information in Javascript? -

I have a note of size 16 in javascript. I have a static 2D array called Tip 11x12 NotoAnmelmapping. Now, in the form of input, I select the user to select any combination of 12 standard notes (C-C # -D-D # -EFF -G-G # -a-A-B-B) I do not, nor at all. Such as "CGG #", or "DD #GAB", or blank etc. PS: For example, I would like to refer to the 2D array and see if Oct. The corresponding numbers for C, G and G # are 0, 7 and 8. Similarly, for October 1, the numbers are 12, 19 and 20. In this fashion continuously, the first 16 numbers are: 0, 7, 8, 12, 19, 20, 24, 31, 32, 36, 43, 44 , 48, 55, 56, 60. > I would like to specify these 16 numbers in my initial note array. My approach I have implemented the 2D array as a 1D array 128 items, where the letter contains the item was 0C All items from item 1 to C # 0 until item 127 (G10) I wanted to use the fact that in the 2D table there was a linear progress from the value 1-127. But I ended up with a nested 3 for t...

testing Spring-Security -

I have many controllers in my Spring-boot (1.1.4.RELEASE) / Spring-Security application that I want However, running some integration tests, I do not know how the authentication is handled to make the request. This is my test: @ContextConfiguration (classes = OFAC, loader = SpringApplicationContextLoader) @ Transaction @WebAppConfiguration @IntegrationTest Class AdminControllerIntegrationTest Specification {def adminUrl = "http: / / / Localhost: 9001 / admin "@Autowired Personal AdminController AdminController Expands; DEF "Testing to retrieve users from DB table" () {def model = Fake (Model) RestTemplate restTemplate = New TestRestTemplate () when: DEF result = restTemplate.getForEntity (adminUrl, String.class, model) Then: Results ! = Null} This is my security configuration: @configuration @ EnableWebMvc security public class ApplicationSecurity WebSecurityConfigurerAdapter Extended {@Autowired Private CustomUserDetailsService customUserDetailsServi...

java - Check mocking call on array of objects -

I am trying to verify whether all the objects in an array are once called once. I am using Powermokito and it is currently done again through objects (layer layer: layers) {Verify (layer, bar (1)). } Is there a more efficient way to check that all the objects in the array are called together once? That is, you can not check a condition for all the objects in any collection or array without recurrence. . It may be possible to hide this information behind the Mockito method call, but still, Mockito will do a repetition to check the status for all your items. If you use your test code more self -When you want to see a legendary view, you can make it a helpful method to reproduce or if you were using Java 8: You can use the stream .for (consumer) .

html - building an outline from a webpage,python -

I am trying to create a function which is to open a URL and create an outline with the HTML code. The framework should include any ... Text between the tags. Just to create an outline from a specific web page Each top level should also be numbered properly, which will have X levels of numbering at the top of Hx. how to start? html has a lot of tags in titles Apart from the link it is to get you started: You need the Sundersoop 4 package and the request for this is requested. Python comes with inbuilt packages for these options, although the above 2 packages make the job very easy. Import BS 4 Import from imported requests BeautifulSoup html = requests.get ("http: //homepage.cs .uiowa.edu/~illillis/166/summer/submission/HW12/Jazz .html "). Text # If you want to parse another url then get () soup = beautiful soup (html, "lxml") print Soup.body this tag html if you want a separate output or something more specific then you will print other c...

ios - Capturing Signature to Core Data -

I have an app that creates a field to sign the name of the user. When I click on save signature, I want to create an image, save it as a PNG, and save it in core data. With the image of the "Pilot Signature" property, this is your unit. - Signature to save (IBAction): (ID) sender) {NSData * ImageData = UIMJPNGRAPanation (MySignat.IJEge); // Create an image object for the new image. NSManagedObject * image = [NSEntityDescription insertNewObjectForEntityForName: @ Managed Object Contains in "Image": self.managedObjectContext]; Self.mySignatureImage = imageData; // Set the image for the image-managed object [Image Set Value: Image of: @ "PilotSignature Image"]; } When I saveSignature Expected Methodist Body And I get on the self.MySignature.image line Incompatible type assigned to "UIImageView" from "NSManagedObject" I I have looked at similar posts about how the image was saved in core data, and I have no luck...

c++ - Better way of using an opaque pointer for Pimpl -

I write a C ++ wrapper library around several hardware libraries for embedded systems (firmware level) using several libraries I am from the different vendors (C or C ++) should be an apiartist, which is the API vendor fronted by the header file ... All Vendor Header Libraries are not included in any of my header files. I have a general pattern that is making the seller member data opaque, using only an "Indicator" seller / struct / class / typedef / pod type for an indicator. // myclass.h class MyClass {... private: vendoring * vendor data; }; and implementation (note: each implementation vendor is specific; all are same * .h file) // myclass_for_vendor_x.cpp #include " Seller ".h" ... {Vendor Data & gt; doSomething (); or Vendor (Seller Data, ...); or whatever I have the problem that vending can be many different things. It can be a class, structure, type or blur, I do not know, and I do not want to care about the header file. If you ch...

javascript - is there a defaultValue property for radio select? -

I'm wondering if there is a way to reset a radio for its basicly selected option The address of defaultValue is, but is there a way to do that I can reset the radio to the page load on its original value? I just do not want to select all the radios > Yes, radio input has default value , but whatever you want is default checked property: $ ('Input [type = radio]'). Prop ('check', function () {return.defaultChecked;}); This is being said, you can use the reset method's HTMLFormElement object if you want to reset the form. : $ ('# formElement'). Get (0) .reset ();

scala - I don't get what should be the C[_] type in Slick 2.1 Query class -

I have just upgraded my skala project to slitch 2.1 and I found a compilation error due to a change in the query category definition. is. It can be found in the query [+ E, U] to query [+ E, U, C [_]] . has been replaced by the I argument as a query type which is defined as the query [link, link] where Link and links case class links (/ * properties / /) class link (tag: tag) table [link ] (Tag, "crawl_arl") {/ * methods * /} I can not find how to declare the C [_] type parameter to compile my method Diff le limit (query: query [link, link, ??], border: it) = The master repository of sealik has a link to the source code of the query class. C [_] is the underlying compilation type that will return slick. It was added to 2.1.0: In your case, you may change your method signature to: def takeLimit ( Query: query [link, link, CEC], border: int) = {/ * stuff * /}

ios - How to add multiline comment in HeaderDoc -

Image
This is my code / ** * Touching: It is believed that It was Succesfull click. Automatically changes to / off images / / @interface WOC_OnOffImageButton: SKSpriteNode and when I type details in pop-in on WOC_OnOffImageButton I click alt-click> I get the in touch: Brinjal: It is believed that it was successfully clicked. I have an automatic change on / off images in the same line. Let me click ... automatically ... , because it's easy to read Questions Yes, AppleDoc supports multinayl comments, here's how you use them: / * * * Brinjal in touch: It is believed that it was succesfull click. * * Automatically changes images on / off * / The key is to keep an asterisk on new lines. To save results in the popup window, save your project ( Cmd + S ) and / or clean ( Cmd + Shift + K ).

html - Make the whole div clickable instead of the links inside of it -

So I'm creating some grids to show the products and instead of the hyperlink, I would like to make the whole tag tag clickable Inside. What would be the best and easiest way to do this? I have found some complex solutions that I am not using because I have many plans, I want to be clickable. Any suggestions are very welcome! You can make the whole divisible clickable rather than just content in it. Just keep in such a way: & lt; A href = "http://www.google.com" & gt; & Lt; Div id = "mydiv" & gt; Blah blah & lt; / Div & gt; & Lt; / A & gt; That's it. Here is JS Friedal:

networking - virtualbox enable network on windows 7 -

I accidentally disabled the Virtualbox network through the Network and Sharing Center and as a result of my virtual machine bad I can find a way to re-enable the network There are two ways to enable virtualbox network adapters. Please tell me to correct this problem You can re-enable it To follow any of them. Go to Network and Sharing Center> & gt; Change the adapter settings (to the left) and select all network adapters related to your VirtualBox, right click and enable them one by one! My Computer (Right-click) ---> Management --- & gt; Device Manager --- & gt; Switch to Network Adapter in Device Manager & gt; All select virtualbox associated adapter and enable them from there . I hope this will help you and reward me with improvement, only if it works.

wordpress - understanding the use of typeof -

I am trying to solve a problem in WordPress and when I am a Noble, I am stumped (Which is the type of part in the last bold). Can someone explain me in simple English? & lt; Input id = "et_pb_number" type = "text" class = "regular-text" value = "& lt;% = typeof (et_pb_number)! == 'undefined'? Et_pb_number: ''%" "/" In my opinion, does this mean that it will check the type of variable (javascript handling) variables (at_pb_number) and see if it is undefined, and then what will happen next? What should I do if I do not want to check the type of value? The surrounding parts are not directly related to typing, is it the expression? When-True: When-False These two are exactly the same: // Ternary form var test = typeof (et_pb_number)! == 'Undefined'? Et_pb_number: ''; Console.log (test); Test // if else block form var; If (typef et_pb_number! == 'undefined') {test = et_pb_n...

vb.net - Three panels, one in the center, other two resize -

Image
So, I'm working on a VB.NET WordPad program. I have three panels in the middle of my panel and there is a rich textbox in the middle panel. Here is an image: Example: || || middle is the actual page [A4] [My size is exact] When I change the size of the WordPad program / max, the side panels all have the same size, although the size of the middle panel varies, but The text box should remain on the left side of the panel. As the text box is covering all, the panel should not be visible, but when its size changes, the text box resides in the same size and the middle panel is visible as it resizes itself on the right The panel panel is like # 1 and remains where it means the same size. Though I'm thinking how I can make a mid panel [while changing shape] and instead of resizing the middle panel, changing the size of both sides panels instead of it || || Its now # 1 | # 2 | # 3 | Sorry for the terrible examples, but hopefully someone will understand thank you Sor...

c# - Create dynamic LINQ query expression at runtime which translates into a parameterized SQL query for nullable types -

This question is related to my I want to make my custom expression for IQueryable in a nutshell. To achieve this goal, I wrote the next code. Public stable IQueryable & lt; T & gt; Filter Aquales & lt; T, TLL & gt; (This IQueryable & lt; T & gt; qSource, expression & lt; Func & lt; t; TLL; Field, TV value) {var fieldFilter = ExpressionClosureFactory.GetField (value); Var constraint = expression. Aqual (field. Body, field filter); Apply Return (qSource, Obstacle, Zone. Parameter); } Private Stable IQueryable & lt; T & gt; Apply & lt; T & gt; (IQueryable & lt; T & gt; qSource, Expression Barrier, ReadOnlyCollection & lt; Parameter Exposure & gt; Parameter) {var predicateFrom = Expression Lambda & lt; Func & lt; T, bool & gt; & Gt; (Hurdle, parameter); Return qSource.Where (predicateFrom); } Public Speaking Expression Clausfactree {Public Status Member Expert Gatefield & lt; TVLUE & gt; (TV va...

jquery - Ajax load page without refresh -

I'm looking for information on what is the easiest way to update page content using jquery + ajax Just want to update the # container content, but not a full page. I am in Ajax. " Thank you. My Jquery Code & script> $ (document) .ready (function () {// $ ('. Line'). Load ('services.html'); $ ('. Nav_link'). Click (function () {var page = $ (this) .attr ('href'); $ ( 'Line'). Load (page); return false;});}); HTML: naval roll = "navigation" square = "nav"> PASLAUGOS & lt; / a & gt; & lt; a class = "nav_link" href = "contacts.html" & gt; div square = "nev _line "& gt; & lt; / div & gt; Contributors & lt; / a & gt; & lt; / nav & gt; & lt; / div & gt; services .html: navel roll = "navigation" category = "nav"> gt; class = "nav_link" "Href =" services.html ...

java - System.in.read conversion to integer not working -

I am trying to create an input class so that it reads faster than the BufferedReader class Could. About me right now, but in some way this code does not work as a purpose. I am basically using the readInt () method of this class, which should read an integer at a time, but what does it do that it reads 1 integer properly, but then It omits the first letter of the second integer INPUT: 1 234 Output: 34 Case 2: Input: 2 3 4 5 6 Output: 4 6 I think the next time the The readInt () method is said to be that it is still reading the new letter of the previous input, but I Only understand why this is happening. Can anyone help me? Import java.io.IOException; Public Class Main {/ ** * @ PRAM RGR * @ Thraze IOException * / Public Static Zero Main (string [] args throws IOException {fast input font = new fast input (); Int T = fi.readInt (); Int [] arr = new int [100]; //System.out.println(- We are here, the value of T is: "+ T); for (int i = 0; i & lt; T; i ++) {arr [...

objective c - Static framework with -"ObjC" -

My project is already importing many third-party structures, and in many "-ObjC" Optimization is required -> Linking -> Other Linker flag tab. Currently, I am trying to add a more stable structure (Osmap SDK), and causes undefined symbols "errors adaptation" architecture i386. Undefined symbols for the architecture are i386: "_BZ2_bzBuffToBuffDecompress", referenced from: - [OSTerrain getDataLoadedForEasting: Answer:] Referenced in OSMap ("OO"), "_OBJC_CLASS _ $ _ RMMapTiledLayerView", in: objc-class-ref Osmap (RMMapView.o) "_OBJC_CLASS _ $ _ RMMarker", refers to: Osjepi (Armmpiovrlewuko.) in objc-class-ref in "Obijesi_elass _ $ _ RM Opanstrektmapasait" Osmpi (Armmapwuko ) Refers to the objection-class-reference in "_OBJC_CLASS _ $ _ RMQuadTree", in: OBJC- Las-ref (Armmapwuko) LD: Architecture of symbol (s) not found I386 Clag: Error: Linker Command Use -V to see EF exit code (invitation with 1)...

c# - Postsharp/Reflection Conflict -

I have 2 basic classes entity and EntityCollection and all of them In the data class underlying entity class constructor, I wanted to call this method: public static zero InitAllCollection (object o) {foreach (var propertyinfo in o.GetType). GetRuntimeProperties ()) {if (PropertyInfo.PropertyType.IS CONSTOCKED GENERIC TYPE [propertyInfo.PropertyType.GetGenericTypeDefinition ()! = TYPE (EntityCollection & lt; & gt;)); Var ctor = propertyInfo.PropertyType.GetTypeInfo (). DeclaredConstructors Where (C =>? C.GetParameters (). Any ()). Select (C = & gt; c) .FirstOrDefault (); PropertyInfo.SetValue (o, ctor.Invoke (new object [0])); }} This method was automatically a member of all the EntityCollection unit, so I do not need to duplicate the code. And everything until I posted the NotifierPropertyChanged aspect to the quickest aspect of the posting that worked fine after that code propertyInfo.SetValue (o, ctor.Invoke ( New object [0])); truing is TargetIn...

javascript - Add WYSIWYG to already existing textareas without losing PHP functionality -

I have some existing forms with text fields for editing. I first retrieve the information from the database, Users can edit them and then update them in the database. The problem is that I have some text from MS Word in the database and I see word formatting in the textware. I tried to use the TinyMCE editor, but it replaces the existing textures with custom code - I lose classname and other things described in my code and do not do anything else. Is there any less WYSIWYG editor that I can apply already in my website without losing the existing functionality? Or are there any ways to change word formatting without using any plug-ins? This is my example form: The text to be edited is inserted into textures by using PHP in the name of TextRe into PHP. While using TinyMCE, Textera no longer exists and hence no text is inserted in it.

jsf - How to close a primefaces push socket connection -

I have a problem with the primhese push I jsf2.2, jetty9.1 with cdi1.2 and primetime 5.0 Use. In my opinion, I connect to a socket The handset message function is called on every push event that works just fine. But I should be able to disconnect from that socket with the AJAX button. & lt; P: commandButton value = "Ajax Discconect" onclick = "disconnectFromSocket ()" /> To stop the connection I could not find a built-in method in the PMFS socket doctor. My idea is to call a Javascript function, if the command button is clicked, which closes the socket connection Unfortunately I do not know how to get open primetime socket connection in javascript And if it is possible to stop them in this way. Any help would be appreciated. / Div>

python - Error when using 'yield' with assert_in in nose -

I am using and produce with assert_in . Here is the code that causes the problem: for lines in rows: produce assert_in, existing_name, row [self.search_field] Error: Failure: Value error (& lt; class; nose.tools.trivial.Dummy '& gt;: testTest has no such test method). Error =============================================== === ============================ Error: Failure: value error (no test method in runTest in 'nose.tools.trivial.Dummy' & gt; is) --- --------------------------------------------- ----- ----------------- Tracebacks (most recent Call final): File "/home/maroun/.virtualenvs/ads_management/local/lib/python2.7/site-packages/nose/loader.py", line 289, yield MethodTestCase generated (test_func, arg = arg , Descriptor = g) File "/home/maroun/.virtualenvs/ads_management/local/lib/python2.7/site-packages/nose/ Case Use", in L 345, __init__ self.inst = self.cls () file In "/usr/lib/python2.7/unittest/case.py",...

powershell - send-mailmessage to send different attachments to different recipients -

Each of them needs to send email to thousands of different recipients with a different attachment. I have a text file with recipients The list and the other text file contains the list of attachment paths. For the first recipient in the text file, the first attachment path must be used. For the second recipient in the text file, the second attachment path should be used. The code below sends all recipients to all recipients separately. But I want to do this as I mentioned above, only one email should be sent to each recipient with the respective recipient. Please tell me whether it is worth achieving. I can also copy recipients and paths for attachment in two different columns of Excel spreadsheet if possible with Excel I create thousands of separate mail-message lines with Excel I can achieve it, but it looks like an ugly way of doing this. This is the reason why I would like to know what is the best way to do this. $ attachments = get content C: \ attach.txt $ recipients...

issue in test classes jar creation(without test classes run only compile) using maven and java -

मेरा जावा प्रोजेक्ट संरचना नीचे जैसा दिखता है MyJavaProject | Src / main / java | > मेरा पोम नीचे उल्लिखित है: मैं कैसे एक परीक्षण मॉड्यूल वर्ग जार और सभी मावेन निर्भरताओं के साथ मुख्य मॉड्यूल वर्ग जार बना सकता हूँ । परीक्षण मॉड्यूल चलाने के बिना (केवल संकलित) मुझे परीक्षण जार प्राप्त करने की आवश्यकता है। मेरे पोम के लिए क्या आवश्यक परिवर्तन और मीवेन कमांड में मुझे उल्लेख करने की आवश्यकता है (या मावेन लक्ष्य को मुझे ग्रहण में उल्लेख करना होगा)। जब मैं लक्ष्य क्षेत्र में जार: टेस्ट-जार (जैसा कि मेरे पाम के अनुसार) प्रयोग किया जाता है, तो कुछ बार सभी कक्षाओं के साथ परीक्षण जार बनाया जाता है, लेकिन कुछ समय में जार में कोई भी वर्ग नहीं होता है। जब मैं कम्पाइल असेंबली: अकेले लक्ष्य क्षेत्र में, हर बार सभी निर्भरताओं के साथ बनाया गया मुख्य मॉड्यूल वर्ग जार हर बार कृपया कोई भी मेरी सहायता कर सकता है। मुझे एक नमूना पॉम की जरूरत है जो मेवेन निर्भरता वाले जावा प्रोजेक्ट संकलित वर्गों के मुख्य, परीक्षण मॉड्यूल बनाता है मुझे जवाब मिला: लक्ष्य के रूप में: mvn...

php - Algorithm to mix any list of string (array) -

I have to find out what is the best algorithm for creating a list of all combinations of an array in PHP. I want all possible combinations of elements in the original array. Duplicate question only seek permutations The difference is that I want to include it, for example, "22", while "22" is not in the element of permutation of this array. Here is an example: Input: 1, 2, 3 Then the output will be Output: 1, 2, 3, 11, 12, 13, 21, 22, 23, 31, 32, 33, 111, 112, 113, 121, 123 ... to 333. This question is different, because this question wants to combine all the combinations of array to a certain length, not all the serials of the array, until a certain length. Specifically, the linked question, for example, "11" or "332" will never return, while the question also seeks to obtain these values ​​as output. This problem can be solved by typing the recursive function, where you can combine an array of combinations with a small ...

sockets - Which technology is the best to inform clients about server events immediately? -

I'm about to make a game first, it will be a browser game, later it will be an APP (Android, iPhone game). On the server side I use Engex, Apache, PPP. ================= I would like to inform online players about various incidents, for example: one user other I am attacking him should inform me about it immediately. Classic AJAX can not be wrong there I have read something about comets, web sockets and some other technologies but I still can not understand what is the best solution for me? Please, help me decide. WebSocket should be the preferred option. This is a widely supported technique. This is a continuous, full duplex connection, which is compatible with all major browsers

PHP find second highest element value in a multidimensional array -

How can I get the second highest element value in a multi-dimensional array? I use this function to get the highest value. But how can I achieve the second highest? function get_max ($ array) {$ max = -999999999; $ Found_item = null; Forex currency ($ array = $ formatted as $ key) {if ($ value ['transaction_no'] & gt; $ max) {$ max = $ value [transaction_no ']; $ Found_item = $ value; }} $ Found_item; } For example, if I call get_max ($ transactions) then I get array number 4 because the highest value is: 5 transaction_no . But how can I get the second highest? For example when i call get_second_max ($ transaction) for I should get array number 3 because it is 4 in transaction_no $ [Transaction] = array ([0] = & gt; array ([transaction_user_id] => 359691e27b23f8ef3f8e1c50315cd506 [transaction_no] => 1 [transaction_total_amount] => 589.00 [TRANSACTION_DATE ] = & Gt; +1335 9 3241 9 [transaction_status] = & gt; canceled) [1] => Array ([T...

FindBugs 3 not working in Eclipse Luna -

I'm trying to use FindBugs 3.0.0 in Eclipse Luna. After installing it, it should be available on the context menu of my java project and under the window -> Preferences -> Java -> Find Bugs. But it's not there. of I have to download it from the place, site updates Market and download the zip and try to install in my Eclipse installation. Do I have to do something else to run it? Greeting Soran I had the same problem running on my Eclipse GVM 6 Searchbugs were not working I switch the Eclipse to GVM 7 and use this fixed problem. For more information on how to change the JVM version that uses extaction, see

Finding the Object Property with the highest value in javascript -

Say I was made an objectively similar ... var indexes = {}; For (var i = 0; i & lt; specchar.length; i ++) {index [specature [i]] = str.indexOf (specchar [i]); } How do I find the property with the highest value? The most effective way to keep track of the maximum value is because your object is being dynamically created: var indexes = {}; Var maxVal = str.indexOf (specchar [0]); // greatest value in var maxKey = ''; // It is important for the largest value (var i = 0; i & lt; specchar.length; i ++) {var val = str.indexOf (specchar [i]); If (Val & gt; Maxwell) {maxVal = val; MAXK = Spectacular [I]; } Index [Specchar [i]] = Well; }

javascript - Limit zoom page -

By using Firefox, the user can maximize the entire webpage by simply pressing CTRL + I want to stop users from zooming in excess of 150%. How can I go about doing this? I tried googling, but I could not find any answer.

api - Running App on Android Studio -

I am very new to Android development and have not just installed Android Studio on my Win7 PC. I have created a simple application that I am trying to run. However, I have no AVD manufactured and the windows are not able to make me any. I have been diluted OK-Button on the AVD build profile and I can not move forward. I tried to install the app on my Android phone but found the following error: Waiting for device Target device: HTC-htc_one_x _- ********* **** File Upload Local Path: C: \ Users \ Manish \ AndroidStudioProjects \ MyFirstApp \ Application \ Construction \ Output \ Apk \ app-debug.apk Remote Path: /data/local/tmp/com.example.manish.myfirstapp Installing com.example.manish.myfirstapp Device Shell Command: at -r "/data/local/tmp/com.example.manish.myfirstapp" pkg installed: /data/local/tmp/com.example.manish. Myfirstapp failure [INSTALL_FAILED_OLDER_SD K] My last problem is that by creating a new AVD screen, only "Android L (preview) - API level L...

javascript - How to intercept COMMAND+V on OSX Safarii? -

I have a function that I use for CTRL + V and COMMAND + V: intercept Function Paste () {clip.val (''). Focus (); // textarea self.oneTime (100, works) (wait for the inserted text in the browser; self.insert (clip.val ()); clip.blur () .val ('');}); } The clip is hidden text, it is hidden from the black div on it (the only way I have found to fix the Andorid). And in the key down event, I call that function: } else if (e.which === 86) {// CTRL + V Paste (); Back true; // I have come true because I am wrong to conclude the // // is incorrect) but it seems that it does not work on MacSacks Safari as you Can check. Does anyone know why this is happening and how to fix it?

php - Site login and session management -

So I'm working on the site for which the "remember me" functionality is entered with a MySQL database Required. I got it right (based on JSPAN's page) I am a little strange, sessions are used to track the user movement I am not worried about their history on the site. I am surrounded by interviews and especially on SO I've seen, but I did not really find what I'm looking for. Maybe I'm not using the right keywords to search anyway ... As I said, I have a real login process, and a cookie has tripled for the "remember me" functionality. But how can the user track the authenticated status while the user is browsing the website? The logged-in user should be able to browse the website's secure area or the script should produce special data, without having to check the "remember me" of the website three times against each page load. I thought of doing something like $ _SESSION ['authed'] == truth, and every page load session w...

how to mix 100+ pictures with python pillow -

Now I try to mix 100+ pictures with a picture (like .png) pillow (kanka pil) I am doing and I know "PIL.Eases Blend (IM1, IM2, Alpha)" can fix all the pictures, though the color of the picture was very light. I want to cure 100+ pictures with color , not transparency (alpha). I know there is another API for fix "PIL.image.cospace (image 1, image2, mask)" but while using it, it was wrong to say something "Im = Image.composite (P, IM," RGBA ")" #What am I using right? p and im API "PIL.Image.open (fp, mode = 'r')" Two open image objects open by file "GA_engine .po ", line 187, test_create in im = Image.composite (P, IM," RGBA ") file" / library / Python 2/7 / site-package / PIL / IDEAS ", line 2313, in the overall image. Paste (Image 1, None, Mask) file "/ Library / Python 2/7 / Site-Package / PIL / Eyes", line 1313, mask in paste. Load () attribute: Error: The 'str...

c# - Send a list of users by email in MVC4 -

I am trying to send a list of users by email. I'm working properly, however My list includes 2 users, only one user is shown when the email is received. This way I am filling out my list, it works fine. list & lt; AccountCourse & gt; AC = new administrative () GetAccountCourseByCourseId (crs.Id); Var ListOfUsers = New List & lt; String & gt; (); Foreach (Accountcars Acer in ATC) {String Username = New Admin} GetAccountByAccountId (acrs.AccountId); ListOfUsers.Add (username); } And likewise, I am trying to fill the body of the e-mail message with the list of users. This is exactly what is not working properly: for (int i = 0; i Any ideas how can I fix this? Thank you. Try this code instead: msg.Body = " Registered users for this course are: "+ string .joined (", ", listoffusor.ORARA) +" "; String.Join will take names of your users and add them using commas and spaces. Give you a single string for your body;...

html - Cannot get two sections next to each other without screwing up other things -

What do I have: I have a top section and a body section (class = " Header "class =" body "respectively) and inside the header section, I have the logo section and menu section. I am trying to put the logo and menu on the same line. What I tried: The result of disappearing in the background for the floating headings section on the left and the second right, changed the width of the logo to 20% and 80% from the menu and Floating them left and right Trying the same results as above: Inline which results is a big mess. Is it possible to get two sections next to each other without disturbing something else? Anyone else can tell what is wrong why is Ans? JSfiddle: Relevant HTML & lt; Body & gt; & Lt; Section square = "header" & gt; & Lt; Section square = "logo" & gt; & Lt; A href = "#" & gt; & Lt; Img src = "logo.png" height = "50px" /> & lt; / A & gt; ...

java - Jackson object mapper exception -

I have written a CGM server there I Jackson object mapper (Not sure I used the library: Jackson-All 1.9 ). The following exception after running org.codehaus.jackson.map.JsonMappingException: No serializer found for the search for classroom materials and a property BeanSerializer (to avoid exceptions, passive SerializationConfig.Feature.FAIL_ON_EMPTY_BEANS)) this adds to disable SerializationConfig.Feature.FAIL_ON_EMPTY_BEANS . ObjectMapper Mapper = New ObjectMapper (); Mapper Configurable (serializationfeature.fel_on_empTiBENs, incorrect); The compilation came again again. SerializationFeature A variable can not be solved. How to solve this? I think I used the wrong library When I was a good example GCM server In addition to changing the key and ID, the only thing I had to do to add it to work was to change the " public class ... "line: @JsonAutoDetect (fieldVisibility = Visibility.ANY) May include Content.java and POST2GCM.java ...

c++ - Class member variable -

I am starting to learn c ++ and as far as I can get, I am the only form of primitive type class members Can find in / P> The following is giving me an error: missing type identifier - int eclipse? class CarManager {public: zero drive (); Private: car car; }; I tried all the combinations that I could think of: car car = new car (); Car * car = new car (); Car and car = new car (); Everyone has their own errors. First of all, car should be defined: before the CarManager definition Add #include "Car.h" . Then, if the car's characteristic is an object (as it is proposed in your example), it should be a default constructor or be started on the Caraminer Creator: Class Employer {Public: Caraminer (): Car (... construction parameters ...) {} // to be transferred to CPP file, of course! Zero drive (); Private: car car; }; Note: If this is an indicator ( car * car; ) or a reference ( car and car; ), Car.h is required to include, a forwarded de...

ios - Swift function with Shorthand Argument Names -

क्या शॉर्टहैंड अर्ग्यूम नाम का उपयोग स्विफ्ट फंक्शन के साथ संभव है? क्लोज़र्स में यह सुविधा है, लेकिन जब से एक फ़ंक्शन स्वयं समापन होता है, तब भी नाम छोड़कर पैरामीटर तक पहुंचने का कोई तरीका हो सकता है। कुछ फ़ंक्शन (param1, {$ 0> $ 1}) आप इस तरह से लघुकथा तर्क नाम के साथ एक बंद को लागू कर सकते हैं: / कोड> बंद करने में पैरामीटर नाम प्रदान करने की कोई आवश्यकता नहीं है, बस $ 0, $ 1 आदि का उपयोग करें। किसी फ़ंक्शन के लिए आप इसे इसी तरह परिभाषित कर सकते हैं: func functionC (int, string) {} परम नामों को छोड़कर कोई कंपाइलर त्रुटि नहीं देता है शायद यह एक तेज सुविधा है तो क्या इसका मतलब यह है कि मैं नाम के बिना पैरामीटर का उपयोग कर सकता हूं। अगर हाँ, तो कैसे? यह एक बग या आधा कार्यान्वित सुविधा हो सकती है क्योंकि अब मैं नहीं कर सकता इसके बारे में दस्तावेज में कुछ भी ढूंढें। फ़ंक्शंस का उपयोग करके आप कंपाइलों का वर्णन करते हैं और ठीक चलते हैं: func functionC (int, string) {println ("function called")} functionC (10, "hello") लेकिन त्रुटि के ...

sublimetext2 - trouble importing folder in python in sublime-text 2 -

I am using Sublime-Lesson 2 for Python and importing a folder as a module . I put a __ init __.py in the folder with that content: __ All __ = ["imsave2", "model_io", "load_data" , "Utils"]; inside the folder where "imsave2", "model_io", "load_data", "utils" are .py files. This system works when using the Python shell, to make the folder importable, by adding the user settings in sublime-lesson-2: "Default_extend_env": {"PYTHONPATH": "/ home / ABC /" / Home / ABC / Vision / Dataset: / Home / ABC / Vision / Code "}, / Pre> The folder / module where I want to import is / home / abc / vision / code / module1 . Although the excellent-text2 is still not in my modules Only you can see.

c# - Best practice to detect a loss of a client in an ASP.NET web application -

This is not a specific coding question, but with years the best practice for a newcomer in web applications is five Enin Telecom software development Experience in I have an ASP.NET web application that collects data from many embedded (Ardino) devices. Push device data from time to time via simple HTTP GET requests. In normal circumstances, each device pushes the data once every 30 seconds However, it is a chance that the device can be lost or the connectivity from the device to the server can be lost to me this condition is 2-3 normal data reporting cycles Will have to find out within. If this was a specific stand-alone C # application, then every time I get data from the device, the expiration set exceeds the timer for the maximum expiration period. , It means that I have not heard from the device for too long and I need to trigger a warning (email or something) from my application. Therefore, the inactivity timer approach is pretty alone-always-specific for non-continuous...

database - What lock type is used in READ COMMITTED isolation level? -

I have found a contradiction in a Wikipedia article and it is not certain where the fault is (or maybe I do it correctly Does not understand). According to the level of isolation: "In the level of this separation, lock-based concurrency control holds the DBMS implementation write locks (acquisition of selected data) / Strong> By the end of the transaction, but when the selection is conducted, the reading locks are released (hence the non-recurring reading event can be at this isolation level, as discussed below Is) " Also read further Read level Rtibddh isolation: Transaction 1: select * from users where id = 1; Transaction 2: The age of SET users = 21 where ID = 1 is updated; COMMIT; Transactions 1: Select * From users where id = 1; COMMIT; According to the first quote, a write-up lock should be taken after the first selection statement in 1 transaction. How to successfully write another transaction lock can get locked and committed if this ...

java - HSQLDB INSERT Value in a Database -

Hi I have problems while inserting data into my database ... string queries = "Include in Gothian (Code, Vert) values ​​(" + code + "," + + + + ")"; SQLConnection sql = new SQLConnection ("Gutscheine.db"); PAS prepared place; Try {ps = sql.con.prepareStatement (query); Int i = ps.executeUpdate (); If (i == -1) {System.out.println ("db error:" + query); }} Hold (SQLException e) {e.printStackTrace (); } Sql.CloseConnection (); // My own Funktion My error: java.sql.SQLSyntaxErrorException: lack of user privilege or object found: org.hsqldb.jdbc On GUTSCHEINE .JDBCUtil.sqlException org.hsqldb.jdbc.JDBCUtil.sqlException (unknown source) org.hsqldb.jdbc.JDBCPreparedStatement is at & lt (unknown source);. Init & gt; (Unknown source) at org.hsqldb.jdbc.JDBCConnection.prepareStatement (org.hsqldb.HsqlException: due to user com.daniel.guthaben.Main.main (Main.java:7) (Gutschein.java33); Unknown source) at com.daniel.guthaben....

Gmail API Users.Messages.get return some messages without any label -

Using the restful API from Gmail, trying to get the message using the operation and some messages empty label (Other parts of the payload are okay). Thanks It looks like expected behavior if they do not have any labels (Like there is not even INBOX), they are all just in the mail (e.g., they have been archived and are in the mailbox etc.).

ruby - Neo4j Batch Inserts -

I batch was used Neo4j API to put a few million records, which will be normally individually, this import has grown very rapidly eliminated but keeps I think I entered millions of records I have something lined up the insertion of Neo4j batch and insert it at the time? If so, how can I see the progress of this queue? I'm counting and I think the records are increasing, but very slow. I am using Nioji gem batch entry () and a batch code insertion is below: User.find_in_batches (Bac_akar: 500) do | Group | $ Neo4j.batch (* group.map {| user | [ "create_unique_node", "user", "id", user.id, user.graph_node_properties]}) Running Neo4j 2.1 Ubuntu 12.04 LTS on Enterprise Edition. Did you shut down correctly batch Insserr after putting his? Are you using Neo4j version and OS? Also make sure that your memory configuration is correct to configure memory-mapping just before the nodestore and the relationship. This is not a line, it is wri...

Assembly Code: If this code runs from its start until the endpoint -

0x40106e & lt; मुख्य + 30 & gt ;: mov $ 0x0,% edx 0x401073 & lt; मुख्य + 35 & gt ;: mov $ 0x0,% ecx 0x401078 & lt; मुख्य + 40 & gt ;: cmp $ 0x9,% ecx 0x40107b & lt; मुख्य + 43 & gt ;: जेले 0x40107f & lt; मुख्य +47 & gt; 0x40107d & lt; मुख्य + 45 & gt ;: jmp 0x401084 & lt; मुख्य + 52 & gt; 0x40107f & lt; मुख्य + 47 & gt ;:% ecx जोड़ें,% edx 0x401081 & lt; मुख्य +49>: inc% ecx 0x401082 & lt; मुख्य + 50 & gt ;: jmp 0x401078 & lt; मुख्य + 40 & gt; 0x401084 & lt; मुख्य + 52 & gt ;: // अंतपॉइंट रजिस्टर में मान ecx & amp; एडीएक्स क्या होगा? कोई मुझे इस कार्यक्रम के माध्यम से कदम कर सकता है। इसके अलावा, मैं इसे ideone.com पर कैसे चला सकता हूं यदि आप इस पर नए हैं, तो आपको चाहिए मानव-पठनीय भाषा में क्या होता है के साथ प्रत्येक पंक्ति का विवरण। इसके अलावा, अनुसरण करने के लिए चीजों को आसान बनाने के लिए लेबल बदलने के लिए शर्मीली मत रहें। मेरे हिस्से पर, मुझे यह पता चला कि & lt; mai...

php xml parser -> Table or OPTION from SELECT -

I'm looking for a way to parse something like this: & Lt; Xml & gt; & Lt; Data & gt; & Lt; Name & gt; Zyx & lt; / Name & gt; & Lt; Price & gt; Xyz & lt; Price & gt; & Lt; / Data & gt; & Lt; Data & gt; & Lt; Name & gt; CBA & lt; / Name & gt; & Lt; Price & gt; ABC & lt; / Pricing & gt; & Lt; / Data & gt; & Lt; / XML & gt; and change it to: & lt; SELECT & gt; & Lt; OPTION VALUE = "xyz" & gt; Zyx & lt; / OPTION & gt; & Lt; OPTION VALUE = "abc" & gt; Cba & lt; / OPTION & gt; & Lt; / Select & gt; Use only php so that if a customer is able to look at my source code they will only see the options selected instead of JS parser (which looks confusing and displays the location of the XML file. Is there a way to do this with PHP? And how to use variable input? Select function ($ tid, $ t, $ xml, $ nam...

html - Execute JQuery Function For Each Element -

I am trying to execute a JQuery function which is empty in the divan for each element (if it is empty). Under the id "answerrr", however, the script will only search for the first part and add text to it, and it will ignore the rest. Maybe I am using the .each () function incorrectly? & lt; B & gt; & Lt; Div id = "answerrr" & gt; & Lt; / Div & gt; & Lt; / B & gt; & Lt; B & gt; & Lt; Div id = "answerrr" & gt; & Lt; P & gt; Not blank & lt; / P & gt; & Lt; / Div & gt; & Lt; / B & gt; & Lt; B & gt; & Lt; Div id = "answerrr" & gt; & Lt; / Div & gt; & Lt; / B & gt; & Lt; Script & gt; $ ('' '' '' '' '' '' '' '($' ' Gt; ') Attachments ($ (this));}}); & Lt; / Script & gt; In addition, if my page has to load more content through Ajax, then how do I go t...

asp.net - How can I hide one user's content from other user? -

Let's have both A and B users, they created an account and now they have their profile page, both users can add, about them Can edit information in When user opens A b's profile page, for example, the page control, add, edit button should not be visible to it. Store user's user ID in session on login. Provide a variable anywhere (such as a base class which extends across all pages). Then on that page, if the User ID matches the login user, show the control otherwise. Do not forget to validate the user ID when submitting user control, because it is possible to inject malicious data into a different user id.

c# - Using yield WaitForSeconds -

I'm asking something which is very clear and I have ignored something, but I have a break before doing it Something I'm trying to make I have seen that it is being used online in many places - yield waiters second (2); Although I get a syntax error, "Error CS 1528: expected; or = (can not specify Constructor logic in declaration) (CS1528 ) (Assembly - CSHRP) Which misleads me as is not really what exactly does yield actually mean or does it, And under the assumption that WaitForSeconds is a class on it in "2" constructor (an announcement Any help will be appreciated thanks! What do you want, an INIMMTR IEnumerator Example () {print (time.time); Return new waiter seconds (5); print (time.time);} Then you will ask: How do I call it? zero start () {print ("start" + time.time); startcartine (wait and print (2.0f) ); Printed T ( "wait and" + time before printing finishes. Time);} INMATTATOR wait and print (float ...

Get a custom attribute with jQuery -

I'm searching for a way to show a div (show-1, show-2, ...) in which Shows a custom attribute (1,2, ...). Everything I tried that did not work ...: ( ... name = "category" size = "1" & gt; ; Option value = "26" show = "1" & gt; Option 1 & lt; / option & gt; Option value = "28" show = "2" & gt; Option 2 & lt; / option & gt; .. ... thanks I id to & lt; select & gt; ; to add to Suggestions, and then depending on how many options you have in your dropdown, please reconsider it for a short while / hidden toggling. HTML & lt; select name = "category" id = "catselect" size = "1"> option 1 JS $ ("# catselect" $ ("visibility "," Visible "); $ (" # show-1 "), CSS (" visibility ", CSS (" visibility "," hidden ");} and if (f.tter (" show ") ==" ...

java - Dispatcher servlet and ResourceHttpRequestHandler conflict -

After the webapp needs to serve static content and the process calls on the other way. In the config I have registered the ResourceHttpRequestHandler and the Dispatcher Servlet. @Override Public Zero addResourceHandlers {ResourceHandlerRegistry registry} {registry.addResourceHandler ("/ index.html") addResourceLocations ("index.html"); } @Bean Public ServletRegistrationBean dispatcherRegistration (DispatcherServlet dispatcherServlet) {ServletRegistrationBean Registration = New ServletRegistrationBean (dispatcherServlet); Registration.setLoadOnStartup (1); Registration.addUrlMappings ("/ left / *"); Return registration; } @Bean (name = "dispatcherServlet") Public DispatcherServlet dispatcherServlet (WebApplicationContext Reference) {New DispatcherServlet (reference) Return; } But the problem is that if I remove the service of the Dispatcher Servlet Resource works, then the Dispatcher Servlet has been registered that the reource handler i...

mongojs - How to dynamically $set a subdocument field in mongodb? -

This question is already an answer here 2 replies I have a situation In where I need to dynamically update the value of a field in a sub-document. Area or may not exist already if it is not in existence, then I want to make Mongo to make it. Here is an example document that will be found in my teams collection, which is used to store members of any team: {_ id: ObjectId ('JKS78678923SDFD678'), name: "Bob Lawblaw", status: "administrator", option: {one: "one", two: "two options and using the query here (I am using my own Mongo client) code> Sub-document: var projectID = 'JKS78678923SDFD678'; Var key = 'three'; Va Update: {$ set: {option [key]: value}}, upsert: true, multi: false, r value = 'three'; Teams.findAndModify ({query}: {projectID: mongojs.ObjectId (projectID)}, New: True}, function (error, result, last error object) {console.log (result);}); But I can not get it up to '...

vba - Scoped to be visible to any module but not outside the VBAProject -

I have these functions: function funcX () integer funcX = 2 end function Func funkY = 3 end function as funnier () function as a function in In a separate workbook, I can run the following to reach both of the above: I How can I create a function that has been scotched, its car Is available in all modules of the manual, but it is not available outside of the workbook? To make routine routine in private modules for regular VBA projects, make them public Announce and add statement: option private module module header. Look for other ideas for controlling the visibility of the VBA routine.