private string GetContactActivityPage(UserActivityView ctrlUserActivity, Contact contact, int messageCount)
        {
            var page = new Page();
            var form = new HtmlForm { EnableViewState = false };

            ctrlUserActivity = (UserActivityView)page.LoadControl(PathProvider.GetFileStaticRelativePath("SocialMedia/UserActivityView.ascx"));
            InitTwitter(ctrlUserActivity, contact);
            if (ctrlUserActivity.TwitterInformation.UserAccounts.Count == 0)
            {
                page.Controls.Add(new EmptyScreenControl
                {
                    ImgSrc = WebImageSupplier.GetAbsoluteWebPath("empty_screen_twitter.png", ProductEntryPoint.ID),
                    Header = CRMSocialMediaResource.EmptyContentTwitterAccountsHeader,
                    Describe = CRMSocialMediaResource.EmptyContentTwitterAccountsDescribe,
                    ButtonHTML = String.Format(@"<a class='link underline blue plus' href='javascript:void(0);'
                                                    onclick='ASC.CRM.SocialMedia.FindTwitterProfiles(jq(this),""{0}"", 1, 9);'>{1}</a>",
                                               contact is Company ? "company" : "people",
                                               CRMSocialMediaResource.LinkTwitterAccount)
                });

                return RenderPage(page);
            }

            ctrlUserActivity.MessageCount = messageCount;
            form.Controls.Add(ctrlUserActivity);
            page.Controls.Add(form);

            var executedPage = RenderPage(page);

            if (ctrlUserActivity.LoadedMessageCount == 0 && ctrlUserActivity.LastException == null)
            {
                page = new Page();

                //TODO
                page.Controls.Add(new EmptyScreenControl
                {

                    Header = CRMCommonResource.NoLoadedMessages,

                });
                executedPage = RenderPage(page);
            }

            return executedPage;
        }
        private void InitTwitter(UserActivityView ctrlUserActivity, Contact contact)
        {
            ctrlUserActivity.TwitterInformation = new UserActivityView.TwitterInfo();

            var twitterAccounts = Global.DaoFactory.GetContactInfoDao().GetList(contact.ID, ContactInfoType.Twitter, null, null);

            if (twitterAccounts.Count == 0)
                return;


            foreach (var twitterAccount in twitterAccounts)
                ctrlUserActivity.TwitterInformation.UserAccounts.Add(new UserActivityView.UserAccountInfo { ScreenName = twitterAccount.Data });

            ctrlUserActivity.TwitterInformation.ApiInfo = TwitterApiHelper.GetTwitterApiInfoForCurrentUser();
            ctrlUserActivity.SelectedSocialNetworks.Add(SocialNetworks.Twitter);
        }