//### Comments ###############################################################################
        #region "Comments"

        private string FormComments(int nbComments)
        {
            //display comments list and new comment form

            int           PanelID = -1;
            StringBuilder myHTML  = new StringBuilder();

            myHTML.Append("<div class=\"PanelComments\">");
            bool YesNo = _DBAllowComments.Equals(EvolCommentsMode.Logged_Users) && _UserID > 0;

            if (YesNo)
            {
                string linkLabel;
                if (nbComments > 0)
                {
                    myHTML.AppendFormat(EvoLang.ucNb, nbComments.ToString(), def_Data.entity).Append(" ");
                    linkLabel = EvoLang.ucAdd;
                }
                else
                {
                    myHTML.AppendFormat(EvoLang.ucNoComments, def_Data.entity).Append(" ");
                    linkLabel = EvoLang.ucPost;
                }
                myHTML.Append(FormCommentPost(linkLabel));
                //'list of comments
                if (!noCommentsHere && nbComments > 0 && ds2 != null)
                {
                    PanelID = ds2.Tables.Count - 1;
                    if (PanelID > -1)
                    {
                        DataTable t = ds2.Tables[PanelID];
                        if (t.Rows.Count < nbComments)
                        {
                            nbComments = t.Rows.Count;
                        }
                        for (int i = 0; i < nbComments; i++)
                        {
                            myHTML.Append("<div class=\"evoSep\"></div>");
                            DataRow r = t.Rows[i];
                            myHTML.Append(EvoUI.HTMLPixCommentUser);
                            try
                            {
                                //myHTML.Append(EvoLang.ucFrom);
                                if (String.IsNullOrEmpty(def_Data.userpage))
                                {
                                    myHTML.Append(r["login"]);
                                }
                                else
                                {
                                    myHTML.Append("<a href=\"").Append(def_Data.userpage).Append("?ID=").Append(r["userid"]).Append("\">").Append(r["login"]).Append("</a>");
                                }
                                myHTML.Append(EvoLang.ucOn).Append(EvoTC.formatedDateTime((System.DateTime)r["creationdate"]))
                                .Append(".<div class=\"FieldComments\">")
                                .Append(EvoTC.Text2HTMLwBR(Convert.ToString(r["message"])))
                                .Append("</div>");
                            }
                            catch
                            {
                                myHTML.Append("<div class=\"evoSep\"></div><div class=\"FieldReadOnly\">")
                                .Append(EvoLang.ucMissing).Append("</div>");
                                break;
                            }
                        }
                    }
                }
            }
            myHTML.Append("</div>");
            return(myHTML.ToString());
        }