Cloudberry Backup API: Listing Plan Items

315 views Asked by At

I'm trying to list selected folder paths in all backup plans using the Cloud.Backup.API.dll and am not having much luck. I've given up trying to load the dll in powershell (using Add-Type returns 'Unable to load one or more of the requested types') and am instead writing a simple console application in C#. So far I have:

foreach (BackupPlan plan in BackupProvider.GetBackupPlans())
    {
        Console.WriteLine(plan.PlanItems);
    }

However, PlanItems returns:

CloudBerryLab.Backup.API.BackupPlan+d__0

What exactly am I doing wrong?

1

There are 1 answers

0
Anton Zorin On BEST ANSWER

For C# this will list paths:

foreach (string _item in plan.PlanItems)
               {
                   Console.WriteLine(_item);    
               }