Search Results

Search found 45193 results on 1808 pages for 'select call'.

Page 54/1808 | < Previous Page | 50 51 52 53 54 55 56 57 58 59 60 61  | Next Page >

  • Custom ListView Row, can no longer select rows...

    - by LDK
    Here's my ScrollView: middle: SC.ScrollView.design({ layout: { top: 36, bottom: 32, left: 0, right: 0 }, backgroundColor: '#ccc', contentView: SC.ListView.design({ contentBinding: 'Spanish.wordsController.arrangedObjects', selectionBinding: 'Spanish.wordsController.selection', contentValueKey: "word", contentDisplayProperties: 'word english'.w(), selectOnMouseDown: YES, exampleView: Spanish.CustomListItemView }) }) and here is my custom listView row: Spanish.CustomListItemView = SC.View.extend({ render: function(context, firstTime){ var content = this.get('content'); var word = content.get('word'); var english = content.get('english'); context = context.begin().push('&nbsp;%@ (%@)'.fmt(word,english)).end(); return sc_super(); } }); The above works as expected, except that I can no longer select views. When I comment out "exampleView: Spanish.CustomListItemView" I can select rows, but they are no longer formatted properly. Why can I no longer select rows when I use exampleView?

    Read the article

  • Django: where do I call settings.configure?

    - by RexE
    The Django docs say that I can call settings.configure instead of having a DJANGO_SETTINGS_MODULE. I would like my website's project to do this. In what file should I put the call to settings.configure so that my settings will get configured at the right time? Edit in response to Daniel Roseman's comment: The reason I want to do this is that settings.configure lets you pass in the settings variables as a kwargs dict, e.g. {'INSTALLED_APPS': ..., 'TEMPLATE_DIRS': ..., ...}. This would allow my app's users to specify their settings in a dict, then pass that dict to a function in my app that augments it with certain settings necessary to make my app work, e.g. adding entries to INSTALLED_APPS. What I envision looks like this. Let's call my app "rexe_app". In wsgi.py, my app's users would do: import rexe_app my_settings = {'INSTALLED_APPS': ('a','b'), ...} updated_settings = rexe_app.augment_settings(my_settings) # now updated_settings is {'INSTALLED_APPS': ('a','b','c'), 'SESSION_SAVE_EVERY_REQUEST': True, ...} settings.configure(**updated_settings)

    Read the article

  • gwt - Using List<Serializable> in a RPC call?

    - by Garagos
    I have a RPC service with the following method: public List<Serializable> myMethod(TransactionCall call) {...} But I get a warning when this method is analyzed, and then the rpc call fails Analyzing 'my.project.package.myService' for serializable types Analyzing methods: public abstract java.util.List<java.io.Serializable> myMethod(my.project.package.TransactionCall call) Return type: java.util.List<java.io.Serializable> [...] java.io.Serializable Verifying instantiability (!) Checking all subtypes of Object wich qualify for serialization It seems I can't use Serializable for my List... I could use my own interface instead (something like AsyncDataInterface, wich implements the Serializable interface) but the fact is that my method will return a list custom objects AND basic objects (such as Strings, int....). So my questions are: Is it a standart behaviour? (I can't figure out why I can't use this interface in that case) Does anyone have a workaround for that kind of situation?

    Read the article

  • jQuery plugin call internal function

    - by pbcoder
    I want to call removeSomething() (see in line 9) internally: JS-Code is: (function($){ $.fn.extend({ Engine: function(options) { var defaults = { ... }; var options = $.extend(defaults, options); removeSomething(); //----------------------------------------------------------------------- //Public Functions ------------------------------------------------------ //----------------------------------------------------------------------- this.removeSomething = function() { ... }; } }); })(jQuery); But if I call removeSomething console outputs that removeSomething is not a function, how do I have to call this function? The function should be available internally and externally. Thanks for help!

    Read the article

  • INSERT SELECT Statement and Rollback SQL

    - by Juan Perez
    Im Working on a creation of a query who uses INSERT SELECT statement using MS SQL Server 2008: INSERT INTO TABLE1 (col1, col2) SELECT col1, col2 FROM TABLE2 Right now the excecution of this query is inside a transaction: Pseudocode: try { begin transaction; query; commit; } catch { rollback; } If TABLE2 has around 40m of rows, at the moment of making the insert on the TABLE1, if there is an error in the middle of the INSERT, will the INSERT SELECT statement make a rollback itself or I need to use a transaction to preserve data integrity? It is necessary to use a transaction? or SQL SERVER it self uses a transaction for this type of sentences.

    Read the article

  • jquery ajax call errors in chrome onenter with no responseText

    - by wham12
    I've built a login page that uses a .ajax call to a generic c# handler (.ashx) to validate the username and password before allowing the user to log in. If you click on the login link <a href="#" class="ui-state-default ui-corner-all CustomButton" onclick="goLogin();return false"> the .ajax call returns successfully and it logs the user in. I am trying to make it so the user can also just press the "enter" key from the password box: $("#pword").keydown(function(e) { if (e.keyCode == 13) { goLogin(); } }); Using Firefox, both ways work just fine and the user is logged in. With Chrome however, pressing "enter" hits the error function of my .ajax call and will not log the user in. The parameters and responses look identical through Firefox's console, as expected. What would be causing this and/or how can I debug it in Chrome?

    Read the article

  • How can I clean up this SELECT query?

    - by Cruachan
    I'm running PHP 5 and MySQL 5 on a dedicated server (Ubuntu Server 8.10) with full root access. I'm cleaning up some LAMP code I've inherited and I've a large number of SQL selects with this type of construct: SELECT ... FROM table WHERE LCASE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE( strSomeField, ' ', '-'), ',', ''), '/', '-'), '&', ''), '+', '') ) = $somevalue Ignoring the fact that the database should never have been constructed to require such a select in the first place, and the $somevalue field will need to be parameterised to plug the gaping security hole, what is my best option for fixing the WHERE condition into something less offensive? If I was using MSSQL or Oracle I'd simply put together a user-defined function, but my experience with MySQL is more limited and I've not constructed a UDF with it before, although I'm happy coding C. Update: For all those who've already raised their eyebrows at this in the original code, $somevalue is actually something like $GET['product']—there are a few variations on the theme. In this case the select is pulling the product back from the database by product name—after stripping out characters so it matches what could be previously passed as a URI parameter.

    Read the article

  • How do I style jQuery Combobox to look like a normal select dropdown

    - by Joe T
    Hi everyone. I am making use of jQuery 1.4.4 and jQuery UI 1.8.7 in a legacy code base. I have added a few combobox() ui-widgets, these comboboxes live along side normal <select> dropdowns. I am finding it difficult to get the two elements to look the same, i.e. the unstyled <select> with it's Internet Explorer / Windows based style and the most basic jQuery UI Themed ui-widget combobox. The screenshot shows an unstyled <select> on the left and a jQuery ui-widget combobox on the right: Is it possible to make the two look the same?

    Read the article

  • how to call the javscript funtion ontable row click

    - by kumar
    hi, I have a javascript funtion.. <script type="text/javascript"> var RowClick = function() { $("#mytable").click( $("#showgrid").load('/Products/List/Items/')); }; </script> Can I call this funtion on onclick evnt on tr? I am calling soemthing like this? <tr class="something" onclick="javascript:RowClick()');"> can i call like this? if I call its not loading the URL? can anybody help me out? thanks

    Read the article

  • Combobox select item in dropdown list C#

    - by Willem T
    I have an combobox poppulated with items from a database table. When I change the text i repopulate the combobox with items from the database table. But when I enter text and the list with suggestions opens no item in de list is selected. And i want a item to be selected so when you press enter that it becomes the selected item. This is a winforms application. Thanks. cbxNaam.Items.Clear(); string query = "SELECT bedr_naam FROM tblbedrijf WHERE bedr_naam LIKE '%" + cbxNaam.Text + "%'"; string[] bedrijfsnamen = Functions.DataTableToArray(Global.db.Select(query)); cbxNaam.Items.AddRange(bedrijfsnamen); cbxNaam.Select(cbxNaam.Text.Length + 1, 0);

    Read the article

  • How to limit select items with L2E/S?

    - by orlon
    This code is a no-go var errors = (from error in db.ELMAH_Error select new { error.Application, error.Host, error.Type, error.Source, error.Message, error.User, error.StatusCode, error.TimeUtc }).ToList(); return View(errors); as it results in a 'requires a model of type IEnumerable' error. The following code of course works fine, but selects all the columns, some of which I'm simply not interested in: var errors = (from error in db.ELMAH_Error select error).ToList(); return View(errors); I'm brand spanking new to MVC2 + L2E, so maybe I'm just not thinking in the right mindset yet, but this seems counter-intuitive. Is there an easy way to select a limited number of columns, or is this just part of using an ORM?

    Read the article

  • AS/400 'SELECT 1' Equivalent

    - by bryan_cook
    I'm trying to help a friend troubleshoot connection problems with an AS/400. He'd like to run a query against the AS/400 that will always return a record, (similar to a SELECT 1 against MSSQL). He's attempted running SELECT 1 but without luck ... I'm assuming that the AS/400 expects a FROM TableName ... Can anyone provided assistance? Is there a system table/file that always exists that he can run a SELECT TOP 1 (or it's equivalent) against? I've never interacted with an AS/400 so I'm a bit out of my element ... was hoping SO could give me a quick answer ... Thanks in advance!

    Read the article

  • Make a call in Objective C help!

    - by Henry D'Andrea
    I need to make a call where it says add call here. Can someone help? (BOOL) webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request navigationType:(UIWebViewNavigationType)ntype { NSLog(@"Scheme: %@", request.URL.scheme); if ([request.URL.scheme isEqualToString:@"save"]) { //Add Call here } return true; } FROM this code- (void) save { UIGraphicsBeginImageContext(self.view.frame.size); [self.view.layer renderInContext:UIGraphicsGetCurrentContext()]; UIImage *viewImage = UIGraphicsGetImageFromCurrentImageContext(); UIGraphicsEndImageContext(); UIImageWriteToSavedPhotosAlbum(viewImage, nil, nil, nil); NSLog(@"TEST"); }

    Read the article

  • How can I join this 2 queries?(A select query with join and An unpivot query)

    - by MANG KANOR
    Here are my two queries SELECT EWND.Position, NKey = CASE WHEN ISNULL(Translation.Name, '') = '' THEN EWND.Name ELSE Translation.Name END, Unit = EW_N_DEF.Units FROM EWND INNER JOIN EW_N_DEF ON EW_N_DEF.Nutr_No = EWND.Nutr_No LEFT JOIN Translation ON Translation.CodeMain = EWND.Nutr_no WHERE Translation.CodeTrans = 1 ORDER BY EWND.Position And this is the unpivot one SELECT * FROM (SELECT N1,N2,N3,N4,N5,N6,N7,N8,N9,N10,N11,N12,N13,N14,N15,N16,N17,N18,N19,N20,N21,N22,N23,N24,N25,N26,N27,N28,N29,N30,N31,N32,N33,N34 FROM EWNVal WHERE Code=6035) Test UNPIVOT (Value FOR NUTCODE IN (N1,N2,N3,N4,N5,N6,N7,N8,N9,N10,N11,N12,N13,N14,N15,N16,N17,N18,N19,N20,N21,N22,N23,N24,N25,N26,N27,N28,N29,N30,N31,N32,N33,N34) )AS test Both Queries put out same number of rows but not columns, Is it possible to join this two? I tried the union but it has problems that I cant solve Thanks in advance!

    Read the article

  • Transparent Select/Option text in IE

    - by Valchris
    I've created the JS fiddle to demonstrate my problem: http://jsfiddle.net/C8NUf/1/ HTML: <select> <option> Test </option> <option> Another Test </option> </select> Style: select { color: transparent; } In chrome, the selected text "test" is properly blanked out by setting the color to transparent, in IE the test is still black. How can I fix this issue in IE? Ideally I want to make this change via JQuery, but that doesn't seem very relevant to the overall problem. Thanks, Daniel

    Read the article

  • Is this SQL select code following good practice?

    - by acidzombie24
    I am using sqlite and will port to mysql (5) later. I wanted to know if I am doing something I shouldnt be doing. I tried purposely to design so I'll compare to 0 instead of 1 (I changed hasApproved to NotApproved to do this, not a big deal and I haven't written any code). I was told I never need to write a subquery but I do here. My Votes table is just id, ip, postid (I don't think I can write that subquery as a join instead?) and that's pretty much all that is on my mind. Naming conventions I don't really care about since the tables are created via reflection and is all over the place. select id, name, body, upvotes, downvotes, (select 1 from UpVotes where IPAddr=? AND post=Post.id) as myup, (select 1 from DownVotes where IPAddr=@0 AND post=Post.id) as mydown from Post where flag = '0' limit ?, ?"

    Read the article

  • Select n+1 problem

    - by Arnis L.
    Foo has Title. Bar references Foo. I have a collection with Bars. I need a collection with Foo.Title. If i have 10 bars in collection, i'll call db 10 times. bars.Select(x=x.Foo.Title) At the moment this (using NHibernate Linq and i don't want to drop it) retrieves Bar collection. var q = from b in Session.Linq<Bar>() where ... select b; I read what Ayende says about this. Another related question. A bit of documentation. And another related blog post. Maybe this can help? What about this? Maybe MultiQuery is what i need? :/ But i still can't 'compile' this in proper solution. How to avoid select n+1?

    Read the article

  • JQuery UI (1.8) Select Event not working on Autocomplete

    - by Cyril Gupta
    I am trying to use JQuery UI autocomplete (1.8) for an app. It is set up like this: $('#txtigtags').autocomplete({ serviceUrl: '/tags/searchtags' + $('#txtigtags').val(), minChars: 2, delimiter: ' ', select: function () { alert(''); }, deferRequestBy: 500 }); According to the documentation the select event should fire whenever an entry is selected in the drop-menu and I should get the alert. But the select event is not firing at all. Neither is focus. What am I doing wrong?

    Read the article

  • Binding a select box to a Collection (with Spring)

    - by WiPU
    i have the following problem. I have a form bean and in this bean is a list with objects. List<SomeObjectForm> toDisplay; Now i want map a html select to this list. Something like that: <form:select id="inputGroupFields" path="templateKey" multiple="true"... <form:select id="inputGroupFields" path="templateKey.id" multiple="true"... And this dosnt work of course. Now i have tryed to add different custom Converter like: myConv implements Converter<SomeObjectForm, String> myConv extends StringToObject And this also not work. I'm not sure if this is the right approach or there is a easier way to do that. Some addional Infos: --i'm using spring 3.0.5 --all this happens during a web flow regards and thanks, WiPu

    Read the article

  • how to call the javscript funtion on table row click

    - by kumar
    hi, I have a javascript function.. <script type="text/javascript"> var RowClick = function() { $("#mytable").click( $("#showgrid").load('/Products/List/Items/')); }; </script> Can I call this function on onclick event on tr? I am calling something like this? <tr class="something" onclick="javascript:RowClick()');"> can i call like this? if I call its not loading the URL? can anybody help me out? thanks

    Read the article

  • oracle call stored procedure inside select

    - by CC
    Hi everybody. I'm working on a query (a SELECT) and I need to insert the result of this one in a table. Before doing the insert I have some checking to do, and if all columns are valid, I will do the insert. The checking is done in a stored procedure. The same procedure is used somewhere else too. So I'm thinking using the same procedure to do my checks. The procedure does the checkings and insert the values is all OK. I tryied to call the procedure inside my SELECT but it does not works. SELECT field1, field2, myproc(field1, field2) from MYTABLE. This kind of code does not works. I think it can be done using a cursor, but I would like to avoid the cursors. I'm looking for the easiest solution. Anybody, any idea ? Thanks alot. C.C.

    Read the article

  • JQUERY: Multiplying input elements select box and radio boxes and hidden inputs

    - by Andrew Tan
    Evening, I'm tyring to multiply different input elements but for some reason it's giving me a NAND error. As the user selects, check or modify the values of any element. This should change the total amount. http://jsfiddle.net/aQ5K8/ <select name="select"> <option value="1">1</option> <option value="2">2</option> <option value="3">3</option> </select> <input name="radio" type="radio" id="radio" value="10" tvalue="100" /> <input name="radio" type="radio" id="radio" value="20" tvalue="200" /> <label id="Total"></label> Also if you take a look at the jsfiddle code i have tvalue=100 and the other is =200 as a custom attributes, how would I access that instead of accessing the regular html value. Thank you.

    Read the article

  • HTML select form with option to enter custom value

    - by Ib33X
    I would like to have input field that users can enter custom text value or choose from drop down, normal select only offers drop down options. How can it accept custom value for instance ford? <select> <option value="volvo">Volvo</option> <option value="saab">Saab</option> <option value="mercedes">Mercedes</option> <option value="audi">Audi</option> </select> Edit: I used this http://bit.wisestamp.com/uncategorized/htmljquery-editable-combo-2/ solution. Also I tried jquery ui combobox and it is not working properly

    Read the article

  • Call random function on percents?

    - by Angelena Godkin
    I cannot figure this out. I need a solution to call a random function for it's percent. Ex. there is 10% chances that the script calls subscriptions() and 3% chance that the system call the function "specialitems()". I am stuck in this, so i hope someone can help me with this brainkiller. <?php class RandomGifts { public $chances = ''; public function __construct($user) { $this->user = $user; //Find percent for each function $this->chances = array( 'subscriptions' => 10, // 10% 'specialitems' => 3, // 5% 'normalitems' => 30, // 40% 'fuser' => 50, // 70% 'giftcards' => 7, // 7% ); //This should call the function which has been calculated. self::callFunction(?); } public function subscriptions(){} public function specialitems(){} public function normalitems(){} public function fuser(){} public function giftcards(){} } ?>

    Read the article

  • Swing: Programmatically select a text

    - by HH
    Hey everyone, I have a very simple Swing GUI with just a JTetxtArea. I am trying to programmatically select a part of text using: textArea.select(startSelection,endSelection); This work. However as soon as I add some other components to the GUI I do not see selection anymore frame.getContentPane().add(button); frame.getContentPane().add(textArea); textArea.select(startSelection,endSelection); I suspect that during layouting the gui, some event causes the text to be deselected. Am I right? And could anybody suggest a solution? My goal is to have a program which displays a text, and allows the user to input start and end selection position, and a selection appears between these two position. Thank you.

    Read the article

< Previous Page | 50 51 52 53 54 55 56 57 58 59 60 61  | Next Page >