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 8454001
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T11:54:45+00:00 2026-06-10T11:54:45+00:00

The block of code where I am getting this is, If userID > 0

  • 0

The block of code where I am getting this is,

 If userID > 0 Then
            Dim lq As New lqDFDataContext
            Dim var = lq.mobile_GetCustomChannels(userID).ToList()
            For Each c In var
                Dim channel As New SimpleChannel
                channel.channelID = c.channelID
                channel.userID = c.userID

                If c.matchTitle = True Then
                    channel.matchBy = "Title"
                End If

                If c.matchTitleAbstract = True Then
                    channel.matchBy = "Title and Abstract"
                End If

                If c.fromMyPage = True Then
                    channel.source = "My Page"
                Else
                    channel.source = "All Journals"
                End If

                   Dim tempKW() As String = c.keywords.Split(",")
                For Each kw As String In tempKW
                    channel.keywords.Add(kw)
                Next

                Dim imageKW As String = c.keywords.Substring(0, c.keywords.IndexOf(" "))
                channel.imageURL = SingleImageSearch(imageKW)


                result.Add(channel)
            Next
        End If

The line, “channel.keywords.Add(kw)” is where the error comes up. I’ve used this technique dozens of time without a problem, and this seems analogous to every other time I’ve used it yet I keep getting this exception. Can’t figure out why.

  • 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-10T11:54:47+00:00Added an answer on June 10, 2026 at 11:54 am

    It looks like your SimpleChannel constructor isn’t initializing the keywords collection. Make sure the constructor is actually creating an instance of keywords (ie: keywords = new List(Of String) or whatever is appropriate).

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

Sidebar

Related Questions

I have this block of code inside a loop: var points = [new google.maps.LatLng(lat1,
For this block of code: if(!skipit) { var update_argument=''; if (document.formname.fieldname) { update_argument=document.formname.fieldname[document.formname.fieldname.selectedIndex].value; }
I have a block of code in my view like this: <% @map[value].each do
I am using this block of code for getting my followers: $trends_url = http://api.twitter.com/1/statuses/followers/myname.json;
I'm getting this weird compilation error with eclipse in the following code block. I've
This block of code is getting data from a csv, putting it into JSON
i am getting this error on this code: <style> #tt { position:absolute; display:block; background:url(images/tt_left.gif)
I have a block of code in C like this- enum colors { //---->I
This is a block of code in one of my program. if i directly
I am trying to build a block where I am getting this error message

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.