Results 1 to 5 of 5

Thread: [RESOLVED] [2008] Checking byte arrays

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Jun 2007
    Posts
    66

    Resolved [RESOLVED] [2008] Checking byte arrays

    I was just wondering what the best way to check if a byte array has anything in it. If it hasn't been used yet then I get the message that it's not set to a instance so I was thinking of using 'try' but that seems really bad. Is there a better way?

    Thanks

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: [2008] Checking byte arrays

    How are you creating the array in the first place?

    (And error trapping is never bad. )

  3. #3

    Thread Starter
    Lively Member
    Join Date
    Jun 2007
    Posts
    66

    Re: [2008] Checking byte arrays

    Sorry I was just explaining myself and figured it out. Sorry for wasting your time. Thanks though!

  4. #4
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: [RESOLVED] [2008] Checking byte arrays

    Don't go away without posting your solution.

    It could help someone else with the same or similiar situation.

    Thanks.

  5. #5

    Thread Starter
    Lively Member
    Join Date
    Jun 2007
    Posts
    66

    Re: [RESOLVED] [2008] Checking byte arrays

    Ok my code looked something this this (This was of course simplified):

    Code:
    dim a() as byte
    
    doFuctionPassA ( byref a ) ' pseudo code here showing the varible getting passed
    
    'since I'm not sure it was assigned anything yet I needed to check.
    'the way I figured out was this
    
    if a is nothing then
    
      'is nothing true
    
    else
    
      'is nothing false
    
    end if

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width