コード例 #1
0
        protected void m_CancelBtn_Click(object sender, System.EventArgs e)
        {
            ArticleManager mgr = new ArticleManager(configAgent);

            mgr.ResetSearch();
            ((IStateProcessor)Parent).SetEvent(StateEvents.CancelToForumView);
        }
コード例 #2
0
        protected void m_SearchTB_TextChanged(object sender, System.EventArgs e)
        {
            if (m_SearchTB.Text.Trim().Length == 0)
            {
                return;
            }

            ArticleManager mgr = new ArticleManager(configAgent);

            mgr.ResetSearch();
            configAgent.SearchText = HttpUtility.HtmlEncode(m_SearchTB.Text);
            ((IStateProcessor)Parent).SetEvent(StateEvents.SearchText);
        }
コード例 #3
0
        private void m_SearchResultsTable_ItemCommand(object source, System.Web.UI.WebControls.DataGridCommandEventArgs e)
        {
            if (e.CommandName == "ShowThread")
            {
                ArticleManager mgr = new ArticleManager(configAgent);
                mgr.ResetSearch();

                string szCmdArg   = (string)e.CommandArgument;
                string threadFile = szCmdArg.Substring(0, szCmdArg.IndexOf(":"));
                int    nId        = int.Parse(szCmdArg.Substring(szCmdArg.IndexOf(":") + 1));

                configAgent.ThreadFile    = threadFile;
                configAgent.ArticleToShow = nId;
                ((IStateProcessor)Parent).SetEvent(StateEvents.ShowThread);
            }
        }
コード例 #4
0
    protected void m_SearchTB_TextChanged(object sender, System.EventArgs e)
    {
      if (m_SearchTB.Text.Trim().Length == 0)
        return;

      ArticleManager mgr = new ArticleManager(configAgent);
      mgr.ResetSearch();
      configAgent.SearchText = HttpUtility.HtmlEncode(m_SearchTB.Text);
      ((IStateProcessor)Parent).SetEvent(StateEvents.SearchText);
    
    }
コード例 #5
0
    private void m_SearchResultsTable_ItemCommand(object source, System.Web.UI.WebControls.DataGridCommandEventArgs e)
    {
      if (e.CommandName == "ShowThread")
      {
        ArticleManager mgr = new ArticleManager(configAgent);
        mgr.ResetSearch();

        string szCmdArg     = (string)e.CommandArgument;
        string threadFile = szCmdArg.Substring(0, szCmdArg.IndexOf(":"));
        int nId             = int.Parse(szCmdArg.Substring(szCmdArg.IndexOf(":")+1));

        configAgent.ThreadFile    = threadFile;
        configAgent.ArticleToShow = nId;
        ((IStateProcessor)Parent).SetEvent(StateEvents.ShowThread);
      }
    }
コード例 #6
0
 protected void m_CancelBtn_Click(object sender, System.EventArgs e)
 {
   ArticleManager mgr = new ArticleManager(configAgent);
   mgr.ResetSearch();
   ((IStateProcessor)Parent).SetEvent(StateEvents.CancelToForumView);
 }