Category "file"

Reading a text file in Android Studio Kotlin and making pointers

I am fairly new to Android + Kotlin, however I am wondering if there is a faster way to read a text (.pgn) file and mark pointers to places in the file for late

res.set('Content-Type','image/jpg') is not working while serving image in node js

res.set('Content-Type', 'image/jpg') is not working while serving us files in node js. Please take a look at code what is wrong with this code. I am getting the

sed replacing first occurence of characters in each line of file only if they are first 2 characters

Is it possible using sed to replace the first occurrence of a character or substring in line of file only if it is the first 2 characters in the line? For examp

How to identify whether an item inside ZipFile is a directory

Consider a zip file that contains a directory with some files inside, e.g. contents of sample.zip are: Archive: ziptest.zip Length Date Time Name

How to gain access to a specific folder and write a file into it using Scoped Storage

My app has a feature that exports GPS data in txt format into a shared folder (now accessed with getExternalStorageDirectory), and I have to switch it to Scoped

fileinput.hook_compressed gives me strings sometimes, bytes other times

I'm trying to read lines from a number of files. Some are gzipped, and others are plain text files. In Python 2.7, I have been using the following code and it w

How to convert Web Stream to NodeJS native Stream

I am taking file input from user as <input type="file"/> It returns file object has Blob. This object has a method .stream() which returns ReadableStream

How to loop over on different files and save the output with filename in R?

I have several files with the names RTDFE, TRYFG, FTYGS, WERTS...like 100 files in txt format. For each file, I'm using the following code and writing the outpu

Alternative to requestLegacyExternalStorage and MANAGE_EXTERNAL_STORAGE for Public Folders in Android 10/API 29?

I have an Android app on the play store that publishes data to a simple .txt file and lets you share using any other app of your choice. It used to write direct

export and import gson - Failed to invoke public ) with no args

i'm learning how to convert array to json file and import that array with using gson. I have abstract class Shape; public abstract class Shape { private Type ty

Encoding issue when saving files with javascript?

i've been trying all day to setup a function that creates a file from plaintext or a stream in a razor page. i create csv plaintext in a backend and send it to

Flutter OS Error: File exists, errno = 17

MY ERROR - Unhandled Exception: FileSystemException: Cannot open file, path = '/storage/emulated/0/Download/Music/a.png' (OS Error: File exists, errno = 17)

Jupyter Notebook's File and Kernel menus disappear

I have an issue where my File and Kernel menus initially show while the notebook is loading, then disappear once the notebook is loaded. I should be seeing this

When downloading a file using ResponseEntity in Spring, byte breaks in reaction

This is a method of downloading files from Spring to ResponseEntity. When you download it, the byte breaks and comes out. If you use tag a, you can download the

Merge multiple binary files in Node.js

I want to merge sliced files into one, but I can't find a way to do so. I tried merge-files but it doesn't work for certain formats. I also tried to make my own

Script to read file and print first two and last two lines of it

I'm writing a program where the user inputs a file name and then the file and prints only the first 2 and the last 2 lines of the file. I have worked out how to

I used pyinstaller to turn my .py file to a executable file, but it doesn't work

EDIT: I'm using the "random" library and the "os" library, could they be interfering with the file's execution? Good morning, I'm creating a hangman game that r

Json file was not found in Android

I am developing a game for mobile and can't create a normal save system because when playing on the phone the error is logged: Could not find the file. I use th

Java: Find .bat files in all folders of a drive (C:\ and others) [duplicate]

Is there a Java code that will look in every folder of a given drive and search for .bat files? And return them has a ArrayList of Files? I'm

C# programm can't find my workspace with MSBuildWorkspace

Hi I am trying to analyze my CsProj using Roslyn. I'm having issues finding my solution. This is my code: using System; using System.Collections.Generic; using