Search Results

Search found 959 results on 39 pages for 'george kas'.

Page 28/39 | < Previous Page | 24 25 26 27 28 29 30 31 32 33 34 35  | Next Page >

  • How to compile a Windows binary in Ubuntu?

    - by George Edison
    I have a Qt application that I can compile in Ubuntu 10.04 64-bit and on Windows. However, I would like to avoid switching to Windows every time I want to compile the Windows version. Is there a way I can compile a Windows Qt executable in Ubuntu with mingw32 or something? Further, is there a way to integrate that compiler into Qt Creator?

    Read the article

  • Can't append to second container

    - by George Katsanos
    I have the following script: (function($) { $.fn.easyPaginate = function(options){ var defaults = { step: 4, delay: 100, numeric: true, nextprev: true, controls: 'pagination', current: 'current' }; var options = $.extend(defaults, options); var step = options.step; var lower, upper; var children = $(this).children(); var count = children.length; var obj, next, prev; var page = 1; var timeout; var clicked = false; function show(){ clearTimeout(timeout); lower = ((page-1) * step); upper = lower+step; $(children).each(function(i){ var child = $(this); child.hide(); if(i>=lower && i<upper){ setTimeout(function(){ child.fadeIn('fast') }, ( i-( Math.floor(i/step) * step) )*options.delay ); } if(options.nextprev){ if(upper >= count) { next.addClass('stop'); } else { next.removeClass('stop'); }; if(lower >= 1) { prev.removeClass('stop'); } else { prev.addClass('stop'); }; }; }); $('li','#'+ options.controls).removeClass(options.current); $('li[data-index="'+page+'"]','#'+ options.controls).addClass(options.current); if(options.auto){ if(options.clickstop && clicked){}else{ timeout = setTimeout(auto,options.pause); }; }; }; function auto(){ if(upper <= count){ page++; show(); } else { page--; show(); } }; this.each(function(){ obj = this; if(count>step){ var pages = Math.floor(count/step); if((count/step) > pages) pages++; var ol = $('<ol id="'+ options.controls +'" class="pagin"></ol>').insertAfter(obj); if(options.nextprev){ prev = $('<li class="prev">prev</li>') .appendTo(ol) .bind('click', function() { //check to see if there are any more pages in the negative direction if (page > 1) { clicked = true; page--; show(); } }); } if(options.numeric){ for(var i=1;i<=pages;i++){ $('<li data-index="'+ i +'">'+ i +'</li>') .appendTo(ol) .click(function(){ clicked = true; page = $(this).attr('data-index'); show(); }); }; }; if(options.nextprev){ next = $('<li class="next">next</li>') .appendTo(ol) .bind('click', function() { //check to see if there are any pages in the positive direction if (page < (count / 4)) { clicked = true; page++; show(); } }); } show(); }; }); }; })(jQuery); jQuery(function($){ $('ul.news').easyPaginate({step:4}); }); which is a carousel-like plugin that produces this html structure for the navigation: <ol id="pagination" class="pagin"><li class="prev">prev</li><li data-index="1" class="">1</li><li data-index="2" class="">2</li><li data-index="3" class="current">3</li><li class="next stop">next</li></ol> And all I want is to enclose this list in a div. Seems simple, but appendTo doesn't want to cooperate with me, or I'm doing something wrong (I'd appreciate if you would help me understand what that is..) So I'm modifying as such: var ol = $('<ol id="'+ options.controls +'" class="pagin"></ol>'); var tiv = $('<div id="lala"></div>'); ol.appendTo('#lala'); tiv.insertAfter(obj); I know how to chain, but I'm in "debugging" mode trying to understand why I don't get the result I imagine I would get: <div id="lala> <ol id="pagination><li>...... </li></ol> </div> I tried putting some console.log's to see the status of my variables but couldn't find something useful.. I guess there's something with DOM insertion I don't get.

    Read the article

  • Is it wise to rely on default features of a programming language?

    - by George Edison
    Should I frequently rely on default values? For example, in PHP, if you have the following: <?php $var .= "Value"; ?> This is perfectly fine - it works. But what if assignment like this to a previously unused variable is later eliminated from the language? (I'm not referring to just general assignment to an unused variable.) There are countless examples of where the default value of something has changed and so much existing code was then useless. On the other hand, without default values, there is a lot of code redundancy. What is the proper way of dealing with this?

    Read the article

  • Close all HTML unclosed IMG tags

    - by George Johnston
    Is it possible to do a regex replace on all IMG tags that are unclosed? If so, how would I identify: <img src="..." alt="..."> ...as a potential canidate to be replaced? = <img src="..." alt="..."/> Update: We have hundreds of pages, and thousands of image tags, all must of which must be closed. I'm not stuck on RegEx -- any other method, aside from manually updating all IMG tags, would suffice.

    Read the article

  • Deleting Row Method on GridView

    - by George
    I am trying to implement the deleting method and pass my parameters for the delete operation. I am using sqldatasource. Since the ID doesnt have a column in my gridview how can I get the value of the ID and set it as my delete parameter?

    Read the article

  • Multiple Regex on String

    - by George
    How can I apply multiple regexs to a single string? For instance, a user inputs the following into a text area: red bird blue cat black dog and I want to replace each carriage return with a comma and each space with an underscore so the final string reads as red_bird,blue_cat,black_dog. I've tried variations in syntax along the lines of the following so far: function formatTextArea() { var textString = document.getElementById('userinput').value; var formatText = textString.replace( new RegExp( "\\n", "g" ),",", new RegExp( "\\s", "g"),"_"); alert(formatText); }

    Read the article

  • MySQL Accept Any Password

    - by George
    Suppose that I have a test server with a large group of test accounts. The test accounts have unknown passwords which are hard-coded into the application's reports and are stored encrypted in the mysql.users table. Is there any option or hack which can be used to make mysql accept any text as the "correct" password for an account? For example: Update mysql.user Set Password="*" where 1=1 Note: The above line wouldn't work because it would literally set the password to "*" and not the wildcard character. However, I am looking for a way to create a mysql account which would accept anything as a valid password. This machine is disconnected from the network and I have full access to the mysql database...

    Read the article

  • Help with validation rules

    - by George Garman
    I am trying to figure out how to validate a section of a form using php. If at least one of value 1-5 is checked, then at least one of value A-E must be checked. Value's A-E cannot be allowed without at least one of 1-5 being checked. Multiple values in each section can be selected, as long as there is at least one value in each section checked. I have tried individual IF statements and arrays without success. Does anyone have any suggestions or examples? I am missing something and I am certain it is pretty obvious, right in my face.

    Read the article

  • What do you think of Visual Studio 2010?

    - by George Edison
    Since it came out a few days ago, I am sure at least some members of SO had a chance to try it out. For those that did, I wonder if you could share the following: Whether you liked/disliked it What you liked/disliked Whether it's worth upgrading To ensure fairness (and to make the mods happy) I will make this CW.

    Read the article

  • VS2010: New and improved Intellisense?

    - by George
    In VB.NET type this on a new line: DateAdd( Shouldn't a dropdown picklist of enum values appear? It used to! I miss it! Of course, this is just one example where an enum pick list does not appear where it did before. Can anyone defend this or is it a bug?

    Read the article

  • git clone with ssh issue

    - by george
    Hi, I have generated a public key, private key pair. I've set the public key to the site. How to use the console in windows to clone a git repository? What do I do with the private key? I keep getting: the remote end hung up unexp. Thanks

    Read the article

  • Counter variable for class

    - by George
    I am having problem getting this piece of code to run. The class is Student which has a IdCounter, and it is where the problem seems to be. (at line 8) class Student: def __init__(self): # Each student get their own student ID idCounter = 0 self.gpa = 0 self.record = {} # Each time I create a new student, the idCounter increment idCounter += 1 self.name = 'Student {0}'.format(Student.idCounter) classRoster = [] # List of students for number in range(25): newStudent = Student() classRoster.append(newStudent) print(newStudent.name) I am trying to have this idCounter inside my Student class, so I can have it as part of the student's name (which is really an ID#, for example Student 12345. But I have been getting error. Traceback (most recent call last): File "/Users/yanwchan/Documents/test.py", line 13, in <module> newStudent = Student() File "/Users/yanwchan/Documents/test.py", line 8, in __init__ idCounter += 1 UnboundLocalError: local variable 'idCounter' referenced before assignment I tried to put the idCounter += 1 in before, after, all combination, but I am still getting the referenced before assignment error, can you explain to me what I am doing wrong? Thank you Edit: Provided the full code I have

    Read the article

  • Using webbrowser component to click button's website.

    - by George Tas
    I have seen some examples but nothing works for my problem. Say you have in a website this html code. <button onclick="searchClick();" value="SomeValue" type="button" class="submitBtn"><span>Some Button Text</span></button> How can i retrieve this and perform click using the WebBrowser .NET Component in winforms? Can't get nothing with GetElementById...or can't seem to find how to use the GetElementsByTag... Any help appreciated.

    Read the article

  • Implementing inotifycollectionchanged interface

    - by George
    Hello, I need to implement a collection with special capabilities. In addition, I want to bind this collection to a ListView, Therefore I ended up with the next code (I omitted some methods to make it shorter here in the forum): public class myCollection<T> : INotifyCollectionChanged { private Collection<T> collection = new Collection<T>(); public event NotifyCollectionChangedEventHandler CollectionChanged; public void Add(T item) { collection.Insert(collection.Count, item); OnCollectionChange(new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add, item)); } protected virtual void OnCollectionChange(NotifyCollectionChangedEventArgs e) { if (CollectionChanged != null) CollectionChanged(this, e); } } I wanted to test it with a simple data class: public class Person { public string GivenName { get; set; } public string SurName { get; set; } } So I created an instance of myCollection class as follows: myCollection<Person> _PersonCollection = new myCollection<Person>(); public myCollection<Person> PersonCollection { get { return _PersonCollection; } } The problem is that the ListView does not update when the collection updates although I implemented the INotifyCollectionChanged interface. I know that my binding is fine (in XAML) because when I use the ObservableCollecion class instead of myCollecion class like this: ObservableCollection<Person> _PersonCollection = new ObservableCollection<Person>(); public ObservableCollection<Person> PersonCollection { get { return _PersonCollection; } } the ListView updates What is the problem?

    Read the article

< Previous Page | 24 25 26 27 28 29 30 31 32 33 34 35  | Next Page >