Hi,
Thanks for persisting with your help.
I tried creating a simple control, with just a label field and still the same error. Verified above steps as well.
msbuild /t:restore is running fine without any issues but the following msbuild command fails with same errors -

Almost sure that the problem lies with Microsoft libs either PAC or MSBUILD or may be Nuget packages.
Full log -----------------------
C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSolution>msbuild
Microsoft (R) Build Engine version 15.9.21+g9802d43bc3 for .NET Framework
Copyright (C) Microsoft Corporation. All rights reserved.
Build started 28/01/2022 10:29:56.
Project "C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSolution\SampleControlSolution.cdsproj" on node 1 (default targets).
Project "C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSolution\SampleControlSolution.cdsproj" (1) is building "C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControl1.pcfproj" (2:2) on node 1 (default target
s).
PcfBuild:
npm run build -- --noColor --buildMode development --outDir "C:\Users\JENAAU\source\PCF\Controls\SampleControl1\out\controls" --buildSource MSBuild
> pcf-project@1.0.0 build
> pcf-scripts build "--noColor" "--buildMode" "development" "--outDir" "C:\\Users\\JENAAU\\source\\PCF\\Controls\\SampleControl1\\out\\controls" "--buildSource" "MSBuild"
[10:30:04] [build] Initializing...
[10:30:04] [build] Validating manifest...
[10:30:04] [build] Validating control...
[10:30:05] [build] Generating manifest types...
[10:30:05] [build] Generating design types...
[10:30:05] [build] Compiling and bundling control...
[Webpack stats]:
asset bundle.js 4.22 KiB [emitted] (name: main)
./SampleControl1/index.ts 2.67 KiB [built] [code generated]
webpack 5.67.0 compiled successfully in 1746 ms
[10:30:08] [build] Generating build outputs...
[10:30:08] [build] Succeeded
Done Building Project "C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControl1.pcfproj" (default targets).
ResolveAssemblyReferences:
Primary reference "SampleControl1".
Could not find dependent files. Expected file "C:\Users\JENAAU\source\PCF\Controls\SampleControl1\out\controls\SampleControl1.exe" does not exist.
Could not find dependent files. Expected file "C:\Users\JENAAU\source\PCF\Controls\SampleControl1\out\controls\SampleControl1.exe" does not exist.
Resolved file path is "C:\Users\JENAAU\source\PCF\Controls\SampleControl1\out\controls\SampleControl1.exe".
Reference found at search path location "".
The ImageRuntimeVersion for this reference is "".
CopyCdsSolutionContent:
Copying file from "C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSolution\src\Other\Customizations.xml" to "obj\Debug\Metadata/Other\Customizations.xml".
Copying file from "C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSolution\src\Other\Solution.xml" to "obj\Debug\Metadata/Other\Solution.xml".
Copying file from "C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSolution\src\Other\Relationships.xml" to "obj\Debug\Metadata/Other\Relationships.xml".
ProcessCdsProjectReferencesOutputs:
Processing output of component type: Pcf, source output directory: C:\Users\JENAAU\source\PCF\Controls\SampleControl1\out\controls\, destination directory: C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSolution\obj\D
ebug\Metadata\Controls
Process: Output copied from source directory: C:\Users\JENAAU\source\PCF\Controls\SampleControl1\out\controls\SampleControl1 to destination directory: C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSolution\obj\Debug\
Metadata\Controls\aj_AJSample.SampleControl1
Process: Control data node created in C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSolution\obj\Debug\Metadata\Controls\aj_AJSample.SampleControl1
Process: Root Component of type: 66, schema name: aj_AJSample.SampleControl1 added to Solution
PowerAppsPackage:
Running Solution Packager to build package type: Unmanaged bin\Debug\SampleControlSolution.zip
Packing C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSolution\obj\Debug\Metadata to bin\Debug\SampleControlSolution.zip
C:\Users\JENAAU\.nuget\packages\microsoft.powerapps.msbuild.solution\1.11.4\build\Microsoft.PowerApps.MSBuild.Solution.targets(134,5): error : Value cannot be null. [C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSoluti
on\SampleControlSolution.cdsproj]
C:\Users\JENAAU\.nuget\packages\microsoft.powerapps.msbuild.solution\1.11.4\build\Microsoft.PowerApps.MSBuild.Solution.targets(134,5): error : Parameter name: type [C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSolutio
n\SampleControlSolution.cdsproj]
Done Building Project "C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSolution\SampleControlSolution.cdsproj" (default targets) -- FAILED.
Build FAILED.
"C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSolution\SampleControlSolution.cdsproj" (default target) (1) ->
(PowerAppsPackage target) ->
C:\Users\JENAAU\.nuget\packages\microsoft.powerapps.msbuild.solution\1.11.4\build\Microsoft.PowerApps.MSBuild.Solution.targets(134,5): error : Value cannot be null. [C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSolu
tion\SampleControlSolution.cdsproj]
C:\Users\JENAAU\.nuget\packages\microsoft.powerapps.msbuild.solution\1.11.4\build\Microsoft.PowerApps.MSBuild.Solution.targets(134,5): error : Parameter name: type [C:\Users\JENAAU\source\PCF\Controls\SampleControl1\SampleControlSolutio
n\SampleControlSolution.cdsproj]
0 Warning(s)
1 Error(s)
Time Elapsed 00:00:12.96
Regards
Aura