User Profile

Collapse

Profile Sidebar

Collapse
anii
anii
Last Activity: May 26 '09, 02:33 AM
Joined: Oct 12 '07
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • anii
    replied to Search and replace char in same text file
    in C
    Hi donbock, thanks for your reply. I've changed the ("r") to ("r+") and tweeked the rest of the code to rewind and little and write.
    See more | Go to post

    Leave a comment:


  • anii
    started a topic Search and replace char in same text file
    in C

    Search and replace char in same text file

    Hi there,

    I've got this piece of code, but I'm having trouble getting it to write the changes into the file.

    What I'm trying to do is:
    • Read text file
    • Find user specified character (eg. what to replace all the a's)
    • Replace the character (eg. replace all a's with b's)
    • Write to the same text file


    Code:
    #include <stdio.h>
    #include <string.h>
    
    #define MAX_LEN_SINGLE_LINE
    ...
    See more | Go to post

  • anii
    replied to Loop to next sibling
    in XML
    Hi, sure! I've modified them all the documents slightly since my last post but here they are:

    customer.xml:
    Code:
    <?xml version="1.0"?>
    <customers>
    	<customer number="BL343456">
    		<meterNumber>134456</meterNumber>
    		<name title="">
    			<firstName>Bart</firstName>
    			<middleName></middleName>
    ...
    See more | Go to post
    Last edited by anii; Apr 15 '08, 07:36 PM. Reason: typos

    Leave a comment:


  • anii
    started a topic Loop to next sibling
    in XML

    Loop to next sibling

    Hi I'm a bit new to XML, and I was wondering if anyone could help me with my problem.

    I have one XML document (readings.xml) being linked to an XSLT document via JavaScript DOM, and am linking the another (customer.xml) through the select="documen t('customers.xm l')/customers/..." /> method in the XSLT document.

    I have this XML document (customer.xml):
    Code:
    <customers>
    	<customer
    ...
    See more | Go to post

  • anii
    replied to XML Element Content
    in XML
    Hi there! Thanks a bunch for your quick reply.

    Just wondering why you used PCDATA when declaring the elements
    eg. <!ELEMENT make (#PCDATA)>
    <!ELEMENT model (#PCDATA)>

    instead of the others this website has:


    I mean like how did you know to choose PCDATA for all of them?

    Also thank you for the code that you've put up. =) Its really helpful....
    See more | Go to post

    Leave a comment:


  • anii
    started a topic XML Element Content
    in XML

    XML Element Content

    Hi there, I'm new to writing XML (just a couple of weeks old) so please bear with me.

    I was wondering when it would be the right time to use PCDATA in the DTD. I think there are another two data types? CDATA and ANY?

    It says on this website that the difference between the two DATA ones is for parsing and I'm sure sure if in this context that thats what I'd like to do.

    This is what I've got at the moment:...
    See more | Go to post

  • anii
    replied to Reading an external csv file
    in C
    Sorry to double post, but I just wanted to add that I was using Microsoft Visual C++ 2005 Express for this. I've also checking it out using Dev-C++. So it doesn't seem like its a complier thing.

    Can anyone help or just look at the code up there please?
    See more | Go to post

    Leave a comment:


  • anii
    started a topic Reading an external csv file
    in C

    Reading an external csv file

    Hi! I'm working on a piece of code for school. =) in C++. (I've read the rules and understand that i can't put all of the code here and ask for all of the code) I've got all (or most) of the code done.

    I'm having trouble with the output.

    I'm supposed to:
    1. Enter a csv file (with info in it)
    2. Read the file
    3. Go through it one by one and sort it into a structure
    4. Sort it by the customer id (which is also used in the
    ...
    See more | Go to post
No activity results to display
Show More
Working...