- Megjött a Chieftec VEGA M szériás tápok legnagyobb teljesítményű kiadása
- 280 Hz-es, remekül felszerelt WOLED monitor jött a Gigabyte gondozásában
- Itt az AI videók TikTokja, az OpenAI új agymenése
- Rekordösszegért kerül szaúdi kézbe az Electronic Arts
- Nem saját tervezésű a Zhaoxin új szerverprocesszora
- Milyen notebookot vegyek?
- Xiaomi Mi Box androidos médialejátszó 4K és HDR támogatással
- 3D nyomtatás
- Hogy is néznek ki a gépeink?
- AMD Ryzen 9 / 7 / 5 10***(X) "Zen 6" (AM5)
- Projektor topic
- AMD Navi Radeon™ RX 9xxx sorozat
- AMD vs. INTEL vs. NVIDIA
- Harcmezőre termett az új GeForce driver
- AMD Ryzen 9 / 7 / 5 7***(X) "Zen 4" (AM5)
Új hozzászólás Aktív témák
-
RedHarlow
aktív tag
Sziasztok!
WinSCP-n keresztüli fájlátvitelt csinált már valaki Visual Studio / C# segítségével? Sehogy se sikerül használni a hivatalos oldalon megadott kódot. Az alábbi hibákat kapom:
The type or namespace WinSCP could not be found.
The type or namespace Protocol could not be found.
The type or namespace SessionOptions could not be found.
The type or namespace TransferOptions could not be found.KÓD
using System;
using WinSCP;
class Example
{
public static int Main()
{
try
{
// Setup session options
SessionOptions sessionOptions = new SessionOptions
{
Protocol = Protocol.Sftp,
HostName = "example.com",
UserName = "user",
Password = "mypassword",
SshHostKeyFingerprint = "ssh-rsa 2048 xx:xx:xx:xx:xx:xx:xx:xx:..."
};
using (Session session = new Session())
{
// Connect
session.Open(sessionOptions);
// Upload files
TransferOptions transferOptions = new TransferOptions();
transferOptions.TransferMode = TransferMode.Binary;
TransferOperationResult transferResult;
transferResult =
session.PutFiles(@"d:\toupload\*", "/home/user/", false, transferOptions);
// Throw on any error
transferResult.Check();
// Print results
foreach (TransferEventArgs transfer in transferResult.Transfers)
{
Console.WriteLine("Upload of {0} succeeded", transfer.FileName);
}
}
return 0;
}
catch (Exception e)
{
Console.WriteLine("Error: {0}", e);
return 1;
}
}
}
Új hozzászólás Aktív témák
● ha kódot szúrsz be, használd a PROGRAMKÓD formázási funkciót!
- GeForce RTX 2070 (OEM HP) Garanciával
- Új Dell 5330 Latitude 13.3 FHD IPS Touch i5-1235U 4.4Ghz 16GB 512GB Intel Iris XE Win11 Pro Garancia
- BESZÁMÍTÁS! 32GB (2x16) G.Skill Ripjaws V 4000MHz DDR4 memória garanciával hibátlan működéssel
- BESZÁMÍTÁS! Intel Core i7 4790K 4mag 8szál processzor garanciával hibátlan működéssel
- GYÖNYÖRŰ iPhone 13 mini 256GB Midnight -1 ÉV GARANCIA - Kártyafüggetlen, MS3403
Állásajánlatok
Cég: PCMENTOR SZERVIZ KFT.
Város: Budapest
Cég: Laptopműhely Bt.
Város: Budapest