Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
Blake Niemyjski
@niemyjski
:)]
dang
feel honored :D
Eric J. Smith
@ejsmith
so what is the status of the issues that you ran into with them though?
did they just release anyway?
Blake Niemyjski
@niemyjski
yeah
they have elasticcon with them next week
Eric J. Smith
@ejsmith
LOL
Blake Niemyjski
@niemyjski
they are going to meet up with me and continue when they get some time
they said the core functionality is working and they had to get it out
@inlineAsm found an issue with our clients: exceptionless/Exceptionless#190
        Target.Geo = latitude + "," + longitude;
looks like we have to do a to lower invariant
because it’s formatting them for eu strings
which blows up elastic search
        Target.Geo = latitude.ToString("G", CultureInfo.InvariantCulture) + "," + longitude.ToString("G", CultureInfo.InvariantCulture);
Eric J. Smith
@ejsmith
well we don’t want any formatting on the numbet
we just want the number
Blake Niemyjski
@niemyjski
for lat and long you want the full thing
Eric J. Smith
@ejsmith
so we need to specifiy the formatting
Blake Niemyjski
@niemyjski
because you have minutes and seconds
invariant will give us what we want right
The invariant culture is culture-insensitive; it is associated with the English language but not with any country/region. You specify the invariant culture by name by using an empty string ("") in the call to a CultureInfo instantiation method. CultureInfo.InvariantCulture also retrieves an instance of the invariant culture.
Eric J. Smith
@ejsmith
need to look and see what format we are wanting.
I think it’s just 22.3333,33.3545
Blake Niemyjski
@niemyjski
yeah
I think invariant culture is what we want
Eric J. Smith
@ejsmith
no, we want to control the formatting ourselves.
Blake Niemyjski
@niemyjski
Target.Geo = latitude.ToString("G", CultureInfo.InvariantCulture) + "," + longitude.ToString("G", CultureInfo.InvariantCulture);
return this;
Eric J. Smith
@ejsmith
culture is only used for controlling commas and other friendly formats
Blake Niemyjski
@niemyjski
yes..
and we are saying convert this decimal to english based culture
with the periods
"The invariant culture is culture-insensitive; it is associated with the English language but not with any country/region"
// Use standard numeric format specifiers.
specifier = "G";
Console.WriteLine(value.ToString(specifier, CultureInfo.InvariantCulture));
// Displays: 16325.62
Eric J. Smith
@ejsmith
b.ToString("#0.0000"
Eric J. Smith
@ejsmith
probably something like that.
not sure how many decimals.
Blake Niemyjski
@niemyjski
90.090.ToString("G", System.Globalization.CultureInfo.InvariantCulture)
"90.09"
think that’s what we want
Eric J. Smith
@ejsmith
Why would we want that? We don’t wany any culture involved and we don’t want any friendly formatting.
we know exactly what format we want.
so you specify it.
Blake Niemyjski
@niemyjski
G is general
and the other is generic english culture
Eric J. Smith
@ejsmith
yes, general as in format it how you would for the general culture.
we don’t want them to format it for us.
we know the format.