Questions tagged as 'arquivo'

2
answers

How to check if a file was selected in the input field?

I do a form validation to ensure that the file a user uploaded is the right type. But the upload is optional, so I want to ignore the validation if it did not upload anything and sent the rest of the form. How can I check if it has loaded someth...
asked by 20.11.2017 / 17:59
1
answer

Does the amount of bytes during a file read vary according to the mode chosen?

In C, if I open a file in binary mode, read it byte-by-byte and then get the file and read in text mode, the amount of bytes will be different? If so, why?     
asked by 30.05.2017 / 03:07
1
answer

How to copy a file in Python?

How to copy a fonte file to a destino file in Python?     
asked by 30.08.2016 / 19:47
1
answer

Passing data from one txt to another txt

I have a .txt file with three comma-separated names, in this case: test.txt João,Maria,José In my class I get the file and step to a array , separating by comma: String nomeArquivo="teste.txt"; String nomeArquivoGerado=...
asked by 30.10.2014 / 17:19
2
answers

How to check if the file name has 16 digits?

namespace _06_Teste { public partial class Form1 : Form { public Form1() { InitializeComponent(); } private void cmdValidar_Click(object sender, EventArgs e) { foreach (Stri...
asked by 08.01.2015 / 14:00
1
answer

A little more about File.WriteAllBytes

How to display a progress by synchronizing the following function: File.WriteAllBytes(string path, byte[] content); This method should be called according to a System.Threading.Thread Ex: Thread wnd; string wnd_file; byte[] wnd_...
asked by 29.01.2015 / 22:56
2
answers

How to add item in array through a foreach?

I'm doing a check in a directory where all the items with a specific extension are ready. I need to add the items in an array via a foreach . Here's part of the code I've tried. DirectoryInfo di = new DirectoryInfo(_caminhoEmail...
asked by 11.10.2016 / 15:35
2
answers

Problem loading file in memory

I'm trying to load several files into memory (small files), but the problem is that when I try to load another file soon then all files have the same name as the last file loaded. I'm using a struct that contains name, size of the name...
asked by 17.07.2014 / 00:39
2
answers

Substitution in a text by words from another file

That should be easy, but I can not find a solution! It is as follows: File1 - with texts: Doc Texto doc1 Isto é um teste para substituições de palavras. doc2 As casas são parecidas. File2 - Reference: Termo Termo_pai é...
asked by 29.07.2018 / 17:12
1
answer

File reading in IDE works and at the time it generates .jar does not work

I have an application that reads a text file that is in the same folder as the application. When I run the program on netbeans it reads the normal file: ButwhenIgeneratetheJARitdoesnotreadthefile: I'vecheckedifwhentheJARisgeneratedthetextfil...
asked by 14.05.2018 / 02:04