AssistantComputerControl icon indicating copy to clipboard operation
AssistantComputerControl copied to clipboard

Wrong OneDrive folder

Open brij1234 opened this issue 2 years ago • 7 comments

Describe the bug I selected personal OneDrive account, but my school OneDrive folder is used.

To Reproduce Steps to reproduce the behavior:

  1. Set up a personal and a work OneDrive
  2. go through ACCsetup.

Hardware & software info

  • [Version of AssistantComputerControl] = 1.4.4

Workaround: Go into advanced settings and manually set the correct folder path.

Additional context & log files log.txt .

brij1234 avatar Oct 12 '21 23:10 brij1234

Will have to check up on this, but it's hard for me to replicate, as I don't have a school OneDrive or anything to test with... I'm gonna need some help on this one

AlbertMN avatar Dec 12 '21 00:12 AlbertMN

@AlbertMN I can help with testing or even coming up with the fix if needed. It's been like 4 years since I've touched C# though.

brij1234 avatar Dec 12 '21 00:12 brij1234

@brij1234 you're very welcome to take a look at the code base, it's been ages since I last looked at the OneDrive folder detection stuff, but should be easy to find in the project. I can assist, but it'd be epic if you'd take a look.

AlbertMN avatar Dec 12 '21 13:12 AlbertMN

Looks like the code points to the generic OneDrive environment variable... OneDrive has 3 different EV's

%OneDrive% - I think this is the first setup OneDrive account on the computer? %OneDriveConsumer% - Points to a personal OneDrive account %OneDriveCommercial% - Points to the commercial version of OneDrive (loosly based off SharePoint), for all basic purposes, the commercial version refers to school and work accounts.

pantherale0 avatar Dec 15 '21 10:12 pantherale0

Nice, didn't know there were more. I guess the software could check whether multiple exists, and in that case, show a Dropdown allowing the user to select which OneDrive to be used. Odd that %OneDrive% points to your school OneDrive though. I only have consumer OneDrive, but %OneDriveConsumer% isn't a variable I have (nor the commercial one).

Will see what I can do, but it'll be some time before I can implement it.

AlbertMN avatar Dec 16 '21 11:12 AlbertMN

Thats interesting, would have thought that you'd have the consumer EV on your machine.. I guess it only comes up if you have both personal and commercial accounts configured.

For me personally, I have both a personal (consumer) OneDrive and commercial OneDrive.. mainly because I have my own domains, but also useful for work when I want to test new stuff... I'm guessing in that case, %OneDrive% is the default account (the first one setup on the computer) then when you add a commercial account it will create the other EV's.... I think I've got some spare O365 licenses so if you need one to test with, just shout 👍

pantherale0 avatar Dec 16 '21 11:12 pantherale0

Thanks, will let you know if it'd help, thinking of just faking the variables for now.

AlbertMN avatar Dec 16 '21 11:12 AlbertMN