Daily Archives

Articles indexed Friday June 11 2010

Page 9/114 | < Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >

  • Automatically generating better views for ASP.NET MVC

    - by Casebash
    I am currently watching the 80 minute ASP.NET MVC introduction. Automatically generating views from a model is pretty neat, but it seems to me that that the automatically generated views could be much better. For a start, instead of inputing dates with text boxes, there could be a date control. Additionally, number inputs could be verified client side. There are probably other improvements that could be made as well. Is it possible to automatically generate better views?

    Read the article

  • Process-wide hook using SetWindowsHookEx

    - by mfya
    I need to inject a dll into one or more external processes, from which I also want to intercept keybord events. That's why using SetWindowsHookEx with WH_KEYBOARD looks like an easy way to achieve both things in a single step. Now I really don't want to install a global hook when I'm only interested in a few selected processes, but Windows hooks seem to be either global or thread-only. My question is now how I would properly go about setting up a process-wide hook. I guess one way would be to set up the hook on the target process' main thread from my application, and then doing the same from inside my dll on DLL_PROCESS_ATTACH for all other running threads (plus on DLL_THREAD_ATTACH for threads started later). But is this really a good way? And more important, aren't there any simpler ways to setup process-wide hooks? My idea looks quite cumbersome und ugly, but I wasn't able to find any information about doing this anywhere.

    Read the article

  • Computer graphics research

    - by Shrey
    What are the best known labs for research in CG especially raytracing/rendering? I want to pursue Masters/PhD in this field and though I have been working on projects such as raytracers, it is all self-driven. What would be a good place to start, perhaps as a research intern? Also, what kind of background is expected for admissions in these programs, in terms of programming skills, formal education etc.?

    Read the article

  • Backup Xen domU machines while running.

    - by Jonathan Hawkes
    The host machine is running CentOS 5.3 and using LVM to create Logical Volumes (LVs) and to allow live snapshots to be taken of those LVs. My thought was to store all of the image files for the Xen underpriviledged domains (domU) in a single LV and periodically take a snapshot of that LV and copy the disk images out of the snapshot in order to make a live backup of these systems. Is this doable? Is there a better way? Thanks!

    Read the article

  • Root view controllers and modal dialogs

    - by Tony
    In a custom UIViewController, if I have a member UINavigationController that I initialize with self as the root view, like this: navController = [[UINavigationController alloc] initWithRootViewController:self]; then presenting a modal dialog does not hide the tab bar at the bottom of the screen. The result is that if the user switches to a different tab while a modal dialog is displayed, when they pop back to the tab that was displaying a modal dialog then subsequent calls to presentModalViewController do not display a modal dialog at all, even if I call dismissModalViewControllerAnimated as a result of the tab switch. If I initialize the UINavigationController with out setting self as the root controller, navigationController = [[UINavigationController alloc] init]; then the tab bar is hidden as expected. I've changed things in my program so that this isn't really an issue for me anymore, but I'm not sure that I understand why this is happening. Is it considered bad practice to have a navigation controller with self as the root, if the nav controller is going to be displaying modal dialogs?

    Read the article

  • LINQ to SQL filter combobox output

    - by Brendan
    OK so I've got 2 tables for this instance, Users{UserID, Name}, Company{CompanyID, UserID, Name, Payrate} i also have 2 combo boxes, first one is for Users which Displays Name, and the Value is UserID i need the second combobox to get the Names from the Company table, but only showing Companies that are relevant to the selected user. I cant work out how to get it to go... Any ideas???

    Read the article

  • Help need to with MySQL query to join data spanning multiple tables and use data as column names

    - by gurun8
    I need a little help putting together a SQL query that will give me the following resultsets: and The data model looks like this: The tricky part for me is that the columns to the right of the "Product" in the resultset aren't really columns in the database but rather key/value pairs spanned across the data model. Table data is as follows: My apologies in advance for the image heavy question and the image quality. This just seemed like the easiest way to convey the information. It'll probably take someone less time to write the query statement to achieve the results than it did for me to assemble this question. By the way, the "product_option" table image is truncated but it illustrated the general idea of the data structure. The MySQL server version is 5.1.45.

    Read the article

  • How to find that Mutex in C# is acquired?

    - by TN
    How can I find from mutex handle in C# that a mutex is acquired? When mutex.WaitOne(timeout) timeouts, it returns false. However, how can I find that from the mutex handle? (Maybe using p/invoke.) UPDATE: public class InterProcessLock : IDisposable { readonly Mutex mutex; public bool IsAcquired { get; private set; } public InterProcessLock(string name, TimeSpan timeout) { bool created; var security = new MutexSecurity(); security.AddAccessRule(new MutexAccessRule(new SecurityIdentifier(WellKnownSidType.WorldSid, null), MutexRights.Synchronize | MutexRights.Modify, AccessControlType.Allow)); mutex = new Mutex(false, name, out created, security); IsAcquired = mutex.WaitOne(timeout); } #region IDisposable Members public void Dispose() { if (IsAcquired) mutex.ReleaseMutex(); } #endregion } Currently, I am using my own property IsAcquired to determine whether I should release a mutex. Not essential but clearer, would be not to use a secondary copy of the information represented by IsAcquired property, but rather to ask directly the mutex whether it is acquired by me. Since calling mutex.ReleaseMutex() throws an exception if it is not acquired by me. (By acquired state I mean that the mutex is in not-signaled state when I am owning the mutex.)

    Read the article

  • how write this in verbatim latex

    - by voodoomsr
    hi, i have a little question about the verbatim environment in latex..... my problem is how can i write "\end{verbatim}" inside of a verbatim environment, it supposed that everything inside a verbatim is written just like it looks but this is the string to end the environment, so how can i do this?

    Read the article

  • Advice on how to complete specific MySQL JOIN

    - by Tim
    Hello, I have a mysql table jobs. This is the basic structure of jobs. id booked_user_id assigned_user_id I then also have another table, meta. Meta has the structure: id user_id first_name last_name How can I join these tables so that both booked_user_id and assigned_user_id can access meta.first_name? Thanks for your advice Tim

    Read the article

  • How do I make my NSNotification trigger a selector?

    - by marty
    Here's the code: - (void)viewDidLoad { [super viewDidLoad]; NSURL *musicURL = [NSURL URLWithString:@"http://live-three2.dmd2.ch/buureradio/buureradio.m3u"]; if([musicURL scheme]) { MPMoviePlayerController *mp = [[MPMoviePlayerController alloc] initWithContentURL:musicURL]; if (mp) { // save the music player object self.musicPlayer = mp; [mp release]; [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(popBack:) name:@"MPMoviePlayerDidExitFullscreenNotification" object:nil]; // Play the music! [self.musicPlayer play]; } } } -(void)popBack:(NSNotification *)note { [self.navigationController popToRootViewControllerAnimated:YES]; } The selector method never gets called. I just want to pop back to the root menu when the "Done" button is pressed on the movie player. I put an NSLog in the selector to check if it was even being called, nothing. The music plays fine. Any thoughts?

    Read the article

  • How to test UI interaction of Silverlight dialogs?

    - by Bernard Vander Beken
    I am using Silverlight 3.0 Unit Testing, version Silverlight Toolkit November 2009. Apart from unit tests, it allows to do UI interaction tests, typically using AutomationPeer subclasses (eg ButtonAutomationPeer to interact with a Button). Are there AutomationPeer classes to test the interaction with the following: OpenFileDialog SaveFileDialog MessageBox In unit tests it would be possible to stub these, but for integration and browser testing it would be great to have this testable.

    Read the article

  • access values of controls dynamically created on postback

    - by userk
    Hi, My problem is: I've got a table, dynamically created, fill with a lot of dropdownlists witches IDs are dynamically created. When a button is pressed, I need to scan all controls in the table and save their value. But after the postback I can't no longer access to the table, and I've no idea how can I get those values... Thanks!

    Read the article

  • How netbeans installation file (bash file) contains Java code?

    - by Daziplqa
    Hi folks, I wonder, how a bash file can contain a Java code that is responsible about the installation of netbeans IDE which is as known is a Java based program? this is the case of netbeans: $ file netbeans-6.8-ml-java-linux.sh netbeans-6.8-ml-java-linux.sh: POSIX shell script text executable $ more netbeans-6.8-ml-java-linux.sh #!/bin/sh # # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. # # Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved. How this can happen?

    Read the article

  • iPad leak - NSPushAutoreleasePool

    - by Tim Bowen
    We are getting a sizable leak (16kb) that is proving very difficult to eliminate. The responsible library is Foundation and the Responsible frame is NSPushAutoreleasePool. This leak does not appear on the iPhone, only the iPad. We get the following stack trace: 9 libSystem.B.dylib thread_assign_default 8 libSystem.B.dylib _pthread_start 7 WebCore RunWebThread(void*) 6 CoreFoundation CFRunLoopRunInMode 5 CoreFoundation CFRunLoopRunSpecific 4 CoreFoundation __CFRunLoopDoObservers 3 WebCore WebRunLoopLock(__CFRunLoopObserver*, unsigned long, void*) 2 Foundation NSPushAutoreleasePool 1 Foundation _NSAPAddPage 0 libSystem.B.dylib malloc We're getting a similar one in the frame NSAutoReleasePool. We've checked everywhere in the code we create an autoreleasepool to make sure we're releasing it. Since none of this is our code I'm not sure how to proceed. Thanks in advance.

    Read the article

  • What encoding I should use in editor (NetBeans), if I were intend to print non-english character

    - by Yan Cheng CHEOK
    I try to set the encoding of my editor to UTF-16. (Java String store the data in UTF-16 internally, right?) And I type the following code package helloworld; /** * * @author yan-cheng.cheok */ public class Main { /** * @param args the command line arguments */ public static void main(String[] args) { // TODO code application logic here System.out.println("???"); System.out.println("\u6587\u4EF6\u79CD\u7C7B"); } } However, the output is not what I expected : ???? ????? I try to change the editor encoding format to UTF-8, it works this time! ??? ???? May I know why I need to change the editor encoding format to UTF-8 but not UTF-16? Isn't Java String store the data in UTF-16 internally?

    Read the article

  • Making a "scrolling" menu.

    - by Anonymous the Great
    I want to make a scrolling menu with my menu on my free hosted site. What I mean by a scrolling menu is like at the bottom of the screen @ CNET.com & ThePheed.net, my site is currently at Trigoblocks.comuf.com. Does anybody know how to do this and could teach me or lead me in the right direction? (:

    Read the article

  • ActionScript Basic Question

    - by TheDarkIn1978
    i've only ever created external .as files that extended a class such as sprite. now i just want to create one that doesn't extend anything and call it from a frame script. package { public class Test { public function Test(val:Number, max:Number) { trace(val, max); } } } from my frame script of an .fla that is in the same folder as Test.as, i'll write this: Test(50, 100); this produces the following error: 1137: Incorrect number of arguments. Expected no more than 1.

    Read the article

  • Managing/Storing complex application form

    - by mickyjtwin
    I am developing an online application form, which can be of two categories, either domestic/international. Each different type has commong questions, and also specific questions. They are approx 6 pages/steps of questions. The application form can also be saved at the end of each step, and can be completed at a later date. Some questions will vary depending on answers to previous questions, so there are some complex business rules. In terms of storage of results, would it be best to store the answers in and XML field in SQL? What would be the best way to reference a question to an answer. There is no need for the form to be dynamic in rendering questions etc. e.g. <Application id="123" type="Domestic"> <Answers> <EmailAddress>[email protected]</EmailAddress> <HomePhone>555-5555</HomePhone> <Suburb>MySuburb</Suburb> <Guardians> <Guardian type="Mother"> <FirstName>Mom</FirstName> </Guardian> </Guardians> <Answers> </Application>

    Read the article

  • Windows service running under network credentials doesn't autostart

    - by David Alpert
    I have a Subversion Server running as a resident service on a Windows XP Pro machine. That service needs to access a secure network fileshare, so I used the Services-Properties-Log On tab to tell the service to run as a user who has access to the target fileshare. That works out fine until the machine restarts, when the service fails to autostart. I am able to start it manually by logging in, going back to that Services-Properties-Log On tab and reconfiming the explicit credentials. Do I have to manually start this service under alternate credentials every time the machine reboots? Is there something else I can do to make sure that my Subversion server service autostarts with proper access to authenticate against this network share?

    Read the article

  • How can display gif on a subview in iPhone using glgif?

    - by iPhoney
    I want to display a gif image on a subview in iPhone. The sample code glgif shows the gif image on the controller's root view, but when I make the following modifications, the application just crashes: IBOutlet UIView *gifView; // gifView is added as a subview of controller's root view //PlayerView *plView = (PlayerView *)self.view; PlayerView *plView = (PlayerView *)gifView; // Load test.gif VideoSource NSString *str = [[NSBundle mainBundle] pathForResource:@"test" ofType:@"gif"]; FILE *fp = fopen([str UTF8String], "r"); VideoSource *src = VideoSource_init(fp, VIDEOSOURCE_FILE); src->writeable = false; // Init video using VideoSource Video *vid = [[GifVideo alloc] initWithSource:src inContext:[plView context]]; VideoSource_release(src); // Start if loaded if (vid) { [plView startAnimation:vid]; [vid release]; return; } // Cleanup if failed fclose(fp); Now the app crashes in this line: Video *vid = [[GifVideo alloc] initWithSource:src inContext:[plView context]]; with the error message:-[UIView context]: unrecognized selector sent to instance. Any ideas about how to add the plView to the subview properly?

    Read the article

  • Cocoa giving error: <Error>: doClip: empty path.

    - by outtru.mp
    Coco gives error: Thu Jun 10 19:13:56 myComputer.local myApp[####] <Error>: doClip: empty path. But I don't have this function anywhere in my code (can't find by searching in frameworks / project)... Seems a lot of people complain about this because it goes into the console logs, but couldn't find any reason given as to what causes it on a progmatic level. Any thoughts as to what the problem is?

    Read the article

< Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >