Daily Archives

Articles indexed Wednesday April 7 2010

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

  • What is the most important thing you weren't taught in school?

    - by Alexandre Brisebois
    What is the most important thing you weren't taught in school? What topics are missing from the CS/IS education? Posted so far How to sell an idea Principles: Often, good enough is better than perfect. Making mistakes is actually a Good Thing™ -- as long as they're new mistakes. If a user can break your code they will. In the Real World™ they're all open-book exams Self confidence is way more important in getting ahead than intelligence. Always prefer simplicity over complexity. The best code is the code that you don't write. You never know when you'll meet someone again ... or where. It's always worthwhile to treat people with respect and kindness. Be aware of what you don't know and don't be afraid to ask questions when you need to Missing knowledge: How to communicate effectively. Lack of source control Lack of Softskills experience How to productize code How to write secure code How to formulate problems How to self-measurement. To evaluate ones true competences and market worth. How to debug code How important is backup How to read code on a large scale (being able to adapt and build upon existing projects) Good Regular expressions comprehension How to teach others effectively TDD/Unit testing Critical thinking How to integrate different skills and languages in a single project

    Read the article

  • WiX - Modifying an existing service to be dependent on the service I am installing

    - by Paul Nearney
    Hi all, Using Wix3, its trivial to ensure that a windows service being installed is given a dependency on a service that is already installed on the target machine, but I need to do the opposite - i.e. as part of my install I need to modify the service dependencies of an existing service (i.e. already installed on the target machine), to ensure that that service is dependent on the service I am installing. Is there a simple way to do this using WiX? or will I need to write a custom action? Many thanks, Paul

    Read the article

  • Accessing the relationship of a relationship with Entity Framework

    - by J. Pablo Fernández
    I the School class I have this code: from student in this.Students where student.Teacher.Id == id select student The Student class there are two relationships: Teacher and School. In the School class I'm trying to find out all the students whose Teacher has a given id. The problem is that I get System.NullReferenceException: Object reference not set to an instance of an object. in the statement student.Teacher.Id I thought of doing this.Students.Include("Teacher"), but this.Students doesn't have such a method. Any ideas how can I perform that query?

    Read the article

  • Silverlight DataStateBehavior, initial value not used

    - by JimmySavile
    Hi, I am trying to use the Silverlight DataStateBehavior, it works fine in most cases where I click a button which sets say a 'Selected' Property in the view model to either false or true. The DataStateBehavior then tells the VisualStateManager to go to the relevant state. Like this: <Button...> <i:Interaction.Behaviors> <id:DataStateBehavior Binding="{Binding Selected}" Value="True" TrueState="SelectedVisualState" FalseState="DeselectedVisualState"/> </i:Interaction.Behaviors> </Button> The above works fine. What I am trying to do though is to get it to set the correct state when the application loads, if I were to set the 'Selected' property on the view model to true by default I wouldn't see any changes in the UI until I clicked the button to change the viewmodel property. I know there are several classes involved with the DataState stuff including: BindingListener.cs ConverterHelper.cs DataStateBehavior.cs DataStateSwitchBehavior.cs DataTrigger.cs Any clues would be good, Thanks

    Read the article

  • How to enter text in AJAX HTML Editor using watin

    - by Shaki
    Hi, I could not figure out how to enter text into HTML Editor using Watin. I tried //ie.TextField(Find.ById("htmlDetail_ctl06_ctl04")).TypeText("ABCD"); But got error: Can't move focus to the control because it is invisible, not enabled, or of a type that does not accept the focus. Can you give some example how to enter text into AJAX HTML Editor using watin please? I am not sure what to plug in frameSrc and java script from this solution - http://stackoverflow.com/questions/939448/unit-testing-the-ms-ajax-toolkit-html-editor Here is html from Develper tool when click the text box: Thanks in advance

    Read the article

  • Generating scriptaculous ajax.autocompleter on the fly

    - by user279992
    I have a form where the user can dynamically add a new table row with fields. I'm using a simple insertCell/InsertRow with innerHTML to generate the new row. One of those form fields is using scriptaculous' ajax.autocompleter. I have it generating new IDs for all the elements, but it is still not working The new row generated by js has the same source as the initial row of the form that loads at run time, however it does not appear to be calling the autocomplete function. I think my problem lies in that I don't understand when/how the "new Ajax.Autocompleter" is called. Is it not possible to use ajax.autocompleter like this? TIA

    Read the article

  • % operator for time calculation

    - by Chris
    I am trying to display minutes and seconds based on a number of seconds. I have: float seconds = 200; float mins = seconds / 60.0; float sec = mins % 60.0; [timeIndexLabel setText:[NSString stringWithFormat:@"%.2f , %.2f", mins,seconds]]; But I get an error: invalid operands of types 'float' and 'double' to binary 'operator%' And I don't understand why... Can someone throw me a bone!?

    Read the article

  • Why does this code read all ' ' for the anything after the 4th character?

    - by djs22
    #define fileSize 100000 int main(int argc, char *argv[]){ char *name=argv[1]; char ret[fileSize]; FILE *fl = fopen(name, "rb"); fseek(fl, 0, SEEK_END); long len = fileSize; fseek(fl, 0, SEEK_SET); //fread(ret, 1, len, fl); int i; *(ret+fileSize) = '\0'; for (i=0; i<fileSize; i++){ *(ret+i)=fgetc(fl); printf("byte : %s \n", ret); } fclose(fl); } In the above code, when I feed the name of a jpeg file, it reads anything after the 4th character as ' '...any ideas? Thanks!

    Read the article

  • Page content bleeding past footer, dynamic resize?

    - by Spider
    Hey all im learning as i go with editing CSS and PHP and ive manage to put together a layout, looks fine on the main page, but I noticed the content is not stretching properly height wise when i goto click on the 3D gallery. Here is the a link to the page that has the issue: http://www.idreamfx.com/wp/?page_id=36&album=1&gallery=2 as you can see its bleeding past the footer, and the content section is not resizing properly. What steps do i take to allow it to be dynamically resized with the content in it? Doing some searching i came across the code: but i'm not sure if how or rather, where to apply such a code or what it really does?

    Read the article

  • SQL Logic Operator Precedence: And and Or

    - by nc
    Are the two statements below equivalent? SELECT [...] FROM [...] WHERE some_col in (1,2,3,4,5) AND some_other_expr and SELECT [...] FROM [...] WHERE some_col in (1,2,3) or some_col in (4,5) AND some_other_expr Is there some sort of truth table I could use to verify this? Thanks.

    Read the article

  • Can I resolve ASP.NET "~" paths without a Control being present?

    - by jdk
    I want to Resolve "~/whatever" from inside non-Page contexts such as Global.asax (HttpApplication), HttpModule, HttpHandler, etc. but can only find the Resolution methods specific to Controls (and Page). I think the app should have enough knowledge to be able to map this outside the Page context. No? Or at least it makes sense to me it should be resolvable in other circumstances, wherever the app root is known. Update: The reason being I'm sticking ~ paths in the web.configuration files.

    Read the article

  • What makes static initialization functions good, bad, or otherwise?

    - by Richard Levasseur
    Suppose you had code like this: _READERS = None _WRITERS = None def Init(num_readers, reader_params, num_writers, writer_params, ...args...): ...logic... _READERS = new ReaderPool(num_readers, reader_params) _WRITERS = new WriterPool(num_writers, writer_params) ...more logic... class Doer: def __init__(...args...): ... def Read(self, ...args...): c = _READERS.get() try: ...work with conn finally: _READERS.put(c) def Writer(...): ...similar to Read()... To me, this is a bad pattern to follow, some cons: Doers can be created without its preconditions being satisfied The code isn't easily testable because ConnPool can't be directly mocked out. Init has to be called right the first time. If its changed so it can be called multiple times, extra logic has to be added to check if variables are already defined, and lots of NULL values have to be passed around to skip re-initializing. In the event of threads, the above becomes more complicated by adding locking Globals aren't being used to communicate state (which isn't strictly bad, but a code smell) On the other hand, some pros: its very convenient to call Init(5, "user/pass", 2, "user/pass") It simple and "clean" Personally, I think the cons outweigh the pros, that is, testability and assured preconditions outweigh simplicity and convenience.

    Read the article

  • Expression Blend 2/WPF Book

    - by Michael Damatov
    I'm looking for an Expression Blend 2 book that includes best-practices (Expression Blend 2/Visual Studio 2008) designer perspective (Expression Blend 2) programmer perspective (interoperability with Visual Studio 2008) How-To-chapters for Windows Forms developers (how to solve the same problem with WPF) Could you make a recommendation?

    Read the article

  • fatal: http://myserverip/home/git/example.git/info/refs not found: did you run git update-server-i

    - by bobobobo
    I followed this example to set up a git repository on my server. It worked, and I successfully pushed my code to it. But now, how do I pull or clone? Using the docs, I tried git clone http://REMOTE_SERVER/home/git/example.git .. But for me, I'm getting: fatal: http://myserverip/home/git/example.git/info/refs not found: did you run git update-server-info on the server? I ran git-update-server info, but nothing changed Edit: Ah, hold on. I changed it to git clone ssh://REMOTE_SERVER/home/git/example.git and I'm getting something.. it wants my user/pass, but how do I make the server public then not requiring login?

    Read the article

  • Help me a routing server on Windows XP

    - by Lu Lu
    I am developing client/server applications and need to test them on Internet environment. However, I only have one PC without connecting the public internet, so I have a plan to simulate a virtual internet environment on my PC. I think I will install the virtual machines for my purpose, but I can install only one machine because of my slowly PC. At the moment, my PC has 2 machines: the host machine (use Windows XP) & the virtual machine (use Windows Server 2003 Ent). Each machine will have 2 network adapter (host-only & internal), and in 2 network adapters, the internal adapter is private on each machine, and host-only adapters are connected together. With Windows 2003, routing server is ok, but I wonder on Windows XP, are there any routing server product? Please help me. Thanks.

    Read the article

  • linux dns server

    - by Clear.Cache
    Can someone explain to me how to easily setup a centos 5 (64bit) dns server? I want to use this strictly for dns for my clients who require rdns (ptr) for their domains. I do have IP delegation/authority from the data center and allocated IPs directly from ARIN. I just want to setup a Centos 5 box to use strictly as a dns server, perhaps with redundancy with a secondary, clustered (or not) dns server Server 1 = dns1.mycompany.com Server 2 = dns2.mycompany.com Then, I need simply instructions on how to create rdns records for clients upon request, especially in bulk amounts. Thank you.

    Read the article

  • Is there a way I can use $PATH as defined by my bash profile?

    - by Adam Backstrom
    I spend most of my day ssh'd into servers. I have a series of aliases/functions/scripts that allow me to type p hostname from the terminal and execute GNU screen(1) on the remote side, using the following command: exec ssh hostname -t 'screen -RD'` I've only recently noticed that ssh -t does not get my custom $PATH. Here's some terminal output: adam@workstation:~:0$ sh server 'echo $PATH' /home/adam/bin:/usr/local/bin:/bin:/usr/bin:/opt/git/bin:/opt/git/libexec/git-core adam@workstation:~:0$ ssh server -t 'echo $PATH' /usr/local/bin:/bin:/usr/bin Connection to uranus.plymouth.edu closed. My biggest problem is my custom aliases only try to execute screen, since I can't guarantee an absolute path, and my $PATH is structured so the shell should find the correct one. If my $PATH settings aren't honored, my scripts don't work. Is there a way I can use $PATH as defined by my .bashrc/.bash_profile? I believe PermitUserEnvironment is disabled.

    Read the article

  • Can't install Windows Desktop Search 4.0

    - by Ben Baril
    On a windows XP system, I try to download and install Windows Desktop Search 4.0 and it fails. The error I get: Windows Search 4.0 could not be installed on this system. For more details, check the log file. (C:\Windows\KB940157.log) The contents of that file: http://pastebin.com/MW37NXCy No idea how to resolve this. Any help is extremely appreciated!

    Read the article

  • Serialize a C# class to xml. Store the XML as a string in SQL Server and then restore the class late

    - by BrianK
    I want to serialize a class to xml and store that in a field in a database. I can serialize with this: StringWriter sw = new StringWriter(); XmlSerializer xmlser = new XmlSerializer(typeof(MyClass)); xmlser.Serialize(sw, myClassVariable); string s = sw.ToString(); sw.Close(); Thats works, but it has the namesapces in it. xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" Will these slow down the deserialization because it will go out to those and verify the XML? I got rid of the namespaces by creating a blank XmlSerializerNamespaces and using that to serialize, but then the xml still had namespaces around integer variables: <anyType xmlns:q1="http://www.w3.org/2001/XMLSchema" d3p1:type="q1:int" xmlns:d3p1="http://www.w3.org/2001/XMLSchema-instance"> 3 </anyType> My question is: Is it necessary to have the namesapces for deserialization and if not, how to get rid of them? How do I tell it fields are ints so it doesnt put in "anytype" Thanks, Brian

    Read the article

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