Search Results

Search found 954 results on 39 pages for 'george katsanos'.

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

  • 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

  • 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

  • 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

  • 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

  • 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

  • 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

  • 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

  • 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

  • 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

  • <Control>.Focus() from server side doesn't scroll into view

    - by George
    Custom Validation Control: <asp:CustomValidator ID="valSex" runat="server" ErrorMessage="1.2 &lt;b&gt;Sex&lt;/b&gt; not specified" EnableClientScript="true" ClientValidationFunction="ValidateSex" SetFocusOnError="True">Selection required</asp:CustomValidator> Client Side validation routine: function ValidateSex(source, args) { var optMale = document.getElementById("<%=optMale.ClientID %>"); var optFemale = document.getElementById("<%=optFemale.ClientID %>"); if (!optMale.checked && !optFemale.checked) { args.IsValid = false; optMale.focus(); } else args.IsValid = true; } When the page is submitted and Sex is not specified, focus is set but the 2 radio buttons are not quite in view, vertical scrolling is required to bring them into view. Shouldn't the Focus() method have brought the focus control into view?

    Read the article

  • MySQL table with similar column info - HELP!!!

    - by George Garman
    I have a DB with a table that is named "victim". The form that dumps the info into the table has room for two victims and therefore there is vic1_fname, vic1_lname, vic2_fname, vic2_lname, etc.. (business name, person first, person last, address, city, state, zip) a "1" and "2" of each. Now I want to search the DB and locate listed victims. This is what I have so far: $result = mysql_query( "SELECT victim.* FROM victim WHERE vic1_business_name OR vic2_business_name LIKE '%$search_vic_business_name%' AND vic1_fname OR vic2_fname LIKE '%$search_vic_fname%' AND vic1_lname OR vic2_lname LIKE '%$search_vic_lname%' AND vic1_address OR vic2_address LIKE '%$search_vic_address%' AND vic1_city OR vic2_city LIKE '%$search_vic_city%' AND vic1_state OR vic2_state LIKE '%$search_vic_state%' AND vic1_dob OR vic2_dob LIKE '%$search_vic_dob%' "); <table width="960" style="border: groove;" border=".5"> <tr><th colspan=10>You search results are listed below:</th></tr> <tr> <th>Case Number</th> <th>Business Name</th> <th>First Name</th> <th>Last Name</th> <th>DOB / Age</th> <th>Address</th> <th>City</th> <th>State</th> </tr> <?php while($row = mysql_fetch_array($result)) { ?> <tr> <td align="center"><?php print $row['vic_business_name']; ?></td> <td align="center"><?php print $row['vic_fname']; ?></td> <td align="center"><?php print $row['vic_lname']; ?></td> <td align="center"><?php print $row['vic_dob']; ?></td> <td align="center"><?php print $row['vic_adress']; ?></td> <td align="center"><?php print $row['vic_city']; ?></td> <td align="center"><?php print $row['vic_state']; ?></td> </tr> <?php } ?> </table> The info did not display in the table until I changed the table to this: <tr> <td align="center"><?php print $row['vic1_business_name']; ?></td> <td align="center"><?php print $row['vic1_fname']; ?></td> <td align="center"><?php print $row['vic1_lname']; ?></td> <td align="center"><?php print $row['vic1_dob']; ?></td> <td align="center"><?php print $row['vic1_adress']; ?></td> <td align="center"><?php print $row['vic1_city']; ?></td> <td align="center"><?php print $row['vic1_state']; ?></td> </tr> <tr> <td align="center"><?php print $row['vic2_business_name']; ?></td> <td align="center"><?php print $row['vic2_fname']; ?></td> <td align="center"><?php print $row['vic2_lname']; ?></td> <td align="center"><?php print $row['vic2_dob']; ?></td> <td align="center"><?php print $row['vic2_adress']; ?></td> <td align="center"><?php print $row['vic2_city']; ?></td> <td align="center"><?php print $row['vic2_state']; ?></td> </tr> Now it displays both rows, even if its empty. It doesn't matter if the victim was listed originally as vic1 or vic2, i just want to know if they are a victim. I hope this makes sense. I can't get it to display the way I want, line-by-line, irregardless of whether you are vic1 or vic2.

    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

  • From client, force whole page validation

    - by George
    I have an ASP button for which I have set the OnClientClick property to display a javascript confirm message. However, I only want this message to be displayed AFTER all of the client side validations have passed. How can I do this? Essentially, I believe that I need to force Page level validation from the client and then, only if it passes, display the confirmation box.

    Read the article

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