Question Move file from Path to PS3

Koreax

Veteran
Messages
35
Reaction score
17
Points
793
Dear CabCon Community,
I'm currently building an advanced Console Manager aka CCAPI 2.90 which i want to improve with many new features.

I'm trying to Move a file from any folder directly to my PS3 without using FTP.

I want to use it in my button that user can put a custom path on their console to move a specific file to this direction.

My code so far that i tried but failed:

string sprx = Path.Combine(Directory.GetCurrentDirectory(), "Settings.sprx");
File.Create(sprx);
string url = "
You do not have permission to view link Log in or register now.
";
File.Copy(sprx, url);
 

ANDYMODZYT

Veteran
Messages
81
Reaction score
26
Points
803
I made something like this not too long ago heres how i do it
Code:
        public void UploadFileToFtp(string url, string filePath, string username, string password)
        {
            var fileName = Path.GetFileName(filePath);
            var request = (FtpWebRequest)WebRequest.Create(url + fileName);

            request.Method = WebRequestMethods.Ftp.UploadFile;
            request.Credentials = new NetworkCredential(username, password);
            request.UsePassive = true;
            request.UseBinary = true;
            request.KeepAlive = false;

            using (var fileStream = File.OpenRead(filePath))
            {
                using (var requestStream = request.GetRequestStream())
                {
                    fileStream.CopyTo(requestStream);
                    requestStream.Close();
                }
            }

            var response = (FtpWebResponse)request.GetResponse();
           MessageBox.Show("File uploaded. Check the tmp folder.");
            response.Close();
        }
UploadFileToFtp("ftp://" + "IP Here" + "/dev_hdd0/tmp/", "Path Here", "", "");
 
Top