Most voted "txt" questions
TXT is a file extension or file that stores text, and is structured as a sequence of lines. May have one or more special characters, known as an end-of-file marker, after the last line of text.
Learn more…182 questions
Sort by count of
-
13
votes3
answers1955
viewsPre-process large text files in R
I am writing a script, which I will make public, to open the micro-data of RAIS (dehydrated, available here) in R using Monetdb. However the bank does not accept vígula (,) as decimal separator.…
-
4
votes3
answers1458
viewsJavascript - Line break in file . txt
How to identify a line break in a txt using javascript ? Example: Essa é a linha 1 Essa é a linha 2 Essa é a linha 3 The file has these 3 lines and I want to put them in an array separated by the…
-
4
votes2
answers1359
viewsSearch specific value within a file . txt C#
I have a. txt file with the following lines: 000-000 = CRT 001-000 = 00000021 009-000 = 00 012-000 = 247823 013-000 = 0000559877 022-000 = 24082017 023-000 = 152842 032-000 = 80F1 100-000 = JORGE…
-
3
votes1
answer1395
viewsSum of several text files *.txt
I have a series of files in . txt and would like to add them / join all in one (Regardless of order). It is possible to do this by word vba, some other text editor, or other means?…
-
3
votes2
answers1174
viewsExport sql server query result to txt file on apache server automatically
I do the following query of my apache server in an SQL SERVER database: <?php // Dados do banco $dbhost = "192.168.0.100"; #Nome do host $db = "DATABASE"; #Nome do banco de dados $user = "root";…
-
3
votes3
answers569
viewsListbox - how to show full product name and bring up another column of values
I have this ListBox. When loaded he wears one txt file being like this: Code to load the ListBox: private void frmOrdemServico_Load(object sender, EventArgs e) { string[] d =…
-
3
votes1
answer431
viewsWrite to txt file save, read and save to one in another txt file
I just started working at a company that programs the Mifire cards and I’m in the experimental phase. Meanwhile the engineer ordered me to do a job. First stage: I have to enter two numerical values…
-
3
votes1
answer71
viewsRead something after a C#keyword
I have the following situation, I have a document(txt) that has some things 'filled' type: Nome:"João"; Idade:"20"; Estado:"SC"; The result I wanted is that the variables had only what is written…
-
3
votes2
answers1231
viewsHow to add text to a specific line in Python txt file?
I am trying to store data in a txt file, but I need to save it in specific lines. How to proceed? I’d like to do something like: data = open('arquivo.txt', 'a') data[linha específica].write('Texto…
-
3
votes1
answer500
views -
3
votes1
answer1023
viewsHow to create a . bat file directly from C#?
I am making a program in C# and in it I run a file . bat Look how I turn the file: string batDir = string.Format(@"C:\Users\Desktop"); proc = new Process(); proc.StartInfo.WorkingDirectory = batDir;…
-
3
votes2
answers65
viewsHow to convert a txt to csv in perl?
Hello, Little Boy. I am new to perl. I need to convert a txt file to csv. Follow the code I’ve managed so far. #!/usr/bin/perl my $filename = "interfaces.txt"; open(fh, $filename) or die "não…
-
2
votes1
answer674
viewsListview does not repeat records
I have a file txt with multiple records inside, I need something that at the time the function is added to the ListView these records, do not let repeat items be added. To do this, it could use a…
-
2
votes1
answer687
viewsThe control number V0102 of PNAD does not correspond to the code of municipalities of IBGE. How to unite the banks?
Hello! I’m working with food safety supplements from pnad04, pnad09 and pnad13 IBGE and two other IPEA banks, one on municipal GDP ipea.pib and other on investments in social programs by…
-
2
votes2
answers923
viewsGenerate Code text file done in Pascal
I have a code in Pascal. Here’s the thing: Program Pzim ; var i:integer; vect:array[1..1001] of integer; Begin i:=1; for i:= 1 to 999 do vect[i]:=i+1; for i:= 1 to 999 do writeln (vect[i]); readln;…
-
2
votes2
answers3791
viewsWrite current Directory to a text file
In a batch program I have: echo Date >c:\users\...\testecmd.txt Write the current date in a text file. Assuming I don’t know where is the directory in which the auto executable is, how do I get…
-
2
votes1
answer1038
viewsHow to remove duplicate lines from txt using php?
Well I’m creating a div which is updated every x seconds and I am displaying the users currently logged in, but my code is inserting every update the same record. Is there any way to delete repeated…
-
2
votes2
answers29234
viewsCreate . txt file in PYTHON if it does not exist
The code: arquivo = open(input('Nome do arquivo a ser editado:'), 'r') texto = arquivo.readlines() texto.append(input('Insira o texto:')) arquivo = open(input('Nome do arquivo a ser editado:'), 'w')…
-
2
votes2
answers2019
viewsWrite to txt file with PHP
I have a file txt but is missing the nome in several lines of the file, I would like to put the name according to the order number. The logic would be to check the order number of the line that is…
-
2
votes2
answers1105
viewsExcessive line breaking while creating file . txt C#?
I’m trying to generate a file .txt from a code list recovered from the database. However, when the file is generated, line breaks come out in excessive number, as shown below: The code is as below,…
-
2
votes2
answers590
viewsSaving result in txt file
Guys how would I save the output from the program to txt file ? in the example I call cmd and ask you to accomplish something, wanted to save the result in a text file. import…
-
2
votes1
answer85
viewsRead from a pre line defined in txt
I am making a txt file to save some information of a root user (user,password,name,Cpf,email) in order, and I would like to know how to read only the line that I would like, Cpf or email or user.…
-
2
votes1
answer63
viewsError trying to save txt
Everybody, good morning, everybody, I have this code pad: $delimitador = ';'; $cerca = '"'; $VarDataAux = ''; // Abrir arquivo para leitura $f = fopen($_FILES['arquivo']['tmp_name'], 'r'); if ($f) {…
-
2
votes1
answer1898
viewsRead txt file
I am creating a web application and need to read a txt file that will be provided by the user. The code I’m using to perform the reading is not working and I can’t find anywhere else a way to do the…
-
2
votes1
answer669
viewsSave to txt file and recover in a combobox
This is what I need to do: Registering a customer on the form. Save the nome of clients that are registered in a txt file on the computer, example: John Marcos Willian Load these names into a…
-
2
votes1
answer204
viewsWhat function allows you to open . txt file and run other functions in the contents of this . txt?
Which C language function allows you to open file .txt and run other functions in the contents of this .txt?
-
2
votes1
answer611
viewsRead large (80gb) php file
I need to read an 80 giga file using PHP to include in a postgres database. The file is a txt with a column layout. THE IDEA WOULD BE NOT TO DIVIDE IT, BECAUSE THE PROCESS WOULD BE UNVIABLE, SO I…
-
2
votes1
answer1371
viewsExtract Data between Lines from txt to VBA spreadsheet
I am creating a code that will automate reports at work from a button. The measuring equipment gives me a file in . mmf or . txt, and there’s an important part that I’m cracking my head to solve and…
-
2
votes1
answer684
viewsWhat is the best way to record a user log?
I have a small monitoring system that aims to show if the data of some servers are equal to backups. As the system interacts directly with the database, the need arose to know who accessed and when…
-
2
votes2
answers108
viewsWhy don’t files show your bits?
For example, I open a file .exe with the notepad and see instead of 100101 I see a lot of strange characters why this? What characters are those? A file .txt is also binary? How can I see the bits…
-
2
votes1
answer1446
views -
2
votes1
answer298
viewsDetermine sequence of numbers with Bubble Sort from a python txt file?
I have a txt input file with data type the below: 7 6 8 4 8 5 0 1 2 1 0 3 2 3 0 This file is about information for 3 students of a school. The first line is the age of these 3 students (the first…
-
2
votes2
answers66
viewsread txt file with less than 5 elements using read.table
I am trying to read the txt file with two columns below: +-----------------------------------------------------------------------------+ | Category Information | square| | #|description | miles|…
-
2
votes2
answers75
viewsGet specific value in a txt file
I am trying to get two specific values on each line of a txt file. As an example: 15/06/2016 R$ 638,69 R$ 2.562,46 15/07/2016 R$ 672,43 R$ 2.533,51 15/08/2016 R$ 658,93 R$ 2.504,75 15/09/2016 R$…
-
2
votes1
answer107
viewsHow to load . txt files from a directory including in the list or dataframe the name of this file in Python?
I’m at Jupyter Notebook working with Python. I have a directory with files in txt, I can iterate in the directory and load these files in txt, however, I also need to take the name of this file as…
-
1
votes2
answers229
viewsAdd to Text File Using pascal
I did this algorithm on Pascal that feeds numerical information into a text file. program Pascal; var i:integer; Vect:array[1..1001] of integer; Myfile: text; begin i:=1; for i:=1 to 999 do…
-
1
votes2
answers673
viewsPHP: Txt for Array relating lines.
next, I have a text file (.txt) with the following structure: |100|Nome do Cliente| |200|Produto 1|R$100| |200|Produto 2|R$200| |200|Produto 3|R$300| In short, whenever the line starts with |100|,…
-
1
votes1
answer3356
viewsEdit txt file by bat
I have the following problem: In a Windows directory, I have 3 files .txt that every day is created automatically. Within them there are several lines with information. I wish to erase two lines…
-
1
votes2
answers1221
viewsHow to format a txt file by inserting columns and changing date and time format with php script
I have text file generated from an access control device, when I download the file it comes without columns of identification, what do I need to do? Insert columns and reset the date format so that…
-
1
votes1
answer974
viewsFormat data and save to txt with php
The goal is to extract data from the base and save in txt file... The script works correctly when I enter only $log (name) on the line if (!fwrite($savelog, $log)) in an attempt to add $log2…
-
1
votes0
answers351
viewsCreate and save text file(.txt) with Vb.net?
Layout Utilizado Nomenclature: XXXXXX_DDMMYYY_ZZZZZZ.TXT DD = DAY / MM = MONTH / YYYY = YEAR: XXXXXX = It will be a 6-digit fixed code with zeros on the left. ZZZZZ = Will be a sequence of the file…
-
1
votes1
answer1751
viewsDelete last line in white txt php
I have a txt file and need to delete the last line, but it is empty. I tried the code below and it just erases the top line of the last one that would be blank. Follows code: $lines =…
-
1
votes2
answers1774
viewsRead txt and generate a new with ; at the end of each line
I created a system that imports the names generated in TXT, but the system interprets the ; at the end of each line and write to the bank, however my client’s commercial system, exports the data…
-
1
votes1
answer259
viewsConvert . log file to . txt in Bash
Hello, I wonder how I can convert a. log file generated in a container in Docker and convert it to a txt file using Bash.
-
1
votes2
answers9721
viewsHow to find specific words in a python txt file?
I need to make a software that searches for words in the code and saves in a string the next line. I couldn’t find anything on how to do it anywhere, I just found one that counts the number of words…
-
1
votes1
answer127
viewsStore amount of values in a PHP txt
I have the information below in a file txt. 500038;204932;61312;FTE GAV EDIT LACAVA TOTAL LARGXALTX15 GAV. NORMAL;LACA BLU FOSCO#996#335;5;78101922;xxxxxxx;0204932005 500038;204932;61312;FTE GAV…
-
1
votes1
answer3365
viewsWrite linux bash exits to a file
I need to do some tests on the linux command line, but doing all the tests is very time consuming, someone can help me, if you have, to write code in shell script to run all the tests, and record…
-
1
votes1
answer386
viewsReplace is not working C#
I’m replacing one code with another in each row that the code is found on. But replace simply doesn’t work, goes through it and the line continues the same way. As you can see in the image below, if…
-
1
votes2
answers180
viewsHow to load a number list into a TXT file for a C#list?
I have the following list of numbers loaded from a table, and is separated by the character "|": 40 |16000|20|311258|3 40 |17000|20|857392|5 50 |18000|90|528777|1 60 |19000|20|917336|3 60…
-
1
votes1
answer172
viewsTxt Manipulation - Separating blocks based on a pattern
I have a txt with some information. txt follows the following pattern: 1 - Beginning of the block 2 - Information 3 - Description of line 2 So for example 190845 3890580235203895 0329045832854880328…