Search Results

Search found 13 results on 1 pages for 'lox'.

Page 1/1 | 1 

  • How many lines of code can a C# developer produce per month?

    - by lox
    An executive at my workplace asked me and my group of developers the question: How many lines of code can a C# developer produce per month? An old system was to be ported to C# and he would like this measure as part of the project planning. From some (apparently creditable) source he had the answer of "10 SLOC/month" but he was not happy with that. The group agreed that this was nearly impossible to specify because it would depend on a long list of circumstances. But we could tell that the man would not leave (or be very disappointed in us) if we did not come up with an answer suiting him better. So he left with the many times better answer of "10 SLOC/day" Can this question be answered? (offhand or even with some analysis)

    Read the article

  • Remember login when connecting to another domain on Windows 2008 Sever

    - by lox
    I run Windows 2008 Server (x64) as a workstation and my computer is on one domain and my exchange server, shared folders and intranet is on another domain. Every time I connect to these eg. every time I open Outlook I am prompted to supply username and password in a "Connect to"-dialog and the "Remember password" option has no effect. What can I do to avoid this manual step every time?

    Read the article

  • Relative XPath node selection with C# XmlDocument

    - by lox
    Imagine the following XML document: <root> <person_data> <person> <name>John</name> <age>35</age> </person> <person> <name>Jim</name> <age>50</age> </person> </person_data> <locations> <location> <name>John</name> <country>USA</country> </location> <location> <name>Jim</name> <country>Japan</country> </location> </locations> </root> I then select the person node for Jim: XmlNode personNode = doc.SelectSingleNode("//person[name = 'Jim']"); And now from this node with a single XPath select I would like to retrieve Jim's location node. Something like: XmlNode locationNode = personNode.SelectSingleNode("//location[name = {reference to personNode}/name]"); Since I am selecting based on the personNode it would be handy if I could reference it in the select. Is this possible?.. is the connection there? Sure I could put in a few extra lines of code and put the name into a variable and use this in the XPath string but that is not what I am asking.

    Read the article

  • Consuming web service from BizTalk with authentication credentials

    - by lox
    I am trying to consume a web service from BizTalk by supplying credentials in the SOAP adapter port. I type in the Web Service URL and then I have the choice of Anonymous, Basic, Digest and NTLM authentication types. How do I supply my username, password and domain?.. when testing with soapUI it works perfectly. The only way I get to supply credentials is Basic or Digest but no matter what I fill in I get a "not authroized" error. The strange thing is that it actually works when I choose the NTLM authentication type but how does it get acces when I have not supplied the credentials. And there is no way that my server has direct access to the service?

    Read the article

  • SQL Server 2008 automated database drop, create and fill

    - by lox
    For the database in my project I have a drop/create script for the database, a script for creating tables and SPs and an Access 2003 .mdb file with some exported values. To set up the database from scratch I can use my SQL management studio to first run one script, then the other and lastly manually run the sort of tedious import task. But I would like to do this as automated as possible. Hopefully something like putting the three files in a folder along with a fourth script to execute. Looking something like: run script "dropcreate.sql" run script "createtables.sql" import "values.mdb" How is this done? I hope to avoid using SSIS and the like. The tricky this is of course the import of data, where I can't seem to find a simple way. It is also important that the files a left as they are and not embedded into anything.

    Read the article

  • how to read an arraylist from a txt file in java?

    - by lox
    how to read an arraylist from a txt file in java? my arraylist is the form of: public class Account { String username; String password; } i managed to put some "Accounts" in the a txt file, but now i don't know how to read them. this is how my arraylist look in the txt file: username1 password1 | username2 password2 | etc this is a part of the code i came up with, but it doesn't work. it looks logic to me though... :) . public static void RdAc(String args[]) { ArrayList<Account> peoplelist = new ArrayList<Account>(50); int i,i2,i3; String[] theword = null; try { FileReader fr = new FileReader("myfile.txt"); BufferedReader br = new BufferedReader(fr); String line = ""; while ((line = br.readLine()) != null) { String[] theline = line.split(" | "); for (i = 0; i < theline.length; i++) { theword = theline[i].split(" "); } for(i3=0;i3<theline.length;i3++) { Account people = new Account(); for (i2 = 0; i2 < theword.length; i2++) { people.username = theword[i2]; people.password = theword[i2+1]; peoplelist.add(people); } } } } catch (IOException ex) { System.out.println("Could not read from file"); } }

    Read the article

  • How to create a list/structure? in JAVA

    - by lox
    i have to create a list of ,let's say 50 people, (in JAVA) and display the list, and i don't really know how to do that. so this is what i have tried to do so far . please correct and complete some of my code . public class Person { String name; String stuff; } public class CreatePerson { public static void ang() { ArrayList<Person> thing=new ArrayList<Person>(); Scanner diskScanner = new Scanner(in); for(int i=0; i<50; i++){ Person pers = new Person(); out.print("name: "); pers.name=diskScanner.nextLine(); out.print("stuff: "); pers.stuff=diskScanner.nextLine(); thing.add(pers); break; } // Display people for (int i=0; i<50; i++) { out.println(??);{ } } }}

    Read the article

  • Maintaining sort order of database table rows

    - by Lox
    Say I have at database table containing information about a news article in each row. The table has an integer "sort" column to dictate the order in which the articles are to be presented on a web site. How do I best implement and maintain this sort order. The problem I want to avoid is having the the articles numbered 1,2,3,4,..,100 and when article number 50 suddenly becomes interesting it gets its sort number set to 1 and then all articles between them must have their sort number increased by one. Sure, setting initial sort numbers to 100,200,300,400 etc. leaves some space for moving around but at some point it will break. Is there a correct way to do this, maybe a completely different approach? Added-1: All article titles are shown in a list linking to the contents, so yes all sorted items are show at once. Added-2: An item is not necessarily moved to the top of the list; any item can be placed anywhere in the ordered list.

    Read the article

  • How to create and display a list in Java?

    - by lox
    i have to create a list of ,let's say 50 people, (in Java) and display the list, and i don't really know how to do that. so this is what i have tried to do so far . please correct and complete some of my code . public class Person { String name; String stuff; } public class CreatePerson { public static void ang() { ArrayList<Person> thing=new ArrayList<Person>(); Scanner diskScanner = new Scanner(in); for(int i=0; i<50; i++){ Person pers = new Person(); out.print("name: "); pers.name=diskScanner.nextLine(); out.print("stuff: "); pers.stuff=diskScanner.nextLine(); thing.add(pers); break; } // Display people for (int i=0; i<50; i++) { out.println(??);{ } } }}

    Read the article

  • how to read data from file into array? java

    - by lox
    I need some help reading data from a txt file into my ArrayList. I know the code is pretty messy, but just try to take a look at it. The first part with the creating and putting the ArrayList into the txt file works perfectly. I just need some help at the end in the "marked" area. Sorry if I still have some words in my native language, but I didn't really had the time to translate everything. public class ContAngajat { String username; String password; } public class CreazaCont { // creating the arraylist and putting it into a file public static void ang(String args[]) { ArrayList<ContAngajat> angajati=new ArrayList<ContAngajat>(50); Scanner diskScanner = new Scanner(in); Scanner forn = new Scanner(in); int n; out.print("Introduceti numarul de conturi noi care doriti sa le introduceti: "); n=forn.nextInt(); out.println(); try{ FileWriter fw = new FileWriter("ConturiAngajati.txt", true); for(int i=0; i<n; i++){ ContAngajat cont = new ContAngajat(); out.print("Username: "); cont.username=diskScanner.nextLine(); out.print("Password: "); cont.password=diskScanner.nextLine(); angajati.add(cont); fw.write(cont.username + " "); fw.write(cont.password +"|"); } fw.close(); } catch(IOException ex){ System.out.println("Could not write to file"); System.exit(0); } for (int i=0; i<n; i++) { out.println("username: " + angajati.get(i).username + " password: " +angajati.get(i).password ); } } // HERE I'M TRING TO GET THE ARRAYLIST OUT OF THE FILE public static void RdAng(String args[]) { ArrayList<ContAngajat> angajati=new ArrayList<ContAngajat>(50); ContAngajat cont = new ContAngajat(); int count,i2,i; try{ FileReader fr = new FileReader("ConturiAngajati.txt"); BufferedReader br = new BufferedReader(fr); String line = ""; while((line=br.readLine())!=null) { String[] theline=line.split("|"); count=theline.length; for(i=0;i<theline.length;i++) { String[] theword = theline[i].split(" "); } } for(i2=0;i2<count;i2++) { ContAngajat contrd = new ContAngajat(); // "ERROR" OVER HERE for (int ird=0; ird <theword.length; ird++) { cont.username=theword[0]; cont.password=theword[1]; // they keep telling me "theword cannot be resolved" whenever i try to run this } angajati.add(contrd); } } catch(IOException ex){ System.out.println("Could not read to file"); System.exit(0); } } }

    Read the article

1