Results 1 to 4 of 4

Thread: my `control` type has lower case c and doesnt work!

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Jan 2000
    Location
    London
    Posts
    290
    trying to declare a subroutine... ie

    private sub blah(myvar As Control)

    but the word `Control` changes to `control` when i move off the line, and i get a type mismatch when i try to assign to it. When i replace it with Variant, it works ok (and the first V in Variant stays in upper case). I`ve checked and i dont have any vars called `control` that may confuse it...why cant i use them? Someone else here can get upper case C`s - why not me?

    Thanks in advance,
    Alex.

  2. #2
    _______ HeSaidJoe's Avatar
    Join Date
    Jun 1999
    Location
    Canada
    Posts
    3,946

    >?>

    not a problem here..sure you don't have something in
    public or other declares
    "A myth is not the succession of individual images,
    but an integerated meaningful entity,
    reflecting a distinct aspect of the real world."

    ___ Adolf Jensen

  3. #3
    Frenzied Member
    Join Date
    Jul 1999
    Location
    Huntingdon Valley, PA 19006
    Posts
    1,151

    Public declare some where

    I was able to create your problem by declaring a Public variable "control" ("Public control As Double")in a code module, while the declare for "blah" was in another code module for a form.

    Try "Dim control As Long" in in each of your code modules. See if you get an error message about multiple declares.
    Live long & prosper.

    The Dinosaur from prehistoric era prior to computers.

    Eschew obfuscation!
    If a billion people believe a foolish idea, it is still a foolish idea!
    VB.net 2010 Express
    64Bit & 32Bit Windows 7 & Windows XP. I run 4 operating systems on a single PC.

  4. #4
    Guest
    An easier approach. Go to Edit > Find and do a project-wide search for Control. If you find a declaration of it, remove it.

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