Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
是否有 VBA 代码可以根据需要更改 Excel 的区域设置?我有 ½ 的 Excel 文件使用日期格式 01/25/2020,而另一半使用 1.1.2020,使用这些文件真的很令人沮丧。我需要一种简单的方法来根据需要切换区域设置。
区域设置是从 Windows 获取的。
您唯一的选择是修改应用于相关单元格的格式。您可以创建一个宏来遍历具有日期格式的单元格和范围,并修改格式以匹配您的偏好。