Python Forum
How to transfer a music file, from "uploads" directory into my project - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: Python Coding (https://python-forum.io/forum-7.html)
+--- Forum: General Coding Help (https://python-forum.io/forum-8.html)
+--- Thread: How to transfer a music file, from "uploads" directory into my project (/thread-4776.html)

Pages: 1 2


How to transfer a music file, from "uploads" directory into my project - sylas - Sep-07-2017

please give a runnable sample of your code with the full error text or a clear description of the problem. Sorry, it is not a problem of code. I feel ashamed with my trouble. With a right click on the music file, the only interesting option is "copy". I choose copy but when I go in my PyCharm project and and pasre it, it is pasted as a link. But in the link there is my name. This is not correct, since the project must work with whatever PC. On the project tree, before my copy/paste, I put the name of the file. In the option "New" I have: 1. File, 2. New scratch file, 3. Directory, 4. Python Package, 5. Python File, 6. Jupyter Notebook, 7. HTML File......I choose the option 1.  Is that correct ???


RE: How to transfer a music file, from "uploads" directory into my project - Larz60+ - Sep-07-2017

What is this post in relationship to?
is this supposed to be connected to another thread?


RE: How to transfer a music file, from "uploads" directory into my project - sylas - Sep-08-2017

I try to build on my PyCharm the pryoject "pong". I have already this game on my terminaL It works well. My goal now is to copy the whole project on my PyCharm. But, as I tell you above I have trouble when I copy a music file which I loaded on my directory "uploads" since all uploads fall there.


RE: How to transfer a music file, from "uploads" directory into my project - Larz60+ - Sep-08-2017

please post some code.
I still am confused by the use of word paste.
if you load the code verbatim into PyCharm, you should be able to run.
One caveat is that if you use arguments (as through sys.argv),
you will have to make these arguments available to the PyCharm editor.

to do this, you need to go to settings->Interpreter options->Script Parameters
you can get to settings while your script is open
One way, is click help and type 'settings'


RE: How to transfer a music file, from "uploads" directory into my project - sylas - Sep-08-2017

I am sorry because you don't reply to my question. On the choice of the type of file I choose "file". Is that correct ? When i paste the music file , it writes:/home/sylvain/Téléchargements/boing.wav.........Téléchargements means uploads. Sylvain is my name, and if I want a project good for everybody, I think having my name inside the project is good for my PC, but not for your PC. Isn't it ?


RE: How to transfer a music file, from "uploads" directory into my project - hbknjr - Sep-08-2017

(Sep-08-2017, 05:59 AM)sylas Wrote: But, as I tell you above I have trouble when I copy a music file which I loaded on my directory "uploads" since all uploads fall there.

If I understand correctly this will solve your problem.

Try this:
1- open your project in Pycharm, right-click on the project name and add a new directory name it uploads.
2- right click uploads and find the option called Show in Explorer/Show in File manager or something similar find and click it.
3- now the uploads directory will open in explorer/file-manager, past you music file in that directory and now your music file will be available inside your project to be used along with uploads folder.


RE: How to transfer a music file, from "uploads" directory into my project - Larz60+ - Sep-08-2017

Is this what you're looking for?
If you are trying to get the path to a file, right click on file ans select File_path
(If windows) then click on show in explorer and click again on file name (in sub window)


RE: How to transfer a music file, from "uploads" directory into my project - sylas - Sep-08-2017

To hbknjr: your idea seems good. But i will wait since this game (pong) comes from Git hub and runs very well, and has not any diectory like the one you tell me. How did they do ? Mystery . A big book on PyCharm exists; 200 $. May be i will buy it later.


RE: How to transfer a music file, from "uploads" directory into my project - metulburr - Sep-08-2017

$200 for an IDE book?!? I would never pay that. There are so many IDE's out there, and a lot of them are for free. Most paid ones have a free option anyways...including PyCharm.

I dont think you are communicating your problem well enough for people to understand.

You have successfully executed the program through the terminal, right? So why are you requiring PyCharm?


RE: How to transfer a music file, from "uploads" directory into my project - hbknjr - Sep-09-2017

You are unable to communicate your problem.

(Sep-08-2017, 05:09 PM)sylas Wrote: A big book on PyCharm exists; 200 $. May be i will buy it later.

An IDE book is a total waste and that too at $200 when Pycharm professional subscription costs $89 or less per year.

Here is JetBrains getting started guide. May be this will help.

a. Text
b. videos