Here are the examples of the csharp api System.Text.StringBuilder.AppendIntTwo(int) taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.
1 Examples
19
Source : StringBuilderExtension.cs
with MIT License
from trampster
with MIT License
from trampster
public static string GetOffset()
{
int tickCount = Environment.TickCount;
if(_offsetCacheTime + 1000 < tickCount)
{
_offsetCacheTime = tickCount;
var offset = TimeZoneInfo.Local.GetUtcOffset(DateTime.UtcNow);
var builder = new StringBuilder();
if(offset.TotalMinutes > 0) builder.Append('+');
else builder.Append('-');
builder.AppendIntTwo(Math.Abs(offset.Hours));
builder.Append(':');
builder.AppendIntTwo(offset.Minutes);
_offset = builder.ToString();
}
return _offset;
}