Click here to Skip to main content
15,904,817 members
Home / Discussions / C#
   

C#

 
QuestionCan version 2015 of Visual Studio still be installed Pin
Brian_TheLion15-May-19 19:48
Brian_TheLion15-May-19 19:48 
AnswerRe: Can version 2015 of Visual Studio still be installed Pin
OriginalGriff15-May-19 20:07
mveOriginalGriff15-May-19 20:07 
GeneralRe: Can version 2015 of Visual Studio still be installed Pin
Richard MacCutchan15-May-19 21:22
mveRichard MacCutchan15-May-19 21:22 
GeneralRe: Can version 2015 of Visual Studio still be installed Pin
OriginalGriff15-May-19 21:39
mveOriginalGriff15-May-19 21:39 
GeneralRe: Can version 2015 of Visual Studio still be installed Pin
Gerry Schmitz16-May-19 3:36
mveGerry Schmitz16-May-19 3:36 
QuestionSelecting the correct code Pin
Brian_TheLion15-May-19 15:25
Brian_TheLion15-May-19 15:25 
AnswerRe: Selecting the correct code Pin
BillWoodruff15-May-19 16:40
professionalBillWoodruff15-May-19 16:40 
GeneralRe: Selecting the correct code Pin
Brian_TheLion15-May-19 17:48
Brian_TheLion15-May-19 17:48 
GeneralRe: Selecting the correct code Pin
BillWoodruff15-May-19 18:00
professionalBillWoodruff15-May-19 18:00 
GeneralRe: Selecting the correct code Pin
Brian_TheLion15-May-19 18:38
Brian_TheLion15-May-19 18:38 
GeneralRe: Selecting the correct code Pin
BillWoodruff15-May-19 22:14
professionalBillWoodruff15-May-19 22:14 
GeneralRe: Selecting the correct code Pin
Brian_TheLion15-May-19 18:46
Brian_TheLion15-May-19 18:46 
AnswerRe: Selecting the correct code Pin
Richard MacCutchan15-May-19 21:26
mveRichard MacCutchan15-May-19 21:26 
QuestionFormatting code to post on this discussion group Pin
Brian_TheLion15-May-19 15:01
Brian_TheLion15-May-19 15:01 
AnswerRe: Formatting code to post on this discussion group Pin
Dave Kreskowiak15-May-19 15:11
mveDave Kreskowiak15-May-19 15:11 
GeneralRe: Formatting code to post on this discussion group Pin
Brian_TheLion15-May-19 15:14
Brian_TheLion15-May-19 15:14 
QuestionHow to change screen resolution in secondary display? Pin
jrdnoland14-May-19 0:29
jrdnoland14-May-19 0:29 
SuggestionRe: How to change screen resolution in secondary display? Pin
CHill6014-May-19 1:11
mveCHill6014-May-19 1:11 
QuestionMessage Removed Pin
13-May-19 20:45
Alexduu13-May-19 20:45 
AnswerMessage Removed Pin
13-May-19 21:02
professionalMycroft Holmes13-May-19 21:02 
GeneralMessage Removed Pin
13-May-19 21:26
mveRichard MacCutchan13-May-19 21:26 
QuestionString Line formating in C# Pin
anilkolla13-May-19 19:32
anilkolla13-May-19 19:32 
AnswerRe: String Line formating in C# Pin
OriginalGriff13-May-19 20:40
mveOriginalGriff13-May-19 20:40 
We can't give you exact instructions because we have no idea how you are building yout strings, but if you want specifically formatted output, you have to specify that when you build the string.
There are a couple of ways to do that.
For string values, you can use PadLeft:
C#
string abc = "ABC";
string abcdefgh = "ABCDEFGH";
Console.WriteLine(abc.PadLeft(8));
Console.WriteLine(abcdefgh.PadLeft(8));
Which will give you:
     ABC
ABCDEFGH
For numbers, it's more complicated: Aligning strings within string.Format and interpolated strings[^]
Sent from my Amstrad PC 1640
Never throw anything away, Griff
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!

GeneralRe: String Line formating in C# Pin
BillWoodruff13-May-19 23:32
professionalBillWoodruff13-May-19 23:32 
GeneralRe: String Line formating in C# Pin
OriginalGriff13-May-19 23:38
mveOriginalGriff13-May-19 23:38 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.