6,015 Topics
![]() | |
I have a file that contain data structure as below: L,13206,11,02,06,000,3981.100 19,22,25,26,19 END L,13207,11,02,06,000,6561.000 22,24,7,8,9,25,22 END K,[COLOR="Red"]1[/COLOR],P [COLOR="red"]-18970.811,53728.643[/COLOR],BKL,,e-Coord,M END so how can i extract 1 and -18970.811,53728.643 and export it into a new output file with new structured as below: C [COLOR="red"]1 [/COLOR] [COLOR="red"]-18970.811 53728.643[/COLOR] For your information, the value … | |
Hello Helper, This is my code. I want to compress the file encrypted and then decrypt the same original file.Can you help ? /* [CODE]#include<iostream.h> #include<conio.h> #include<fstream.h> #include<stdio.h> #define ENCRYPTION_FORMULA (int)Byte+25 #define DECRYPTION_FORMULA (int)Byte-25 int Encrypt(char *FILENAME,char *NEW_FILENAME) { ifstream fin; ofstream fout; char Byte; char NewByte; fin.open(FILENAME,ios::in,ios::binary); fout.open(NEW_FILENAME,ios::out,ios::binary); if(!fin) … | |
![]() | Hi folks, I know this ain't php, but seemed the best place to put it for now. Am trying to mod_rewrite the following: http://www.nu.wetwork.org.uk/index.php?adran=first&tud=second to http://www.nu.wetwork.org.uk/first/second/ I'm a complete idiot when it comes to regex/apache, so any advice would be welcome. I have already managed to place 2 rules which: … ![]() |
Hello, I'm checkng whether a file has been modified or not in order to refresh the content... However, i need a couple improvements : - How do I test the return value of stat to tell if it failed ? - The returned errno numbers may change between glibc versions, … | |
Hello, i have a function that starts searching for all files that match the given file name and Recursively traverses itself into sub directories and does the same thing and when a file is found i should output its path starting from the first directory that was given to the … | |
Hello, I am currenty using MySQL 5.1 community server and trying to import the data of the comma delimited text file into the table using python 2.6 scripts. I have installed Mysqldb 1.2.2. follwoing is my script: [CODE] import MySQLdb, csv, sys conn = MySQLdb.connect (host = "localhost",user = "usr", … | |
hello everyone .. im writting a C program that requires to insert integers from a text file .. the contents of the text file are: 1:2:4 4:12:5 13:7:5 1:20:4 how can i read each number and define it as an integer ???? please HELP !! [CODE] #include <stdio.h> int main() … | |
I have a directlry with log files example (logs/server.log.2009-10-17 or logs/server.log.2009-10-18) 2009-10-17 01:33:00,710 Beginning a.gzip 2009-10-17 01:33:56,704 Completed a.gzip 2009-10-17 01:33:56,704 Beginning b.gzip 2009-10-17 01:34:45,828 Completed b.gzip Now I have a directory which has all these files as well and if you do "zcat a.zip|wc -l you will find the … | |
hello all please help .. whenever I enter a path it tells me it cannot open the file here is the code: [CODE]# include <iostream> # include <fstream> # include <iomanip> using namespace std; struct count_type { int count; double percent; }; void intial_struct(count_type count[]); void open_file(ifstream&, ofstream&); void counter(count_type … | |
Hello, i wanted to know how to write a file path for every computer For example: [code]objwrite = New System.IO.StreamWriter("C:\Users\EVGA\Desktop\VB.Net Example\myfile.txt", False)[/code] this code work only on my pc cause of its path so i wanted to know how to write it so i can use it in another pc … | |
Hello. I am writing an ATM program for a project, but I am having problems matching the users entered pin with what is stored on the text file. Here is how i read the file [CODE]import java.io.File; import java.util.Scanner; import machine.*; import javax.swing.JOptionPane; public class FileRead { Transactions query = … | |
how do i get a function to write to a file for me?? im getting the error error: invalid use of void expression i want to save my tic tac game board to this file in order to save it..... am i going the right way about it?? [code] if(save_or_not … | |
hi there got a couple of probs, say in my text file i have: abase abased abasement abasements abases -------- This coding below is meant to find a word in a file and print all the lines to the end of the file. But it doesnt, it only prints out … | |
I have this code. I want to update the writes immediately to log file before closing the file (because my program might get hang and I have to exit it by ctrl+c so fclose would never be called). The code is: [CODE] 1 #include <stdio.h> 2 #include <stdlib.h> 3 4 … | |
Hi all, I have a very large amount of files I need to update, so I thought the easiest way would be to do it with php. [B]Below is the current directory structure[/B] [CODE]www.domain.com/branch_finder/country/county/town/[/CODE] I need to replace the existing index page in every "county" level directory inside the branch_finder … | |
Hi i want to compress the file on the file during FTP file download. Is it possible to do that. I have an application that downloads the files from remote FTP server as windows forms application using VB.net Please help Thanks | |
Hey everyone, I'm new to posting in these forums so sorry if I didn't post my code correctly? I think i did it...hopefully. Anyways, I've been working on this all day but I can't figure it out. (i think i will be having problems with the rest of my assignments … | |
If I Open a file using something like: FileStream^ fs = File::OpenRead( path ); How can I determine the size of the file so that I can read all of the data bytes in the file? What sort of Read would you use to read one byte at a time. … | |
Hi, Can anyone explain me, what is file system in solaris all about? Regards, Prashant | |
I am trying to get a handle on two things: building strings, and reading a file. I am trying to write a function that will pull a line from a file and put it into a string. I want to use it in a loop, so I am having the … | |
![]() | Hello people!! Hoping someone can help me out with this, i have a game of life program where a grid is draw using private string[,] paintSequence = new string[50, 50]; (note i tried switching to 2d string arrays, but this caused looooads of problems so switched it all back to … ![]() |
Hi all is it possible to delete the last line of a text file each time a method is called. I have the following method: [CODE] Writer output = null; File file = new File("playerData.xml"); try { output = new BufferedWriter(new FileWriter(file, true)); output.write("\t" + "<player>" + "\n"); output.write("\t" + … | |
Hi friends, I am facing a problem with Signed jar file. I have two jar files.One contains applet class and other jar file contains supportive classes used by that applet.I was able to self sign the applet jar file let name it as "ScreenApplet.jar" using jarsigner tool. The supportive jar … | |
Hi friends I am new to python. I have doc file and jpg file. I want to append jpg file content to doc file. How to achieve this with python please help me. | |
I am not able to shearing my foler by another pc, opson is dissable | |
Hi. I am having some problems with files. I am trying to read some contents from a file, transfer them to an array and then read the contents of the array. The problem that I am facing is that the output is not that is suppose to be. The file … | |
My teacher gave use a project were we have to read a text from a file and then output some results. I have got C++ to read the text from file but I have to average out each persons test scores and then output them. I am not sure how … | |
I have written a function which will open the file with the input name provided.I am compiling on a Linux box using g++ compiler.Detail code below Plz let me know what is the wrong in code. [CODE]1 #include<iostream> 2 #include<fstream> 3 #include<string> 4 #include<stddef.h> 5 #include<cstddef> 6 #include<cstring> 7 8 … | |
The program needs to read an excel file that contains a list of data (a list of students, thier module mark, student ID) The data needs to be presented in the following format: User ID : Name : Module ID : Mark The program also needs to have a menu … | |
Hello everyone. Got a bit of a weird problem here. I cant seem to figure out a way to read a file with a format like this... hello what 100 200 its a string string integer integer i need to put each of those values in separate arrays. eg: array1[0] … | |
I am taking entry level C++ course, and I am having trouble with my assignment for this week on Sequential Files. Here is my assignment: Create a C++ console application that analyzes the contents of a text file. Your program should count the number of: lines (hint: use getline) words … | |
I need help creating a program. I have a text file that is 0's and 1's which create a picture. There are 33 rows and 50 columns. Every row contains 0's and 1's. what i need to do is do a program that will read the zeroes and ones and … | |
Hi, everyone! I'm new to DaniWeb and also to PHP and MySQL. I have a script, previewfile.php, that extracts files of various file types (currently .doc, .docx, .xls, .xlsx, and .pdf) from a MySQL database and is supposed to display them to the user. I'm encountering difficulties in displaying the … | |
i am trying to send a file using tcp on the local host itself but not sucessful. here iz the program tht i am trying to use. server side [code] [import java.lang.*; import java.io.File; import java.io.InputStream; import java.io.FileInputStream; import java.net.Socket; import java.net.ServerSocket; public class FileReceiver implements Runnable { private static … | |
Thanks for your input vegaseat. I have posted the code that is giving me the problem in the two scripts and I hope you can comment further. Thanks in advance - Elvedon. [CODE]#The script displayed below is only part of the larger original script.# #filename = 'firstScript.py' #!/usr/bin/python from Tkinter … | |
Hey guys, is there any program out there that will scan a directory of files and record its file size on disk and its name? I've been searching and can't seem to find anything. | |
The backstory: I want to be able to sell this embedded system that I'm creating, a large part of which relies upon an executable piece of software running under the windows operating system on a small PC board in the unit. Software updates for the customer should be easily enough … | |
i have this program and i'm already done with the data entry, search, display and exit menu.. my only problem is my search and delete and the search and edit...please help me. i've attached my unfinished program here: Programming Assignment: Write a program to simulate a telephone directory. The user … | |
Hi, I want to edit a record inside a txt file. So first a search for the record inside the file and display the record to the user. But for example, if the user want to edit the name, how I can go to that position? [CODE] void editar_cliente() { … | |
i'm writing a program that creates a file called 'hardware.dat' and i'm supposed to be able to insert a record, update, and delete a record. first i'm having problem with the insertrecord cause it keeps giving me an infinte loop. i'm creating file that would hold these data: record # … | |
Hi ! My script don't understand file name with "interval", help me with it problem !!!! [CODE] use Cwd; $dir = cwd(); $vardas=$dir; while($vardas=~/(.*\/)+(.*)/){ $vardas="$2_source"; } $newfile = "$dir/$vardas.tex"; FILE: foreach $file (<@ARGV>) { if ($file eq $newfile) {next FILE}; if (-e "$dir/$vardas.tex"){ print "File exist\n";} else{ print "Rename: "."$file\n"; … | |
I have an program that allows a user to input their employee name and number and then their hourly wage and their total number of regular hours and overtime hours. Then writes out the data to a binary file. The program I need assistance with reads in that file, adds … | |
Hi there, I'm relatively new and I'm making a program that reads reads a txt. file stores it in an array, validates and finally displays back. However I'm not getting the desired display when I tell my program to display txt. file contents, I get some of the correct content … | |
Hello Devs, Wondering about permissions-based web software to have a registered user (client) upload file to server host, perhaps for a fee, and have server host take file and store it. Is there a somewhat streamlined solution for this? I realize this can be achieved with sophisticated software such as … | |
Hi, I need help with this. I basically want users to enter their name email address with validation and also have a tick box for them to say yes or no to receiving future updates. This information will be sent to an email address not a database on clicking the … | |
Hi I have took from internet PHP script that uploads images to the host [CODE] <form name="upload-form" id="upload-form" method="post" action="./upload.php" enctype="multipart/form-data"> <input type="hidden" name="MAX_FILE_SIZE" value="30000"> <fieldset> <legend>File upload:</legend> <dl> <dt> <label for="file">File:</label> </dt> <dd> <input tabindex="1" accesskey="b" name="file" type="file" id="file" /> </dd> </dl> <input tabindex="2" accesskey="l" type="submit" name="cmdupload" value="Upload" /> … | |
I want javascript to download a file automatically in every 3 mins and save it to my server. Is it possible. What will be the javascript code? thanks Lavi | |
Hello! I had a question about appending data in to a file. My program flows in the following way-- [CODE] // This function reads data from the file parse_input_data_for_one_algo(some parameters) { FILE *f = fopen (filename, "rw+"); while ( fgets (in_line, 100, f) != NULL ) { //read values } … | |
like isnt there a way to update an rss feed without using other programs? i have an .rss feed and it has like 10 entries or whatever they are callled but its only because i cant update it manually everytime i want to. that would be rediculous. also ihave some … | |
I'm a newbie trying to modify the code in an AJAX tutorial to load data from an XML file, and it is not working. The code is in a php file that is invoked with the URL: [icode]getXMLTest.php?showName=photoShowTest.xml[/icode] The code I've written (mostly copied from the tutorial, actually) is: [code] … |
The End.