Michael Klement

Results 1234 comments of Michael Klement

Mysterious, @237dmitry, I just tried in WSL (Ubuntu 20.4), and - as I would expect - `[cultureinfo]::CurrentCulture` / `[threading.thread]::Currentthread.CurrentCulture` are read-only there. [`[cultureinfo]`](https://learn.microsoft.com/en-US/dotnet/api/System.Globalization.CultureInfo?view=net-7.0) implements the `IConeable` interface, so you _can_...

@237dmitry, the only explanation I can think of is that something in a `$PROFILE` file of yours assigns a read-write `[cultureinfo]` instance to `[threading.thread]::Currentthread.CurrentCulture` on session startup. (Either that, or...

If you assign a culture info that was obtained via a `[cultureinfo]` _constructor_, it will be read-write. If you use `[cultureinfo]::GetCultureInfo('...')`, it will be read-only. Sounds like your `$PROFILE` assigns...

I don't know what's in your `$PROFILE`; it may be using the culture via `[cultureinfo]::CurrentCulture` instead, and perhaps there are even other ways. Please note that we're getting pretty far...

That's good to know. Given that [DateTime.ToOADate()](https://learn.microsoft.com/en-US/dotnet/api/System.DateTime.ToOADate) returns a `[double]` and that `.ToString()` stringification is culture-sensitive: Does Excel expect the decimal mark to use the current culture's? For instance, on...

Thanks, @jhoneill. I looked into this, and you're right: Excel expects culture-specific field-value representations as well as as the culture-specific list separator (e.g, `;` for `fr-FR`), which can be applied...

Glad to hear it, @sba923. As for the original proposal: I think that changing the formatting now would be a backward-compatibility concern. Generally, CSV is a purely text-based format, so...

Generally, the use case you're describing is better handled using serialization based on CLIXML rather than JSON. What makes this more cumbersome is the fact that you must export to...

@SteveL-MSFT: I merely restricted my comment to pointing out the CLIXML alternative, because I don't know what the right answer to the specific problem at hand is, but here are...

@B-Art: This issue is about _ignoring_ values that can't be converted to JSON. By contrast, you're looking to for an opt-in method for _including_ such values by converting dictionary keys...