Search Results

Search found 311 results on 13 pages for 'erik'.

Page 8/13 | < Previous Page | 4 5 6 7 8 9 10 11 12 13  | Next Page >

  • How do you distinguish your EC2 instances?

    - by Erik
    The ec2-describe-instances command is not very helpful in distinguishing the instances. Are there command line tools that give a better overview? Perhaps somewhat like http://github.com/newbamboo/manec2 but with support for different regions etc.

    Read the article

  • What am i doing wrong

    - by Erik Sapir
    I have the following code. I need B class to have a min priority queue of AToTime objects. AToTime have operator, and yet i receive error telling me than there is no operator matching the operands... #include <queue> #include <functional> using namespace std; class B{ //public functions public: B(); virtual ~B(); //private members private: log4cxx::LoggerPtr m_logger; class AToTime { //public functions public: AToTime(const ACE_Time_Value& time, const APtr a) : m_time(time), m_a(a){} bool operator >(const AToTime& other) { return m_time > other.m_time; } //public members - no point using any private members here public: ACE_Time_Value m_time; APtr m_a; }; priority_queue<AToTime, vector<AToTime>, greater<AToTime> > m_myMinHeap; };

    Read the article

  • Generate an ID via COM interop

    - by Erik van Brakel
    At the moment, we've got an unmaintanable ball of code which offers an interface to a third party application. The third party application has a COM assembly which MUST be used to create new entries. This process involves two steps: generate a new object (basically an ID), and update that object with new field values. Because COM interop is so slow, we only use that to generate the ID (and related objects) in the database. The actual update is done using a regular SQL query. What I am trying to figure out if it's possible to use NHibernate to do some of the heavy lifting for us, without bypassing the COM assembly. Here's the code for saving something to the database as I envision it: using(var s = sessionFactory.OpenSession()) using(var t = s.BeginTransaction()) { MyEntity entity = new MyEntity(); s.Save(entity); t.Commit(); } Regular NH code I'd say. Now, this is where it gets tricky. I think I have to supply my own implementation of NHibernate.Id.IIdentifierGenerator which calls the COM assembly in the Generate method. That's not a problem. What IS a problem is that the COM assembly requires initialisation, which does take a bit of time. It also doesn't like multiple instances in the same process, for some reason. What I would like to know is if there's a way to properly access an external service in the generator code. I'm free to use any technique I want, so if it involves something like an IoC container that's no problem. The thing I am looking for is where exactly to hook-up my code so I can access the things I need in my generator, without having to resort to using singletons or other nasty stuff.

    Read the article

  • How can I create personalized menus in WPF?

    - by Erik Vullings
    I'm working on an XmlEditor (similar to XmlNotepad, but using WPF) in which I want to implement personalized menus. I.e. only show the most popular MenuItems on first open, and show all MenuItems when the user explicitly asks for it, either by clicking on the double arrow at the bottom or waiting for a certain amount of time. I'm specifically looking for feedback on how I should approach this problem: any thoughts are appreciated!

    Read the article

  • How can I do rapid application development with ASP.NET MVC?

    - by Erik Forbes
    I've been given a short amount of time (~80 hours to start with) to replace an existing Access database with a full-blown SQL + Web system, and I'm enumerating my options. I would like to use ASP.NET MVC, but I'm unsure of how to use it effectively with my short timetable. For the database backend I'll be using Linq to SQL as it's a product I already know and can get something working with it quickly. Does anyone have any experience with using ASP.NET MVC in this way and can share some insight? Edit: The reason I've been interested in ASP.NET MVC is because I know (100% confirmed) that there will be more work to do after this first round, and I'd like my maintenance work to be as easy as possible. In my experience Webforms applications tend to break down over repeated maintenance, despite discipline. Maybe there's a middle ground? How difficult would it to be for me to, say, build the app with Webforms, then migrate it to MVC later when I have more time budgeted to the project? Edit 2: Further background: the Access application I'm replacing is used in some capacity by everyone in the building, and since it was upgraded from Access 98 to 2003 it's been crashing daily, causing hours of lost productivity as people have to re-enter data since the last backup. This is the reason for the short amount of time - this is a critical business function, and they can't afford to keep re-entering data on a daily basis.

    Read the article

  • How to make the yuicompressor jar file a singleton, or globally accessible?

    - by Erik Vold
    I'd like to put the yuicompressor jar file in a single folder so that I can call java -jar yuicompressor-2.4.2.jar ... from anywhere on my system, with cygwin. For bash files I use I simply put them in a common folder, and added the folder's path to my windows user's PATH environment variable and the bash commands were found in cygwin. when I echo $PATH I see the folder I put the yuicompressor jar into listed in the $PATH.. But when I try java -jar yuicompressor-2.4.2.jar ... I get the following error message: Unable to access jarfile yuicompressor-2.4.2.jar Even when I try providing an absolute path to the jarfile I get the same error message.. How can I do this?

    Read the article

  • Best Practices / Patterns for Enterprise Protection/Remediation of SSNs (Social Security Numbers)

    - by Erik Neu
    I am interested in hearing about enterprise solutions for SSN handling. (I looked pretty hard for any pre-existing post on SO, including reviewing the terriffic SO automated "Related Questions" list, and did not find anything, so hopefully this is not a repeat.) First, I think it is important to enumerate the reasons systems/databases use SSNs: (note—these are reasons for de facto current state—I understand that many of them are not good reasons) Required for Interaction with External Entities. This is the most valid case—where external entities your system interfaces with require an SSN. This would typically be government, tax and financial. SSN is used to ensure system-wide uniqueness. SSN has become the default foreign key used internally within the enterprise, to perform cross-system joins. SSN is used for user authentication (e.g., log-on) The enterprise solution that seems optimum to me is to create a single SSN repository that is accessed by all applications needing to look up SSN info. This repository substitutes a globally unique, random 9-digit number (ASN) for the true SSN. I see many benefits to this approach. First of all, it is obviously highly backwards-compatible—all your systems "just" have to go through a major, synchronized, one-time data-cleansing exercise, where they replace the real SSN with the alternate ASN. Also, it is centralized, so it minimizes the scope for inspection and compliance. (Obviously, as a negative, it also creates a single point of failure.) This approach would solve issues 2 and 3, without ever requiring lookups to get the real SSN. For issue #1, authorized systems could provide an ASN, and be returned the real SSN. This would of course be done over secure connections, and the requesting systems would never persist the full SSN. Also, if the requesting system only needs the last 4 digits of the SSN, then that is all that would ever be passed. Issue #4 could be handled the same way as issue #1, though obviously the best thing would be to move away from having users supply an SSN for log-on. There are a couple of papers on this: UC Berkely: http://bit.ly/bdZPjQ Oracle Vault: bit.ly/cikbi1

    Read the article

  • How to attach multiple files to a Wordpress post?

    - by erik.brannstrom
    I'm currently working on a project where we are using Wordpress 3.0 RC. The idea is to create custom post types with meta boxes to make the system easier to use for the client. Some of these posts need to have multiple files attached to them, and by attached I do not mean inserted to post but rather we'd like to keep them separate from the post body (in fact, a given post type might not even have text, only files). I'm wondering if there is a standard approach for allowing multiple files to be attached to a Wordpress post? I've managed to add a meta box that allows one file from the media library to be selected, but I have no idea how to extend this to allow an arbitrary number of files. Hope someone can help!

    Read the article

  • DB2 load partitioned data in parallel

    - by Erik Paulson
    I have a 10-node DB2 9.5 database, with raw data on each machine (ie node1:/scratch/data/dataset.1 node2:/scratch/data/dataset.2 ... node10:/scratch/data/dataset.10 There is no shared NFS mount - none of my machines could handle all of the datasets combined. each line of a dataset file is a long string of text, column delimited. The first column is the key. I don't know the hash function that DB2 will use, so dataset is not pre-partitioned. Short of renaming all of my files, is there any way to get DB2 to load them all in parallel? I'm trying to do something like load from '/scratch/data/dataset' of del modified by coldel| fastparse messages /dev/null replace into TESTDB.data_table part_file_location '/scratch/data'; but I have no idea how to suggest to db2 that it should look for dataset.1 on the first node, etc.

    Read the article

  • Using the same style in many listviews

    - by Erik
    I want to use the same style in many listviews. And in my style i have defined the gridview columns also. But when i try to run, it throws an exception: View can't be shared by more than one ListView. How can i solve this?

    Read the article

  • VS 2010 breaks my keydown events

    - by Erik Karlsson
    I have a custom control, a groupbox, which reacts on key events on a assigned key. It is possible to remove this groupbox, as well as adding more dynamically. Havnt been any trouble in VS 2008 so far. Two days ago i installed VS 2010. And i started to get multiple event fireing, and removing a groupbox did not remove the specific key events attached to it. Where did it go wrong? I use -= on the events present in the gruopbox code to remove them before removing the groupbox.

    Read the article

  • Dependency property does not work within a geometry in a controltemplate

    - by Erik Bongers
    I have a DepencencyProperty (a boolean) that works fine on an Ellipse, but not on an ArcSegment. Am I doing something that is not possible? Here's part of the xaml. Both the TemplateBindings of Origin and LargeArc do not work in the geometry. But the LargeArc DependencyProperty does work in the Ellipse, so my DependencyProperty seems to be set up correctly. <ControlTemplate TargetType="{x:Type nodes:TestCircle}"> <Canvas Background="AliceBlue"> <Ellipse Height="10" Width="10" Fill="Yellow" Visibility="{TemplateBinding LargeArc, Converter={StaticResource BoolToVisConverter}}"/> <Path Canvas.Left="0" Canvas.Top="0" Stroke="Black" StrokeThickness="3"> <Path.Data> <GeometryGroup> <PathGeometry> <PathFigure IsClosed="True" StartPoint="{TemplateBinding Origin}"> <LineSegment Point="150,100" /> <ArcSegment Point="140,150" IsLargeArc="{TemplateBinding LargeArc}" Size="50,50" SweepDirection="Clockwise"/> </PathFigure> </PathGeometry> </GeometryGroup> </Path.Data> </Path> </Canvas> </ControlTemplate> What I'm trying to build is a (sort of) pie-shaped usercontrol where the shape of the Pie is defined by DependencyProperties and the actual graphics used are in a template, so they can be replaced or customized. In other words: I would like the code-behind to be visual-free (which, I assume, is good separation). SOLUTION--------------------------(I'm not allowed to answer my own questions yet) I found the answer myself, and this can be useful for others encountering the same issue. This is why the TemplateBinding on the Geometry failed: A TemplateBinding will only work when binding a DependencyProperty to another DependencyProperty. Following article set me on the right track: http://blogs.msdn.com/b/liviuc/archive/2009/12/14/wpf-templatebinding-vs-relativesource-templatedparent.aspx The ArcSegment properties are no DependencyProperties. Thus, the solution to the above problem is to replace <ArcSegment Point="140,150" IsLargeArc="{TemplateBinding LargeArc}" with <ArcSegment Point="140,150" IsLargeArc="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=LargeArc}" Colin, your working example where an 'ordinary' binding was used in the geometry set me on the right track. BTW, love the infographics and the construction of your UserControl in your blogpost. And, hey, that quick tip on code snippets, and especially on that DP attribute and the separation of those DPs into a partial class file is pure gold!

    Read the article

  • Shell Extension: DragQueryFile returns at most 16 (in Windows 7)

    - by Erik
    I've writtten a shell extension (guided by The Complete Idiot's Guide to Writing Shell Extensions) which worked as it should until I upgraded to Windows 7(32bit). Now, the function DragQueryFile UINT uNumFiles = DragQueryFile(hDrop,0xFFFFFFFF,NULL,0); returns the right number of selected files until the number is above 16. Then always 16 is returned. I've tested it in XP(32) and Vista(32), there it works, in Windows7 (32/64) it doesn't. Any ideas? Thanks.

    Read the article

  • WPF Notify changes on object

    - by Erik Z
    I have a gridview were I define some columns, like this... <GridViewColumn.CellTemplate> <DataTemplate> <TextBlock Text="{Binding MyProp}" /> </DataTemplate> </GridViewColumn.CellTemplate> I bind my gridview to a collection and implemts INotifyPropertyChanged in the property MyProp. This works well and any changes of MyProp are reflected to the gridview. If I add another column that is bound to the object itself I dont get any notifications/updates. My code... <GridViewColumn.CellTemplate> <DataTemplate> <TextBlock Text="{Binding Converter={StaticResource myConverter}}"/> </DataTemplate> </GridViewColumn.CellTemplate> I think I need something like INotifyPropertyChanged for the object but I have no idea how to do this. Any suggestions?

    Read the article

  • HttpResponse.Filter how determine End of stream

    - by Erik
    I got a HttpResponse.Filter filter that replaces text in the HTML. I've created a class that derives from Stream and implemented the Write method: public override void Write(byte[] buffer, int offset, int count) I read all bytes from buffer and store them in a private StringBuilder, then I replace the text, and write the string back to the Stream. But how can I determine when the stream is at the end of the stream. I.e. how do I determine when to write back the html (string) to the stream?

    Read the article

  • Falling Sand simulation

    - by Erik Forbes
    I'm trying to re-create a 'falling sand' simulation, similar to those various web toys that are out there doing the same thing - and I'm failing pretty hard. I'm not really sure where to begin. I'm trying to use cellular automata to model the behavior of the sand particles, but I'm having trouble figuring out how to make the direction in which I update the 'world' not matter... For example, one of the particle types I'd like to have is Plant. When Plant comes in contact with Water, Plant turns that Water particle into another Plant particle. The problem here though is that if I'm updating the game world from top to bottom and left to right, then a Plant particle placed in the middle of a sea of Water particles will immediately cause all of the Water particles to the right and below that new Plant particle to turn into Plants. This is not the behavior I am expecting. =( I'm having difficulty explaining exactly my difficulty, so I'll try to add more information as best I can as I go along. Suffice it to say that this is very much outside my box, as it were, and I don't even know what to search for.

    Read the article

  • Is there a good reflection library available for Scala?

    - by Erik Engbrecht
    I'm working on a library that needs reflection, and needs Scala-specific information as opposed to what is available via the standard Java reflection API. Right now I'm using the undocumented code in scalap (the Scala equivalent to javap) and trying to associate the data it provides with Java reflection objects so that I can call methods and such (scalap just parses class files). I found this but there's nothing there... https://github.com/dubochet/scala-reflection ...and I've searched the Scala SVN repo for traces of it and failed to find it there, either (but it could be I just missed it). Does anyone know of a Scala reflection library that provides information similar to what scalap provides but also allows you to call methods, access fields, etc like the Java reflection library?

    Read the article

  • PHP PDO: Fetching data as objects - properties assigned BEFORE __construct is called. Is this correc

    - by Erik
    The full question should be "Is this correct or is it some bug I can't count on?" I've been working with PDO more and in particular playing with fetching data directly into objects. While doing so I discovered this: If I fetch data directly into an object like this: $STH = $DBH->prepare('SELECT first_name, address from people WHERE 1'); $obj = $STH->fetchAll(PDO::FETCH_CLASS, 'person'); and have an object like this: class person { public $first_name; public $address; function __construct() { $this->first_name = $this->first_name . " is the name"; } } It shows me that the properties are being assigned before the __construct is being called -- because the names all have " is the name" appended. Is this some bug (in which case I can't/won't count on it) or is this The Way It Should Be. Because it's really quite a nice thing the way it works currently.

    Read the article

  • hg: unknown command 'qimportbz'

    - by Erik Vold
    I followed the instructions on how to setup qimportbz here; I'm on WinXP and instead of adding: [extensions] qimportbz = C:\mozilla\mercurial\qimportbz to a .hgrc file I updated a Mercurial.ini file which seems to be the correct file to add extensions to for me.. then when I run hg help qimportbz I see the help for the qimportbz cmd, but when I try to run hg qimportbz 548590 for example, on the jetpack-sdk hg repo, I get the following error: hg: unknown command 'qimportbz'

    Read the article

< Previous Page | 4 5 6 7 8 9 10 11 12 13  | Next Page >