read

VBScript to search two Strings in a TXT

Hello, i try to make a VBScript that read a txt and search for two strings and gives out only the last results. String 1: Hello123 String 2: Test123 The TXT looks like this: 27.07.2010 09:45 ... DumDumDum ... 27.07.2010 09:45 ... BlaBlaBla ... 27.07.2010 09:45 ... Hello123 ... 27.07.2010 09:45 ... BlaBlaBla ... 27.07.2010 09:45 ...

read sniffing data over tcp

i'm developing application that is listening to the data coming to the pc and store it in a db when i'm trying to use any sniffing software it decode the data and i can read it... but in my code ....i cant read it at all it come in a format like that 182226215162234181711881551821161612152094113192157204151991232141301822451045348206...

Reading from a file in assembly

I'm trying to learn assembly -- x86 in a Linux environment. The most useful tutorial I can find is Writing A Useful Program With NASM. The task I'm setting myself is simple: read a file and write it to stdout. This is what I have: section .text ; declaring our .text segment global _start ; telling where pr...

batch, read texts files in n'th line to m'th line

hello, I am new about batch command. I have five text files in different folders. For example, c:\case1\case1.txt c:\case2\case2.txt c:\case3\case3.txt So I want to read these text files from nth line to mth line and write these values in same text file. How can I make batch files? For example, the result text file I want is.... ca...

Uninterruptible read/write calls

At some point during my C programming adventures on Linux, I encountered flags (possibly ioctl/fcntl?), that make reads and writes on a file descriptor uninterruptible. Unfortunately I cannot recall how to do this, or where I read it. Can anyone shed some light? Update0 To refine my query, I'm after the same blocking and guarantees th...

reading .key file android

I have problem when i try to read a .key file. This file is created by a normal java (J2SE) and i read it from android application. When i read this file from android it gives me nothing and i have done some debugging and i noticed that it can't read the file. Also i have checked if i can read the file (using file.canRead()) and it appea...

built predicate into prolog

input = * value = 3 output = ***(3 star) use prolog to write out the coding when key in value is 3 than the output is ***(3star) or when key in value is 5 than output is *****(5 star). so i want to ask what are the coding in prolog for this question. my answer is like below but cannot compile and have error. can check for me?? start...

Reading and comparing lines in a file using Python.

I have a file of the following format. 15/07/2010 14:14:13 changed_status_from_Offline_to_Available 15/07/2010 15:01:09 changed_status_from_Available_to_Offline 15/07/2010 15:15:35 changed_status_from_Offline_to_Away became_idle 15/07/2010 15:16:29 changed_status_from_Away_to_Available became_unidle 15/07/2010 15:45:40 changed_status_f...

Reading file using python and and see if a particular string is there inthe file.

I have a file in the following format Summary;None;Description;Emails\nDarlene\nGregory Murphy\nDr. Ingram\n;DateStart;20100615T111500;DateEnd;20100615T121500;Time;20100805T084547Z Summary;Presence tech in smart energy management;Description;;DateStart;20100628T130000;DateEnd;20100628T133000;Time;20100628T055408Z Summary;meeting;Descrip...

Problem extracting text from text file perfectly in VB6

Hi everyone, I am working on a VB6 project and I need to extract plain text from a text file. Here is code of the function I used to do that: Private Function FileGetText(TextFile As String) As String Dim FileContent As String Dim TextLine As String Dim n As Integer n = FreeFile Open TextFile For Input As #n 'Open given Text File Do Un...

Groovy read text file but omit header

This is a follow up to the question asked here: http://stackoverflow.com/questions/3360191/groovy-parsing-text-file The difference now is my file has a header, I attempted to read past the header first and then onto the content that I am wanting, but for some reason it doesn't seem to cooperate. def dataList = [] def theInfoName = 'tes...

Why multiple read reduce so dramaticaly the performances ?

I'm trying to understand and if possible tune my read performance from our direct-attached storage. Host : centos 5.4 2 * Intel Xeon E5520 24 Gib of memory gpfs filesystem I/O Scheduler is set to deadline, cfq doesn't seem to improve anything. Storage : 60 2Tb drives hardware raid 60 (6 * 10 drives) 8GB fiber channel connexion ...

PHP read command from file and run it

Hello, I have a unix command written in a file and I need PHP to read it and execute it. The reason it needs to be read from a file is because the commands symbols mess up the script when put them directly in it. So far I have this: <?php $command = readfile("http://localhost/command.txt"); echo shell_exec($command); ?> Upon running...

What is the best way to create an rw pipe with c++?

I have a program A that needs to send commands to the stdin of a program B and reads back the output of this program B. (Programming in C++, not linux only) ProgramA -> send letter A -> ProgramB ProgramA <- output of B <- ProgramB I actually have the first part, send commands to B, working with popen(). I do know that popen is a one wa...

Read from an existing text file(.txt) in sql server 2005

My gps device writes its data to a text file in my server. Now i want sql server to read it and store values in a table. How to get started with this kind of a scenario? Any suggestion. EDIT: Consider it is an existing file with 10 rows and i have already imported it. Now the file gets updated with new 10 rows. How to import the new row...

IE reading/writing on client end

Hi Everyone, Is there a way to read and write files on a client's computer using a web based application? Basically I need to create a internal app that will take two input CSV files and convert it into an output CSV file that is written to the same location as the input files on the client's computers. Since this is an internal app, I...

Reading files using Python

I have a file of the following format. "08-10-2010 13:29:31 1 APs were seen " "08-10-2010 13:29:31 MAC Address SSID RSSI" "08-10-2010 13:29:31 00:1e:79:d7:d5:b0 -80" "08-10-2010 13:30:32 2 APs were seen " "08-10-2010 13:30:32 MAC Address S...

How to read java stream until certain byte is reached

My question is similar to this post. But I don't send packet length rather a 0 byte at end. http://stackoverflow.com/questions/833744/most-efficient-way-to-read-in-a-tcp-stream-in-java So I'm wondering how would I code something that would. At the moment I just use this.socketIn = new BufferedReader(new InputStreamReader(this.socket....

Way to get value of this hex number

import binascii f = open('file.ext', 'rb') print binascii.hexlify(f.read(4)) f.close() This prints: 84010100 I know that I must retrieve the hex number 184 out of this data. How can it be done in python? I've used the struct module before, but I don't know if its little endian, big..whatever.. how can I get 184 from this number ...

Accessing C# user settings from a C++ Application

I am writing a C# program in Microsoft Visual Studio 2010 that stores some information inside of the local user settings like so: Properties.Settings.Default.userActive.Add(connection.Active); Properties.Settings.Default.Save(); I also have a Visual C++ application that would like to read these stored user settings. Is it possible f...