Search Results

Search found 1496 results on 60 pages for 'adam hart'.

Page 40/60 | < Previous Page | 36 37 38 39 40 41 42 43 44 45 46 47  | Next Page >

  • jQuery or CSS - How do you make a link in a table row appear underlined even when the cursor is in a

    - by adam
    I have a table of 3-4 columns, the central one being task names that are also links(yet another todo app..groan). Im trying to make it so that whenever the mouse hovers over any part of the table row - not just the link itself - the link will appear underlined. Its a small detail but its been annoying me like hell and i refuse to let it get the better of me now. At first i tried jQuery with a (forgive the obvious syntax errors but this is the jist) $('#row_in_question').hover( function(){ $(this).find(...the link..).toggleClass("highlighted") }, function(){ $(this).find(...the link..).toggleClass("highlighted") } ); with this as a styling for the a element in general .highlighted { text-decoration: underlined; } and it did indeed toggle the highlighted class on that link - however css inheritance got in the way and no visual changes made. Since i previously styled that link to have no underline when not hovered it wouldnt change the style. So how do i go about this? I dont want the whole row to become clickable, I just want the text to become underlined.

    Read the article

  • Using drawAtPoint with my CIImage not doing anything on screen

    - by Adam
    Stuck again. :( I have the following code crammed into a procedure invoked when I click on a button on my application main window. I'm just trying to tweak a CIIMage and then display the results. At this point I'm not even worried about exactly where / how to display it. I'm just trying to slam it up on the window to make sure my Transform worked. This code seems to work down through the drawAtPoint message. But I never see anything on the screen. What's wrong? Thanks. Also, as far as displaying it in a particular location on the window ... is the best technique to put a frame of some sort on the window, then get the coordinates of that frame and "draw into" that rectangle? Or use a specific control from IB? Or what? Thanks again. // earlier I initialize a NSImage from JPG file on disk. // then create NSBitmapImageRep from the NSImage. This all works fine. // then ... CIImage * inputCIimage = [[CIImage alloc] initWithBitmapImageRep:inputBitmap]; if (inputCIimage == Nil) NSLog(@"could not create CI Image"); else { NSLog (@"CI Image created. working on transform"); CIFilter *transform = [CIFilter filterWithName:@"CIAffineTransform"]; [transform setDefaults]; [transform setValue:inputCIimage forKey:@"inputImage"]; NSAffineTransform *affineTransform = [NSAffineTransform transform]; [affineTransform rotateByDegrees:3]; [transform setValue:affineTransform forKey:@"inputTransform"]; CIImage * myResult = [transform valueForKey:@"outputImage"]; if (myResult == Nil) NSLog(@"Transformation failed"); else { NSLog(@"Created transformation successfully ... now render it"); [myResult drawAtPoint: NSMakePoint ( 0,0 ) fromRect: NSMakeRect ( 0,0,128,128 ) operation: NSCompositeSourceOver fraction: 1.0]; //100% opaque [inputCIimage release]; } }

    Read the article

  • Re-ordering collection C#

    - by Adam
    Hi - I have a problem which I cant seem to find answer to through searches (either that or I am searching for the completely wrong thing!). I have a list of items called "Top 10" in a sortedlist item that is populated from my DB (SortedList where int is position and string is item). I want to be able to move items up & down the list order at the click of a button and then save the new order back to the DB. I am OK with the DB part it is just the re-ordering I am really struggling with - is a sortedlist the correct collection for this? Many thanks for any advice offered.

    Read the article

  • Where should document-related actions for a Cocoa app be implemented?

    - by Adam Preble
    I'm writing a document-based Cocoa app that's basically a graphical editing program. I want the user to be able to show/hide non-modal windows (such as an inspector window). Since these windows would be shown/hidden from menu items, where is the "best" place to implement the actions, such as - (IBAction)toggleInspector:(id)sender? I've seen that in the Sketch example code these are implemented in the app delegate, and the window controller instances are kept there as well, but that feels like more of a convenient place to put it than the most "graceful" place. Additionally, since this inspector would only be relevant when a document is open it feels like it should be associated more with the document's main NSWindowController than the app.

    Read the article

  • GetAccessControl error with NTAccount

    - by Adam Witko
    private bool HasRights(FileSystemRights fileSystemRights_, string fileName_, bool isFile_) { bool hasRights = false; WindowsIdentity WinIdentity = System.Security.Principal.WindowsIdentity.GetCurrent(); WindowsPrincipal WinPrincipal = new WindowsPrincipal(WinIdentity); AuthorizationRuleCollection arc = null; if (isFile_) { FileInfo fi = new FileInfo(@fileName_); arc = fi.GetAccessControl().GetAccessRules(true, true, typeof(NTAccount)); } else { DirectoryInfo di = new DirectoryInfo(@fileName_); arc = di.GetAccessControl().GetAccessRules(true, true, typeof(NTAccount)); } foreach (FileSystemAccessRule rule in arc) { if (WinPrincipal.IsInRole(rule.IdentityReference.Value)) { if (((int)rule.FileSystemRights & (int)fileSystemRights_) > 0) { if (rule.AccessControlType == AccessControlType.Allow) hasRights = true; else if (rule.AccessControlType == AccessControlType.Deny) { hasRights = false; break; } } } } return hasRights; } The above code block is causing me problems. When the WinPrincipal.IsInRole(rule.IdentityReference.Value) is executed the following exception occurs: "The trust relationship between the primary domain and the trusted domain failed.". I'm very new to using identities, principles and such so I don't know what's the problem. I'm assuming it's with the use of NTAccount? Thanks

    Read the article

  • How to determine where a Mailitem is being opened from in Outlook 2007 using VSTO 2005 SE

    - by Adam
    I have an Outlook 2007 Add-in in VSTO 2005 SE that allows users to save e-mails into our document management system. From within our system users are able to open e-mails they have previously saved. However, when doing so I need to try and prevent them from saving them again. I am trying to figure out how to determine if the Mailitem being opened is coming from the Outlook e-mail client or from an external source. I know that normally the EntryId Property of the Mailitem is null or empty string when a Mailitem has not been previously saved in Outlook, however, it seems like when a Mailitem is being opened from within our system the EntryID is not null.

    Read the article

  • Using cProfile results with KCacheGrind

    - by Adam Luchjenbroers
    I'm using cProfile to profile my Python program. Based upon this talk I was under the impression that KCacheGrind could parse and display the output from cProfile. However, when I go to import the file, KCacheGrind just displays an 'Unknown File Format' error in the status bar and sits there displaying nothing. Is there something special I need to do before my profiling stats are compatible with KCacheGrind? ... if profile: import cProfile profileFileName = 'Profiles/pythonray_' + time.strftime('%Y%m%d_%H%M%S') + '.profile' profile = cProfile.Profile() profile.run('pilImage = camera.render(scene, samplePattern)') profile.dump_stats(profileFileName) profile.print_stats() else: pilImage = camera.render(scene, samplePattern) ... Package Versions KCacheGrind 4.3.1 Python 2.6.2

    Read the article

  • .NET Multipage Tiff with Lossy Compression

    - by Adam Berent
    I need a way to take several jpgs and convert them into a single multi page Tiff. I have that working using GDI+ however it only works with the compression LZW which is lossless. This means that my 3 50KB Jpgs turn into 3MB multipage Tiff file. This is not something I can accept for the software that I am working on. I know that Tiff Image format can use a JPG compression scheme but GDI+ does not seem to support this. If anyone knows how to do this in .NET (C#) or of any component that does this conversion.

    Read the article

  • What is the point of a constant in C#

    - by Adam
    Can anyone tell what is the point of a constant in C#? For example, what is the advantage of doing cosnt int months = 12; as opposed to int months = 12; I get that constants can't be changed, but then why not just... not change it's value after you initialize it?

    Read the article

  • iphone sdk - why is the video returned not full res?

    - by ADAM
    im developing an app for the iphone and im able to get a video using a UIImagePickerController the problem is that the video thats returned by the UIImagePickerControllerMediaURL is not full resoultion -- its only 480 x 360 as opposed to 640 x 480 like the videos that sync to my itunes. -please someone tell me this is not a limitation of the current sdk? - how can i work around it and is there a way to set the uiimage picker so its taking full res video?

    Read the article

  • How to get rid of g++ hash_map deprecation warning?

    - by Adam
    When I compile a c++ application I'm writing that makes use of hash_map, I get this warning on g++ 4.3.2: You are using the deprecated header . To eliminate this warning, use an ANSI-standard header file or use hte -Wno-deprecated compiler flag. 9> #include <ext/hash_map> What include replaces this? I've searched for a while on google, and can't find anything except for people having similar problems, but no solution.

    Read the article

  • OOP C# Question: Making a Fruit a Pear

    - by Adam Kane
    Given that I have an instance of Fruit with some properties set, and I want to get those properties into a new Pear instance (because this particular Fruit happens to have the qualities of a pear), what's the best way to achieve this effect? For example, what we can't do is simple cast a Fruit to a Pear, because not all Fruits are Pears: public static class PearGenerator { public static Pear CreatePear () { // Make a new generic fruit. Fruit genericFruit = new Fruit(); // Upcast it to a pear. (Throws exception: Can't cast a Fruit to a Pear.) Pear pear = (Pear)genericFruit; // Return freshly grown pear. return ( pear ); } } public class Fruit { // some code } public class Pear : Fruit { public void PutInPie () { // some code } } Thanks! Update: I don't control the "new Fruit()" code. My starting point is that I've got a Fruit to work with. I need to get that Fruit into a new Pear somehow. Maybe copy all the properties one by one?

    Read the article

  • C# / IronPython Interop with shared C# Class Library

    - by Adam Haile
    I'm trying to use IronPython as an intermediary between a C# GUI and some C# libraries, so that it can be scripted post compile time. I have a Class library DLL that is used by both the GUI and the python and is something along the lines of this: namespace MyLib { public class MyClass { public string Name { get; set; } public MyClass(string name) { this.Name = name; } } } The IronPython code is as follows: import clr clr.AddReferenceToFile(r"MyLib.dll") from MyLib import MyClass ReturnObject = MyClass("Test") Then, in C# I would call it as follows: ScriptEngine engine = Python.CreateEngine(); ScriptScope scope = null; scope = engine.CreateScope(); ScriptSource source = engine.CreateScriptSourceFromFile("Script.py"); source.Execute(scope); MyClass mc = scope.GetVariable<MyClass>("ReturnObject ") When I call this last bit of code, source.Execute(scope) runs returns successfully, but when I try the GetVariable call, it throw the following exception Microsoft.Scripting.ArgumentTypeException: expected MyClass , got MyClass So, you can see that the class names are exactly the same, but for some reason it thinks they are different. The DLL is in a different directory than the .py file (I just didn't bother to write out all the path setup stuff), could it be that there is an issue with the interpreter for IronPython seeing these objects as difference because it's somehow seeing them as being in a different context or scope?

    Read the article

  • What is the best way to organize object oriented code?

    - by Adam
    I haven't coded in java for a long time, and after coding in C, I'm having issued organizing my code for OOP. More specifically I'm not sure when to create a new method, and when to create a new class, and when to just lump everything together. Are there some general rules or guidelines on how it should be done?

    Read the article

  • Using Wordpress as more than just a blog?

    - by Adam
    I have been making plans to create a site that would contain several different sections, such as several blog feeds for reviews and articals, a forum, and also a stock site where people can sell/buy photos. I was planning on doing this in PHP, but have recently started using wordpress and found it to be very powerful. is a site like this too "advanced" to be done in wordpress?

    Read the article

  • iPad Camera Connection kit?

    - by Adam
    Does anyone know if it is possible to access the iPad's camera connection kit? I would like to read the files off the connected mass storage device. Would this be possible or is this something that only Apple can do in there apps. Thanks

    Read the article

  • change color of red box on tri-state checkbox

    - by Adam S
    Hi all. I'm trying to get the green box that appears on the second click of a tri-state checkbox to be red, and also to fill up the box. I found an article here that demonstrates a little bit about using templates to do this: http://social.msdn.microsoft.com/Forums/en-US/wpf/thread/98cf8a65-f4ca-4ff5-9851-c2989b91a013 However, I can't figure out how to interpret all that. I only understand a few of the things in that template and don't know how to get my red box. Can anyone help, and also tell me how you knew what to do?

    Read the article

  • Reload Document into Google Docs Viewer (Clear Cache)

    - by Adam
    Google Docs Viewer (http://docs.google.com/viewer) creates a cache of a document after the first viewing. To see what I mean, try the following: Upload file.pdf to your server (i.e., http://example.com). Visit http://docs.google.com/viewer?url=http://example.com/file.pdf Upload a new file to replace file.pdf (but use the same name). Revisit http://docs.google.com/viewer?url=http://example.com/file.pdf. Google Docs Viewer still shows the old file.pdf. Anyone know how to correct this? (I have already tried clearing browser cache, switching browsers, and logging in with a different google account to view the link.)

    Read the article

  • Too Many Left Outer Joins in Entity Framework 4?

    - by Adam
    I have a product entity, which has 0 or 1 "BestSeller" entities. For some reason when I say: db.Products.OrderBy(p = p.BestSeller.rating).ToList(); the SQL I get has an "extra" outer join (below). And if I add on a second 0 or 1 relation ship, and order by both, then I get 4 outer joins. It seems like each such entity is producing 2 outer joins rather than one. LINQ to SQL behaves exactly as you'd expect, with no extra join. Has anyone else experienced this, or know how to fix it? SELECT [Extent1].[id] AS [id], [Extent1].[ProductName] AS [ProductName] FROM [dbo].[Products] AS [Extent1] LEFT OUTER JOIN [dbo].[BestSeller] AS [Extent2] ON [Extent1].[id] = [Extent2].[id] LEFT OUTER JOIN [dbo].[BestSeller] AS [Extent3] ON [Extent2].[id] = [Extent3].[id] ORDER BY [Extent3].[rating] ASC

    Read the article

  • Creating an accurate php search engine to search database

    - by Adam
    Ok, I attempted at making my own search function which doesnt work very well. It consists of eliminating useless words such as "how" "you" "to" then using a premade Stemmer class that reduces words to their root so "Appointments" searches "appoint" However in the end I'm really only searching keywords and the results are not very accurate. Are there open source search engines that i can implement for free?

    Read the article

  • A question about making a C# class persistent during a file load

    - by Adam
    Apologies for the indescriptive title, however it's the best I could think of for the moment. Basically, I've written a singleton class that loads files into a database. These files are typically large, and take hours to process. What I am looking for is to make a method where I can have this class running, and be able to call methods from within it, even if it's calling class is shut down. The singleton class is simple. It starts a thread that loads the file into the database, while having methods to report on the current status. In a nutshell it's al little like this: public sealed class BulkFileLoader { static BulkFileLoader instance = null; int currentCount = 0; BulkFileLoader() public static BulkFileLoader Instance { // Instanciate the instance class if necessary, and return it } public void Go() { // kick of 'ProcessFile' thread } public void GetCurrentCount() { return currentCount; } private void ProcessFile() { while (more rows in the import file) { // insert the row into the database currentCount++; } } } The idea is that you can get an instance of BulkFileLoader to execute, which will process a file to load, while at any time you can get realtime updates on the number of rows its done so far using the GetCurrentCount() method. This works fine, except the calling class needs to stay open the whole time for the processing to continue. As soon as I stop the calling class, the BulkFileLoader instance is removed, and it stops processing the file. What I am after is a solution where it will continue to run independently, regardless of what happens to the calling class. I then tried another approach. I created a simple console application that kicks off the BulkFileLoader, and then wrapped it around as a process. This fixes one problem, since now when I kick off the process, the file will continue to load even if I close the class that called the process. However, now the problem I have is that cannot get updates on the current count, since if I try and get the instance of BulkFileLoader (which, as mentioned before is a singleton), it creates a new instance, rather than returning the instance that is currently in the executing process. It would appear that singletons don't extend into the scope of other processes running on the machine. In the end, I want to be able to kick off the BulkFileLoader, and at any time be able to find out how many rows it's processed. However, that is even if I close the application I used to start it. Can anyone see a solution to my problem?

    Read the article

< Previous Page | 36 37 38 39 40 41 42 43 44 45 46 47  | Next Page >