6,015 Topics
![]() | |
Hi, I have written a polling service that checks a directory for new files & then distributes them to new locations. The service is so quick, that no soon as the file has arrived in the watched folder, it is moved in to its new location. One concern that I … | |
Hello everyone, I am trying to write to a file what I am currently displaying on the console. I have a bit of code that works fine by creating a list of files based on it's file extention and it then displays it using println: What I want it to … | |
I just want to ask what this code practically means? [CODE]<xsl:variable name="gSetValues" select="toolPackage:setValues($obDateFormat,$gDocID)"/> <xsl:variable name="gSmi" select="normalize-space(toolPackage:PubMetaDataReader.getEntry($gKey, 'smi'))"/> <xsl:variable name="obDateFormat" select="toolPackage:LNDateFormat.new('<input format date>', '<output format date>', 'ENGLISH', 'German', '19000101', '365', '19000101')"/> <xsl:variable name="vFormattedLoadDate" select="toolPackage:reformat($obLoadDateFormat,$gLoadDate,$gDocID)"/>[/CODE] I don't understand the 'totalPackage' followed by setValues,LNDateFormat,PubMetaDataReader.getEntry,reformat ? How can I connect each different 3 XML … | |
I'm relatively new to this and need help counting the number of times a user provided word appears in a user provided file this is what I got:[CODE]#include <iostream> #include <fstream> #include <string> using namespace std; int main() { ifstream infile; string str, filename; int count, num; count = 0; … | |
Hi guys, I've got a question that hopefully someone can answer. I have a file that contains the following structure: g hub f 100 200 300 12 f 356 403 345 484 f 333 212 1203 393 g door glass f 323 9292 383 f 32 3838 3939 f 1231 … | |
Trying to make a quick little tool in response to the [URL="http://www.msnbc.msn.com/id/42348642/ns/technology_and_science-security/"]FBI's request for assistance[/URL] on cracking a code.. getting an error that takes me outside the scope of my program.. not sure what is causing the problemo. Maybe another set of eyes can help: [CODE] #include <iostream> #include <fstream> … | |
OK I'm pretty green at this so do bear with me. What I want to do is have an area where people can upload files to me. I found a script that I'm trying to make work and I've almost got it there but I'm having an issue. Everything actually … | |
My original plan was to pipe "ls -l", get the permission string that represented the file in question. Translate the string of 'r's 'w's 'x's '-'s into 0s and 1s then convert it from binary to octal. This seems really cumbersome and annoying and I gotta figure there is some … | |
I have made floyd warshall algorithm. I need some help for finding shortest path from source to destination. We have to give source and destination. Eg. Program gives us output like source=A and destination=D then shortest path is A-B-D with distance 10. I also give the code for that in … | |
[B]TL;DR:[/B] I am asking for help considering the structure on the following code, and advice on code structure in general. The problem in this case is the try blocks, which are messing up the scopes and complicating error handling. I will elaborate a little for the more patient readers below … | |
Hi all... I am trying to upload 4 files on a local disk, onto a remote ftp server. All of them are in the same folder(in local machine). I am using the storbinary function of ftplib. Following are the file sizes: 1-- 70 KB 2-- 60 KB 3-- 73 KB … | |
I am having a lot of trouble getting the following to work and I think it is because of file issues: [CODE]int GetMinutes() { fstream file(FNAME); char num[101]; if (!file.is_open()) Error("FILE NOT OPEN!"); file.getline(num,100); file.close(); return atoi(num); } int main(int argc, char *argv[]) { LARGE_INTEGER timestart, timestop, tickspersecond; QueryPerformanceFrequency(&tickspersecond); QueryPerformanceCounter(×tart); … | |
This is a program for displaying image files. I downloaded this program template from Microsoft. I executed the program and open an image file to display, and everything seems to be working fine. However, when I continue to open another image file - which is different from the first one … | |
I dont know shell scripting, It will be great help if someone help me in writing the script for below requirnment Requirnment: I have a file in which sql quires are written.I have to replace content of that file. sql file looks some what like below [CODE] #partial content of … | |
Hi everyone. I have an application where users submit text files and then based on some rules, the application gives instant responses of whether the submitted text file is right or wrong. What actually happens behind the scenes is that I have the correct text file on the server and … | |
How to upload file with oracle database 10gR2?? i can't find how to upload.. i've tried to create a procedure in oracle and execute in netbeans but the file save in directory and then from directory save to database. it means the file save in 2 location, in directory and … | |
Hello everyone I'm using dreamweaver CS5. I have widgets like slideshow filmstrip; youtube; and twitter im trying to upload unto my server go daddy, but it doent reconize my spry can anyone help. Aposse | |
Hi. I'm wanting to append some information to a file, which is found in a different file. I have simplified the problem using animals. Here is the basic code to add the line to the file: [CODE]grep "some important info about rabbits" rabbits.data >> rabbits.txt[/CODE] Very simple, but this must … | |
hey friends... i am using fedora 13... when i am trying to access a database i am getting this error-- mysql> use bgm_scr; ERROR 1044 (42000): Access denied for user ''@'localhost' to database 'bgm_scr' --------------------------------------- i also tried accessing by switching to superuser.. but i get this error -- [CODE][user@localhost … | |
I can read from files that are uploaded but now I would like to INSERT the data entered on the file to be inserted to mysql database. But not sure how this work. Tried to search few term and I have tested few methods. Nothing works. [CODE]<?php if ($_FILES["file"]["error"] > … | |
Hello. I've got a homework assignment involving reading an unspecified number of numbers from a data file, storing it into a dynamically allocated array and doing various sorts and such(the output is basically a list of grades on some test that I do stuff like sort, average, give an accurate … | |
Hi... I have a problem to load a PDF file which is stored on another machine.I had loaded the PDF on the same machine using following PHP script.Here I had used a hyper link to load PDF. [CODE] <?php $file="first"; $pdfFile=$file.".pdf#page=1"; ?> <a href="<?php echo $pdfFile; ?>" target="_blank" > Click … | |
Hi There I just wanna find out how I can save some data to a text file or access database (doesn't matter - the one that's the quickest). What my form does is it has a list box with ID's in it. I can select them. Then I have a … | |
this is the code for selecting the file to be deleted by the user [CODE=HTML] <title>File Delete</title><form enctype="multipart/form-data" action="delete.php" method="POST"> <input type="hidden" name="hidden1" value="file to be uploaded in AldrichSample folder" /> Please choose a file: <input name="deleted" type="file" /><br /> <input type="submit" value="DELETE" /><br /> <input type="reset" value="cancel" /><br /> … | |
1.<?php 2.$con = mysql_connect("localhost","root","")or die (mysql_error()); 3.mysql_select_db("registration", $con); 4.function protect($value){ 5.$value=mysql_real_escape_string($value); 6.$value=stripslashes($value); 7.$value=strip_tags($value); 8.} 9.if(isset($_POST['upload']) && $_FILES['file']['size'] >0) 10.{ 11.$fileName = $_FILES['file']['name']; 12.$tmpName = $_FILES['file']['tmp_name']; 13.$fileSize = $_FILES['file']['size']; 14.$fileType = $_FILES['file']['type']; 15.$fp = fopen($tmpName, 'r'); 16.$content = fread($fp, filesize($tmpName)); 17.$content = addslashes($content); 18.fclose($fp); 19.if(!get_magic_quotes_gpc()) 20.{ 21. $fileName = addslashes($fileName); 22.} … | |
Hi there guys, I recently swtiched to Ubuntu Lucid, and just want to know if there is something like an "App store" for Ubuntu apps? Since my Ubuntu machine is not connected to the net, i can't use the software centre. So I have to download the packages and install … | |
First of all, I would like to apologize if I have posted this in the wrong forum. If I have made this mistake, please tell me where this should be placed and I will quickly fix that. Okay, now to the problem. I downloaded a zip file and extracted it … | |
I have a reg text box and just want to add the save command, I managed to figure out how to do open but save is giving me problems. I am fairly new at VB.net been coding less then a week so I need all the help you can give … | |
Hey everyone, I've got a problem. Say I've got two xml files, a student file and a class file. The class file displays all the students in a class; eg- [CODE] <Class> <Student> a </Student> <Student> b </Student> <Student> c </Student> </Class> [/CODE] And the student file stores the details … | |
![]() | I had recently made a .bat file that read a couple lines from file.txt and assigned them as variables then went through the execution of the bat which ended up deleting the original file.txt and writing the new values to a new file.txt. Now I want to convert this to … |
I am currently having problems displaying a file correctly once i have written a dictionary to the file. For this program the input file needs to have the format: ID: Date: Dayskept: ProductName e.g. 1:12/12/2011:12:A This is fine the first time I read the example file into a dictionary, but … | |
Hello Everyone, I am trying to emulate a T9 (cellphone) keyboard in C. So lets say a user types in the numbers "23", a possible word combination would be "be". In my question here, I will only write down a part of what I have assuming it only works for … | |
<?php $con = mysql_connect("localhost","root","")or die (mysql_error()); mysql_select_db("registration", $con); function protect($value){ $value=mysql_real_escape_string($value); $value=stripslashes($value); $value=strip_tags($value); } if(isset($_POST['upload']) && $_FILES['file']['size'] >0) { $fileName = $_FILES['file']['name']; $tmpName = $_FILES['file']['tmp_name']; $fileSize = $_FILES['file']['size']; $fileType = $_FILES['file']['type']; $fp = fopen($tmpName, 'r'); $content = fread($fp, filesize($tmpName)); $content = addslashes($content); fclose($fp); $sql = "INSERT INTO signup_image (name, size, … | |
I've been making a program which reads several strings from a Notepad file which's location is set through user input. Then they enter a string which is in the file, a positive message is shown if it's not then a negative one is shown. However I can only scan the … | |
Hi All; need java code to upload and download excel files to the file system.. | |
I have tried many ways to download the files in a listbox. non-seems to work. the listbox has url eg: [ICODE] [url]http://www.hahaww.com/2.pdf[/url] [url]http://www.hahaww.com/f1.pdf[/url] [url]http://www.hahaww.com/24.pdf[/url] [/ICODE] I want to download the files until ListBox.Items.Count = 0 which each file with number ording... for eg: 2.pdf will be 1.pdf f1.pdf will be … | |
[CODE]File.Delete(saveFileDialog1.FileName);[/CODE] Giving error in the above code giving exception as not a legal action form Can any one help Actually From main Function m calling a function(which writes and creates the file asking from savedialog1) and after retruning from function it browse for another file to read if user is … | |
I use [CODE] FileUpload.Filename = lbl1.text.ToString(); FileUpload.SaveAs(Server.MapPath("~/Photo/AllPhotoes/" + FileUpload.FileName)); [/CODE] and i got Error: Property or indexer 'System.Web.UI.WebControls.FileUpload.FileName' cannot be assigned. it is read only. I want to save image with label name which is hidden. and it get new value each time. how can i change image name with … | |
Write a program to allow a user to do conversions between two different units of measurement. So the user might type in an amount, and the names of two units of measurement, for example: 5, ounce, gram In this case the program should then print out the number of grams … | |
If I have an application written in Java, how can I make it available for purchase/download on my website? Namely, how do I obscure the source code so it can't be viewed, yet enable it to be executed by any machine (including ones that don't have the JVM installed)? | |
I have this code but the floats wont print to the file. Everything else prints and works well but the floats i see 0.000. Can someone tell me where im going wrong. I already declare them in the struct as float apaid; float tpaid; [CODE] customer customerinfo(customer info) { FILE … | |
hi..who knows how to append the list box to the exist text file? [CODE] FileStream fs2 = new FileStream(@"C:\Users\Fish\Desktop\fyp-coding\Combine.txt", FileMode.Append, FileAccess.Write,FileShare.Write);//create text file StreamWriter sw2 = new StreamWriter(fs2, Encoding.Default); string writetext = ListItemCom2.SelectedItems.ToString(); sw2 = File.AppendText(@"C:\Users\Fish\Desktop\fyp-coding\Combine.txt"); // write to the text file sw2.Flush(); sw2.Close(); [/CODE] this is my coding.But,it contain … | |
My site is broken into three different categories (which are stored on 3 separate tables) and I am looking at creating a functionality to let a user upload photos. Ideally, I would like the following to happen: [LIST=1][*]A user is viewing a single retail store on the site, for example … | |
hi, I now face some problems in saving the content of the listBox to the exist text file. i need to append the content to the text file and canot overwrite the content in the text file.Who can help me..? [CODE] FileStream fs2 = new FileStream(@"C:\Users\Fish\Desktop\fyp-coding\Combine.txt", FileMode.Append, FileAccess.Write, FileShare.ReadWrite);//create text … | |
I am working on a project and coding in Python 3.1 where I need to find a string in a file. I have already considered reading the file to a string and then using rfind() on it, but that does not seem to be efficient, seeing as how I expect … | |
Hi, I am making a script that takes the file contents of another chosen file on the same server, everything in the file is pulled into a textarea including the PHP in the file. I want to know how to then save all this data to a PHP file (temporary) … ![]() | |
I want to ask how to combine two text file and read in the rich text box..? [CODE] String rd = ""; private void CLICK2_Click(object sender, EventArgs e) { string file1 = @"C:\Users\Fish\Desktop\fyp-coding\sample1.txt"; string file2 = @"C:\Users\Fish\Desktop\fyp-coding\sample2.txt"; FileStream fs1 = null; FileStream fs2 = null; try { fs1 = File.Open(file1, … | |
I have an interface built in javafx but it currently does nothing it just looks nice. How do you download files from the web in javafx or java? How do you create files on the users system in java or javafx? How do you place downloaded files in the created … | |
![]() | I have been looking for an answer for the last few hours on google with no success. I am trying to create a program that will determine what file to open from user input. For example: names of the text files are xaa through xzz. The text files contain integers … ![]() |
Hi, At the moment i'm trying to locate xml files to use their content. I would like to be able find all files that have a particular pattern in their name (for example student_James.xml; student_Chris.xml so "student" would be the pattern). I want to be able to do this using … |
The End.