Search Results

Search found 1323 results on 53 pages for 'dr giles m'.

Page 16/53 | < Previous Page | 12 13 14 15 16 17 18 19 20 21 22 23  | Next Page >

  • DDD and MVC Models hold ID of separate entity or the entity itself?

    - by Dr. Zim
    If you have an Order that references a customer, does the model include the ID of the customer or a copy of the customer object like a value object (thinking DDD)? I would like to do ths: public class Order { public int ID {get;set;} public Customer customer {get;set;} ... } right now I do this: public class Order { public int ID {get;set;} public int customerID {get;set;} ... } It would be more convenient to include the complete customer object rather than an ID to the View Model passed to the form. Otherwise, I need to figure out how to get the vendor information to the view that the order references by ID. This also implies that the repository understand how to deal with the customer object that it finds within the order object when they call save (if we select the first option). If we select the second option, we will need to know where in the view model to put it. It is certain they will select an existing customer. However, it is also certain they may want to change the information in-place on the display form. One could argue to have the controller extract the customer object, submit customer changes separately to the repository, then submit changes to the order, keeping the customerID in the order.

    Read the article

  • SQL: without a cursor, how to select records making a unique integer id (identity like) for dups?

    - by Dr. Zim
    If you have the select statement below where the PK is the primary key: select distinct dbo.DateAsInt( dateEntered) * 100 as PK, recordDescription as Data from MyTable and the output is something like this (the first numbers are spaced for clarity): PK Data 2010 01 01 00 New Years Day 2010 01 01 00 Make Resolutions 2010 01 01 00 Return Gifts 2010 02 14 00 Valentines day 2010 02 14 00 Buy flowers and you want to output something like this: PK Data 2010 01 01 01 New Years Day 2010 01 01 02 Make Resolutions 2010 01 01 03 Return Gifts 2010 02 14 01 Valentines day 2010 02 14 02 Buy flowers Is it possible to make the "00" in the PK have an "identity" number effect within a single select? Otherwise, how could you increment the number by 1 for each found activity for that date? I am already thinking as I type to try something like Sum(case when ?? then 1 end) with a group by.

    Read the article

  • dropdownlist binding from function in code behind aspx vb

    - by Dr.H
    so I have this working in C# , why it is not working in VB public string[] CustomizedRoles() { int length = Roles.GetAllRoles().Length; string[] arrRoles=Roles.GetAllRoles(); string[] customizedRoles= new string[length+1]; customizedRoles[0] = ""; for (int i = 1; i < length+1; i++) { customizedRoles[i] = arrRoles[i-1]; } return customizedRoles; } asp:GridView.... asp:DropDownList ID="ddlOwnerRolesUpdate" runat="server" DataSource="<%# CustomizedRoles() %" Height="25px" Width="177px" SelectedValue='<%# Bind("Owner") %' where is "Owner" is a data value come from a datasource for the grid it is working fine in C# . in Vb with the same aspx and this code behind it is not working. Public Function CustomizedRoles() As String() Dim length As Integer = Roles.GetAllRoles().Length Dim arrRoles As String() = Roles.GetAllRoles() Dim _customizedRoles As String() = New String(length + 1) {} _customizedRoles(0) = " " For index As Integer = 1 To length _customizedRoles(index) = arrRoles(index - 1) Next Return _customizedRoles End Function can anyone show me how to bind array of string to a dropdownlist from aspx to code behind in VB

    Read the article

  • Templating Engine to Generate Simple Reports in .NET

    - by dr. evil
    I'm looking for a free templating engine to generate simple reports. I want some basic features such as : Ability to Write Loops (with any IEnumerable) Passing Variables Passing Templates Files (main template, footer, header) I'll use this to generate reports in HTML and XML. I'm not looking for a ASP.NET Template Engine. This is for a WinForms applications. I've seen this question http://stackoverflow.com/questions/340095/can-you-recommend-a-net-template-engine, however all of those template engines are total overkill for me and focused for ASP.NET. Please only recommend free libraries. // I'm still looking an NVelocity but it doesn't look any promising for .NET, overly complicated, when you download it's bunch of files not clear what to do, no tutorial, startup document etc.

    Read the article

  • using win32 api in linux ?

    - by Dr Deo
    I have heard of WINE but I don't like it because it's slow on the computers I have tested and almost always crashes. It also has some unpleasant looking gui. I am wondering if there is a "win32" library in c/c++ for linux that produces native linux code so that if I have my source code for windows, I can just recompile and produce a working linux application. Is this possible?

    Read the article

  • Zsh command substitution

    - by Dr. Watson
    I usually work with BASH, but I'm trying to setup a cronjob from a machine and user account that is configured with zsh. When the cronjob runs, the date variable does not contain the date, just the string for the command to return the date. DATE=$(date +%Y%m%d) 55 15 * * 1-5 scp user@host:/path/to/some/file/$DATE.log /tmp I've tried using backticks rather than $() around the command, but that did not work either. Is there a special way to do command substitution in zsh?

    Read the article

  • WPF texbox focus when render to offscreen buffer

    - by dr.mo
    i am rendering a textbox to an offscreen buffer using RenderTargetBitmap and i want to enter text into this textbox, however, i can't set the textbox focus (using Focus() has no effect - presumably because the canvas is not attached to a real window?) this has two consequenes: 1 the keyboard input doesn't get captured 2. even if i set the text manually using TextBox text and CaretIndex = index i dont get a caret because of the lack of focus. is there a way to make this focus somehow? and if not, i'd like to at least have the caret visible even if there is no focus, but can't see a way of doing this.

    Read the article

  • Script to sell php script?

    - by DR.GEWA
    Hi ppl. I am to finish my social network web-script which should be sold license based. I wonder such thing. There is a lot of shopping carts there. Is there a one, which is specialized on selling scripts and supportings them? Or should I part by part put a forum, make an order system, wiki, and so on?

    Read the article

  • DotNetNuke adds wrong module to page

    - by Dr Tom
    I've deployed DotNetNuke 07.03.02 to Azure using Azure's own wizard - worked fine. Been using DNN for years on personal server without issues. However, when I try to add a module to a page (i.e regular editing) DNN adds the wrong module to the page; seemingly FirstOrDefault from the list of installed modules. I.E, I want to add the "HTML" module (or any other) to a page but instead I get the "Banners" module. If I then uninstall the the Banners module it now adds the "Modules list" module. See below example, where I'm editing the "About" page of my site and have tried to add the HTML module. I hope anyone with insight into DNN (on Azure) can provide info. I am a .Net developer, but have so far had no reason to dig into DNN's inner workings.

    Read the article

  • Best way to display a background with a pattern in an iPhone/iPad app

    - by Dr Dork
    Here's an example of the type of background image I'm talking about... Clearly, there's a pattern in it. My question is, if this were an iPad app and the background image was twice the size, would there be any significant benefits to taking advantage of this pattern by tiling the image? Or would it really make no difference in terms of performance and just be easier to load the entire image into a UIImageView? Thanks in advance for all your wisdom!

    Read the article

  • How can I replace a UITableViewController with a UIViewController that contains a UITableView?

    - by Dr Dork
    I created a new SplitView iPad project in Xcode and setup the code to populate the TableView (in the RootView on the left) with data. Now I'd like to customize the RootView to contain a DatePicker view along with the TableView, but I'm unsure how to accomplish this. Since the default RootViewController is a subclass of a UITableViewController, I couldn't add a DatePicker view to it in IB (since you can't add a DatePicker to a UITableView). The only way I understand to accomplish my goal of adding a DatePicker to the "Left" RootView is to change the RootViewController from a subclass of a UITableViewController to a subclass of a UIViewController, then I'll be able to add a view to it that contains a DatePicker view and a TableView using IB. Questions... Is this the correct approach to add a DatePicker to the "Left" RootView? If so and I change the RootViewController to a subclass of a UIViewController (instead of a UITableViewController) and add to it a TableView (along with the DatePicker), how will that affect the code I currently have in place for populating my current TableView? Thanks so much for all your help! Below is my current interface code for my RootViewController, if it'll help any. @interface RootViewController : UITableViewController <NSFetchedResultsControllerDelegate> { DetailViewController *detailViewController; NSFetchedResultsController *fetchedResultsController; NSManagedObjectContext *managedObjectContext; } @property (nonatomic, retain) IBOutlet DetailViewController *detailViewController; @property (nonatomic, retain) NSFetchedResultsController *fetchedResultsController; @property (nonatomic, retain) NSManagedObjectContext *managedObjectContext; - (void)insertNewObject:(id)sender; @end

    Read the article

  • why does $.ajax(..) not work for me?

    - by dr jerry
    I'm running jquery from a file. And I'm trying to load a svg file from my localhost to populate a svg canvas. However that does not work as expected. What I do from filesystem: $.ajax({ url: url , timeout: 1000, complete: function(xml) { alert('complete'); }, success: function(xml, status, xreq) { alert('success'); }, error: function() { alert('error'); } }); the url reads: http://localhost/image.svg, when I read this url directly from an addressbar from the browser, the pages remains white but the pagesource displays the source of image.svg. Debugging the $.ajax code above, reveals that the success: method is hit, but xml response remains empty. Any help is greatly appreciated. regards, jeroen.

    Read the article

  • What is your favourite programming-related lolcat picture?

    - by DR
    In the spirit of these questions... http://stackoverflow.com/questions/234075/what-is-your-best-programmer-joke http://stackoverflow.com/questions/354686/programming-related-songs http://stackoverflow.com/questions/517897/anyone-know-any-programming-related-poetry ... I wonder: What is your favourite programming-related lolcat picture? Please add one answer per picture.

    Read the article

  • How to cleanup old Failed Builds in TeamCity?

    - by dr. evil
    We do have hundreds of failed builds in TeamCity (number is especially high because of old retry on fail settings) and now it's a pain to browse history. I want to clean up only old failed builds, is there anyway to do that in TeamCity? Normal clean-up policy only allows X days before the last successful build sort of clean ups.

    Read the article

  • comments in svg path

    - by dr jerry
    I'm experimenting with jquery and svg, I make up my path but now I want to change that (based on some user input) I do something like var dpath = $('path').attr("d"); $('path').attr("d",dpath.replace("150 150", "450 450")); which works fine, but this not useful when my path grows, so I wonder is there a possibility to put a label or a comment in the path to serve as a replace hook? searching for svg path comments gives me all. I'm close to write my own "replaceble" pseudo svg path code, but is there an alternative possible in svg? regards, Jeroen.

    Read the article

  • can Yahoo and Hotmail contacts api be used without leaving the site?

    - by Dr.Dredel
    I might be missing something but I'm trying to implement a contacts retrieval mechanism akin to the one that is offered by Google for Yahoo and Hotmail. Both APIs seem to require the user to actually go to their sites to log in. The documentation is really convoluted for both. I was hoping someone has done this and can point me to a simple way (if there is one) to allow the user to log in directly in my app and then for me to go and fetch their contacts for them (preferably in XML, but JSON would also do nicely). I currently have a Perl script that goes and gets the gmail stuff and works very nicely. I was (maybe wildly optimistically) hoping that Yahoo and Microsoft would have similarly useful mechanisms.

    Read the article

  • Getting notification / listener when action is performed (chimpChat / monkeyrunner tool)

    - by Dr. AtZe
    I want to get a notification if someone has performed an action in an android app from outside of the app. I don't want to make any (android) code changes. To do the actions I use the Chimpchat.jar, the .jar that the monkeyrunner tool uses. To be clear: Can I get a notification or register listeners on components from outside of the app? e.g. Run my android app My java application links into the device with chimpChat via the adb The user touches a button My java application gets a notification what was performed = am I able to get that information? If not, am I able to get the information on which position the tab was? Hopefully it's clear what I want to do. Thanks, soeren

    Read the article

  • Reflection: take values from an unknown running alpplication

    - by Dr.Lesh
    I'm writing an application that searchs for Semaphore types in the fields of unknown classes in unknown application (passed by user). I made it using Reflection and it worked. Now I want to fill up these semaphores with values, taking them from a running instance of this unknown application. So i took the class with "main" method of this unknown application, made a newInstance, and passed it when invoking the main method to start the application: Class mainClass = getItSomeWhere(); Object instance = mainClass.newInstance(); Method mainMethod = mainClass.getDeclaredMethod("main", new Class[]{String[].class}); mainMethod.invoke(instance, new Object[]{args}); and it worked fine. Now, how can I get the semaphore values, taking them from the classes of this running application, when I only have an instance of the main class? Many thanks for the answers.

    Read the article

  • How to prevent inheritance for some methods?!

    - by Dr TJ
    Hi How can I prevent inheritance of some methods or properties in derived classes?! public class BaseClass : Collection { //Some operations... //Should not let derived classes inherit 'Add' method. } public class DerivedClass : BaseClass { public void DoSomething(int Item) { this.Add(Item); // Error: No such method should exist... } }

    Read the article

  • Why doesn't the SplitView iPhone template have a nib file for the RootView?

    - by Dr Dork
    I'm diving into iPad development and am learning a lot quickly, but everywhere I look, I have questions. After creating a new SplitView app in Xcode using the template, it generates the AppDelegate class, RootViewController class, and DetailViewController class. Along with that, it creates a .xib files for MainWinow.xib and DetailView.xib. How do these five files work together? Why is there a nib file for the DetailView, but not the RootView? When I double click on the MainWindow.xib file, Interface Builder launches without a "View" window, why? Below is the code for didFinishLaunchingWithOptions method inside the AppDelegate class. Why are we adding the splitViewController as a subview? (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { // Override point for customization after app launch rootViewController.managedObjectContext = self.managedObjectContext; // Add the split view controller's view to the window and display. [window addSubview:splitViewController.view]; [window makeKeyAndVisible]; return YES; } Thanks so much in advance for all your help! I still have a lot to learn, so I apologize if this question is absurd in any way. I'm going to continue researching these questions right now!

    Read the article

  • How can I get the text color of a button using the Substance LaF?

    - by DR
    In my Java application I have to custom-paint a control and for that I need to use the same font colors as JButton. (Enabled an disabled) I don't want to to hard-code them, because the user can change the Substance skin at runtime. I'm aware of the ColorSchemes but I'm not sure how to proceed once I have the color scheme of the current skin. Also the Substance documentation says something about creating your own color scheme, but I just can't figure out the way to retrieve a certain color.

    Read the article

  • Why are my "+" characters turned into spaces in my CGI program that handles Ajax requests?

    - by Dr.Dredel
    I'm collecting text through a web form and noticing that when it is collected by my Perl CGI all instances of "+" are transformed into " ". I run the text through a JavaScript escape before submission, but escape seems to leave + unaltered. There must be something really obvious that I'm missing... how do I send the string "2 + 2 = 4" through and not have it arrive as "2 2 = 4"?

    Read the article

< Previous Page | 12 13 14 15 16 17 18 19 20 21 22 23  | Next Page >