Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8523769
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T07:30:14+00:00 2026-06-11T07:30:14+00:00

I try to get DomainCollectionView, but Total Count doesn’t include in query: public DomainCollectionView<sys_log>

  • 0

I try to get DomainCollectionView, but Total Count doesn’t include in query:

    public DomainCollectionView<sys_log> collView
    {
        get { return (DomainCollectionView<sys_log>)this.GetValue(collViewProperty); }
        set
        {
            this.SetValue(collViewProperty, value);
        }
    }

    public static DependencyProperty collViewProperty = DependencyProperty.Register(
      "collView", typeof(DomainCollectionView<sys_log>), typeof(Journal), new PropertyMetadata(null));

    this._source = this.maindatacontext.sys_logs;
    this._loader = new DomainCollectionViewLoader<sys_log>(this.LoadEntities, this.mdcloaded);
    this._view = new DomainCollectionView<sys_log>(this._loader, this._source);

    private LoadOperation<sys_log> LoadEntities()
    {
        EntityQuery<sys_log> temp = mdc.GetSys_logQuery().OrderBy(order => order.Id).Where(c => c.date > DateFrom.SelectedDate.Value && c.date < DateTo.SelectedDate.Value.AddDays(1).AddTicks(-1)).SortAndPageBy(this._view);
        temp.IncludeTotalCount = true;
        return mdc.Load(temp);
    }


    void mdcloaded(LoadOperation<Web.sys_log> t)
    {
            this.collView = _view;
            //but this _view.TotalItemCount = -1
            dataGrid1.UpdateLayout();
    }

dataGrid1 has ItemSource = collView.
How I can set TotalItemCount or include it in query?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T07:30:16+00:00Added an answer on June 11, 2026 at 7:30 am

    You need to override the Count method of your DomainService to get the total count of entities of the query.

    public class MyDomainService : DomainService{
       protected override int Count<T>(IQueryable<T> query) {
            return query.Count();
       }   
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i try to get my FragmentPagerAdapter working, but the examples are a bit to
I try to get this following url using the downloadURL function as follows: http://www.ncbi.nlm.nih.gov/nuccore/27884304
i try get curent coordinate and addres with NETWORK_PROVIDER in trhead, but when i
I try get a my attribute inside Fancybox, and I get when I use
I try to get the whole content between an opening xml tag and it's
I try to get the main window handle using following code in Lazarus (Free
I try to get some website attribute (colour of the cell) and compare in
I try to get to a page straight from Bash at http://www.ocwconsortium.org/ . The
I try to get all WPF window controls collections. In other words i try
I try to get the name of executable name of all of my launched

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.