GetTempPath

[DllImport("Kernel32.dll", SetLastError = true)][return: MarshalAs(UnmanagedType.U4)]
public static extern uint GetTempPath(
   uint nBufferLength,
   StringBuilder lpBuffer
);

Microsoft documentation: Link

Last updated