[Android] Invalid file path

Stesvis 1,041 Reputation points
2021-11-05T00:05:27.087+00:00

I can't build my XF solution anymore, due to a build error such as:

Error invalid file path 'R:\Levitica\AWDServiceMobile\AWDServiceMobile\AWDServiceMobile.Android\obj\Debug\110\res\logo.png'. AWDService.Android

I tried to clean the entire solution, manually delete all the obj and bin folders, restart VS 2019, rebuild....no luck. I always get the same error, but if I open that path in file explorer, the log file is there:
146677-image.png

Last time I built the solution was when I made a package for the store, no changes after that except VS 2019 updates.

Is there a way to solve this and keep working?

Xamarin
Xamarin
A Microsoft open-source app platform for building Android and iOS apps with .NET and C#.
5,296 questions
0 comments No comments
{count} votes

Accepted answer
  1. Leon Lu (Shanghai Wicresoft Co,.Ltd.) 68,661 Reputation points Microsoft Vendor
    2021-11-05T01:52:04.85+00:00

    Hello,​

    Welcome to our Microsoft Q&A platform!

    Error invalid file path 'R:\Levitica\AWDServiceMobile\AWDServiceMobile\AWDServiceMobile.Android\obj\Debug\110\res\logo.png'. AWDService.Android

    Please move your logo.png file to the Drawable folder or mipmap- folders(if you want to make your logo.png as application icon), do not put it in the Resource folder directly.

    I notice your png's name is logo.png, if you want to change a new icon for your application. Here is thread about changing the icon for xamarin application.

    If you want to know more details about there folders in the Drawable path, you can refer to default-resources thread.

    Best Regards,

    Leon Lu


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

0 additional answers

Sort by: Most helpful