Priya.InfoList.JsonInfoCategoryService.DeleteInfoCategory C# (CSharp) Method

DeleteInfoCategory() private method

private DeleteInfoCategory ( long infoCategoryId ) : JsonObject
infoCategoryId long
return JsonObject
        public JsonObject DeleteInfoCategory(long infoCategoryId)
        {
            var retMessage = new JsonObject();

            string message;
            bool success = DataInfoList.DeleteLtdInfoCategory(infoCategoryId, out message);
            if (success)
            {
                retMessage.Put("message", "Successfully Deleted Info Category");
            }
            else
            {
                if (message.Trim().Length == 0) message = "Error in Deleting Info Category";
                retMessage.Put("error", message);
            }

            return retMessage;
        }
        #endregion