/// <summary>
/// Process multiline message
/// </summary>
/// <param name="heading"></param>
/// <param name="messages"></param>
/// <returns></returns>
public static string ProcessMessageList(string heading, List<string> messages)
{
StringBuilder messageText;
messageText = new StringBuilder();
messageText.Append(heading);
messageText.Append(messages.Count > 0 ? ERPUtilityResources.MsgStart : string.Empty);
foreach (string message in messages)
{
messageText.Append(string.Format(ERPUtilityResources.MsgFormat, message));
}
messageText.Append(messages.Count > 0 ? ERPUtilityResources.MsgEnd : string.Empty);
return messageText.ToString();
}
/// Process multiline message
/// </summary>
/// <param name="heading"></param>
/// <param name="messages"></param>
/// <returns></returns>
public static string ProcessMessageList(string heading, List<string> messages)
{
StringBuilder messageText;
messageText = new StringBuilder();
messageText.Append(heading);
messageText.Append(messages.Count > 0 ? ERPUtilityResources.MsgStart : string.Empty);
foreach (string message in messages)
{
messageText.Append(string.Format(ERPUtilityResources.MsgFormat, message));
}
messageText.Append(messages.Count > 0 ? ERPUtilityResources.MsgEnd : string.Empty);
return messageText.ToString();
}
No comments:
Post a Comment