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

  • SEARCH
  • Home
  • 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 7853339
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T19:39:18+00:00 2026-06-02T19:39:18+00:00

Hi I have a program which is goin to basically load news articles from

  • 0

Hi I have a program which is goin to basically load news articles from an IEnumerable. I have started a method which has to load only the first item in this IEnumerable. Then on a user gesture ( swipe-left or swipe-right) the previous item or next item in the IEnumerable will be loaded. Also if the user tries to load an index out of range item ( for example -1 or an item that is greater that the count of the IEnumerable) it will do nothing.

I have written many methods that iterate through an IEnumerable but i found some difficulty trying to solve this one :/

  • 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-02T19:39:19+00:00Added an answer on June 2, 2026 at 7:39 pm

    Convert the enumerable to a List first by calling ToList. You can then keep track of the current index and act accordingly.

    Edit: If you want items to “load” only when needed, you could wrap each item in a Lazy. That way, you can materialize the whole list, but only load individual items when required. This will also load an item only once even when the user flicks back and forth.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i have program which prints all char from char_min to char_max here is code
I have a program which gets a list of locations from an sql db
I have socket program which sends a file from socket client to socket server
I have a program which I have got to take numbers from a text
I have a program which has some Textareas / Labels these can be anywhere
I have a program which has to create an empty file with a specific
I have a program which only needs a NotifyIcon to work as intended. So
I have program which loads an assembly using Asssembly.LoadFrom method. Some time later I
I have program which has servers interacting with each other using Twisted's remote procedure
I have a program which I would like to run every X min the

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.