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
-
0
votes1
answer52
viewsAdapt txt file reader
I was using a manual method to grab a txt file, where the user typed the file name and extension and pressed the button, now that replace by a code that opens a search box to choose the file on the…
-
0
votes1
answer42
viewsError adding items to a file. txt Python3
I’m trying to read a file . txt (currently empty) to check if chat_id already exists, if it already exists, it ends right there. If it doesn’t exist... Add the new chat_id in the last line, but when…
-
0
votes1
answer514
viewsListbox - Multiply values and move to another Listbox
I have 2 Listbox. When I pass a value to the other Listbox opens a screen to enter the amount I want of that product. That said, it will take the quantity * value and show in the other Listbox. Code…
-
0
votes2
answers1225
viewsHow to check if the txt file has a blank space on the last line
i have a script here that searches all the files . txt from a folder and then joins them in one file only. The problem is that some files have a " n" in the last row, causing the next line not to be…
-
0
votes1
answer915
viewsSave Json dictionary to txt
How can I save a. json dictionary of a requests in txt. I tried to do it this way but it didn’t work. import requests import json url = requests.…
-
0
votes1
answer2879
viewsRead txt file and save to PHP array
I have a txt file, where the data is separated by |. I would like to read and separate the content from within each pair of | at a position of a vector. But it does not print when I put the print_r…
-
0
votes2
answers1345
viewsSave textarea content as text file
I need to make a code that when entering what is requested in textarea and push the button submit, save the content inserted in textarea in a .txt (with line break. For example: If someone has…
-
0
votes1
answer422
viewsEdit text file in cmd
I have a test.txt file D:\Tools\fonts D:\Tools\gui D:\Tools\guitex D:\Tools\table is there any command that edits the test.txt file to be this way? command###D:\Tools\fonts command###D:\Tools\gui…
-
0
votes1
answer254
viewsI need to go through the data of several txt, take specific data and generate a csv
I’m already going through the files and accessing the data, but I need to get what’s after the following line: P.A.C.() initial P.A.C. () Sopave of the quota due 3a. installment due due due payment…
-
0
votes2
answers2097
viewsRead java txt file data and perform Java operations
I am making a vehicle rental company in java need to read from a txt the type of client(char) a date range(string) and the amount of passengers(int). I need to bring this data to be analyzed , for…
-
0
votes2
answers455
viewsRead a TXT file and put its content into a Linkedlist
I need to read a TXT file and add its contents to variables in a list. However, the file does not have the same amount of characters on all lines. In the input we have a sequence of two numbers in…
-
0
votes2
answers356
viewsSetting parameters and filtering file . TXT
I have a file with a tab | in file . txt, would like to turn it into file .xls and then work with it by filtering and replacing values in python3. And possible ?! Follow a template of the file ".…
-
0
votes1
answer678
viewsTake data from a.txt file and store it in a list
What a function would look like to take this . txt and import in the lists? This function takes the data from the lists and stores the data in txt. def guardaTxt(lstModelo, lstCor, lstNumeracao,…
-
0
votes1
answer50
viewsImport from . txt using php + mysql
Good evening, I’ve tried other ways, but I couldn’t. I need to run the code query below at once instead of inserting row by row into the database. Someone would have salvation? <?php…
-
0
votes2
answers375
viewsExport process information to a . txt - Python
Good morning! I have a problem exporting the information that my process is generating. Currently I copy everything in mine print and paste it into a txt file, but I’d like to take this manual…
-
0
votes1
answer1421
viewsLine Breaking in txt file - Python
I am with a file selects the main words cited in the code I prepared. Put it in my file .txt it loses the line breaking that would be the most important for this document. Code: f =…
-
0
votes1
answer1460
viewsImport txt files with pandas
I’m starting in the area of machine Learning, following a website that suggested the following initial model: import pandas as pd from sklearn import linear_model import matplotlib.pyplot as plt…
-
0
votes1
answer961
viewsStoring Variable in a Python TXT File
Greetings,I made that algorithm CODE BELOW: from bs4 import BeautifulSoup soup=BeautifulSoup(html,'html.parser') for link in soup.select('div.sg-actions-list__hole > a[href*="/tarefa"]'):…
-
0
votes0
answers8
viewsuse Dapper with txt file and not database
greetings as I can use the Dapper with a text file and not a table or database, need to manipulate and change several lines of this text. I have a form where I open a txt on a datagrid with multiple…
-
0
votes0
answers249
viewsHow to change a specific text from a txt file?
In my notepad has 2620 lines which is the maximum. >PRODUTO [1] 1. Exemplo de texto 1 2. Exemplo de texto 2 >PRODUTO [2] 1. Exemplo de texto 1 2. Exemplo de texto 22 >PRODUTO [3] 1. Exemplo…
-
0
votes1
answer362
viewsDoubt with handling of Treeview and delimited TXT files
I’m having a little difficulty with Delphi, I’m creating a very basic small application for me to manage accounts, games, emails etc. and I decided to use the Treeview scheme as a base for listing…
-
0
votes1
answer596
viewsHow do I turn my results into txt, excel or word file?
I have a code in Python that does the following: Extracts several data from different tables and performs a linear regression between them. So far so good but how do I make my results come out clean…
-
0
votes1
answer160
viewsread txt files with php
I have the following situation: I have files in txt format, which are generated by another program and I will have to read this file row by row to generate payment slips, in this file approximately…
-
0
votes1
answer810
viewsEdit text file on a specific line
I have a txt file that informs me 3 fields: error line, wrong number and number to replace. However I am not thinking of an instruction to go directly to the line I need, this file follows a layout.…
-
0
votes1
answer826
viewsStack several txt files using pandas
I wanted to make a routine that accumulates the data I extract from google Analytics every day, but my code shows an error that I can not solve: import pandas as pd import os import glob my_dir =…
-
0
votes1
answer633
viewsParse txt file and return to another file - Python
Good night! There is a file with numbers, save in txt format, each number separated by space, with a list with about 50 values in each line of the txt file (and more than 10,000 lines in the file):…
-
0
votes1
answer1050
viewsJava, write to a specific line of a file . txt
I’ve been testing several ways to write the data of a variable in a text file (.txt), but I need to know if you can write this variable in a given line, so I could organize multiple data in the same…
-
0
votes0
answers72
viewsFeed a list with txt file data
Hello, good morning, good morning!! staff need help! I have the following list created in html, it is not complete, just for you to understand. <ul class="lista">…
-
0
votes1
answer238
viewsPHP cannot process heavy files
I have a PHP system that reads a TXT file, and performs an REPLACE in the database for each line, it does this well with small files (About 100 lines), but when I do with giant files (Over 1 Million…
-
0
votes1
answer174
viewsSave as txt c#
I created a method that saves a txt in the user’s temp folder, but I would like the user to choose where to save to his machine (save as). How could I do that? Below is my code: protected void…
-
0
votes3
answers75
viewsError reading all records from a.txt file in C
Can anyone tell me why this my code just returns the first record several times, instead of returns all the records? Function in the Code void listarDados(int quantidadeContatos) { char caracteres;…
-
0
votes2
answers799
viewsRead multiple text files using System.IO and Visual C# . NET and writing to these files
My problem is this. I have several . txt files in a pc directory. These files have information on each line and have blank lines. What I would need to do is read all the files in the directory, open…
-
0
votes2
answers107
viewsgenerate Json through txt (Position) file by php
I’m having a hard time trying to generate the Json using the basis of a txt by certain positions. I could not evolve the code because I do not know how to make a explode in the position I need. Ex:…
-
0
votes0
answers92
viewsHow to resolve txt special character error
I’m using the library requests and the following code in Python to take data from Receita-WS and to JSON in a TXT. for i in lista_empresa: url = "https://www.receitaws.com.br/v1/cnpj/" + (i['cnpj'])…
-
0
votes1
answer39
viewsImport data with spaces within fields from a txt to R
Good afternoon I would like to import a file, and I will post an example to be helped It consists of names with space and number separations To help me with the solution, please copy this…
-
0
votes1
answer2411
viewsImport data from a txt to EXCEL spreadsheet via VBA
I would like help to import this file to an excel spreadsheet through VBA These data below are the ones that are in the txt file for import, to help me, just save them in the notepad…
-
0
votes1
answer1290
viewsTXT OF BANK EXTRACT (RELEASES)
You guys, good morning. I have the following problem. I have some txt-like bank statements files that I need to play on for a dataframe, until they have a sort of standard layout. I need to take…
-
0
votes2
answers73
viewsHow to break line in txt file generation for printing?
I have an order form, and I need the line broken to every new product, one item per line, but it’s not working: <input name="cpf" type="hidden" value="<?=$ec2[cpf];?>" /> <input…
-
0
votes1
answer255
viewsGenerate Python CSV from txt
I’m trying to run the code: import csv listaG = [] arquivoSaida = 'teste.csv' with open('Arquivos_avanco.txt', newline='') as csvfile: spamreader = csv.reader(csvfile, delimiter='-', quotechar='|')…
-
0
votes0
answers137
viewsWhy does my SD card corrupt in the Afghan rescue?
I have a Kingston 4GB micro SD card and a Datalogger code that deletes the successful file and creates a new one with the new values of the variables. Follow the code below: void back_var() {…
-
0
votes1
answer386
viewsOpen text file in float value list
I need to open some files I have here that are in txt format which is even less common and specific in data processing issues, these files consist of values from 0,000 up to 0,999 and also from…
-
0
votes0
answers207
viewsGenerate txt file with custom letter font
I’m creating a code that generates a txt to print to a printer matrix. However, I would like to change the font of the letters. Someone could help me, please? Follow the code below. try{ byte[]…
-
0
votes1
answer74
viewsError trying to save git repository log to txt (Python) file
Hello, I’m trying to write a code in Python to save a git log from a git repository to a file . txt in a different directory using the function subprocess.Popen(). I know the command line syntax is:…
-
0
votes2
answers163
viewsTxt generation, does not work PHP_EOL function
Good morning, everyone. I am working on a php page for generating a.txt export data file to be imported back into another system. I had programmed taking into account the server running php 7, but…
-
0
votes1
answer33
viewsPHP - Multiple upload files not saved with . txt extension
galley. I am trying to upload multiple files that accept all types of files and save with the correct extension, but in the files . txt it saved with extension . Plain, I tried to change this…
-
0
votes2
answers1307
viewsSave form data in TXT (PHP)
Hello, good afternoon, sir! I have the following code: <?php if (isset($_POST['texto'])) { $texto = $_POST['texto']; $arquivo = fopen('msg.txt', 'w'); fwrite($arquivo, $texto); fclose($arquivo);…
-
0
votes2
answers172
viewsPython Generate txt layout from a txt file
I have a txt file that I am doing treatment to generate a layout in another txt file. When I use the command print the same generates correctly, but when I put to write in another file it generates…
-
0
votes1
answer67
viewsComparing strings
Hello I have a program to check if there is a string inside a file like this: import xml.etree.ElementTree as ET #Bibliotecas…
-
0
votes1
answer41
viewsHow do I manipulate specific information from a TXT file in C++?
The file . txt contains the following lines: 1.55 66.5 1.80 90.2 1.66 65.1 1.70 70.0 1.65 58.8 1.58 53.5 1.72 68.5 1.63 67.9 1.71 69.4 1.67 62.4 I need to average the height, average the weight and…
-
0
votes1
answer63
viewsLooking for string inside another Python string
Hello I have a program to check if there is a string inside a file like this: import xml.etree.ElementTree as ET #Bibliotecas…