Results 1 to 4 of 4

Thread: Load obj problem

  1. #1

    Thread Starter
    Frenzied Member
    Join Date
    Sep 1999
    Location
    Phoenix, az
    Posts
    1,517
    Hi..

    I am trying to load a number of labels
    and it doesn't seem to work at all.

    why not?

    Code:
            For i = 1 To UBound(sTxt)
                Load PopupText.ltxt(i)
                With PopupText.ltxt(i)
                        .Caption = sTxt(i)
                        .Move 20, (i * 200) + 20
                        .borderstyle = 1
                        .ForeColor = &H80000017
                        .BackColor = &H80000018
                        .Visible = True
                End With
            Next i

  2. #2
    transcendental analytic kedaman's Avatar
    Join Date
    Mar 2000
    Location
    0x002F2EA8
    Posts
    7,221
    check your spelling, put an option explicit on top of your files, the code seems to be ok, maybe PopupText.ltxt isn't a control array. Do you get any errors?
    Use
    writing software in C++ is like driving rivets into steel beam with a toothpick.
    writing haskell makes your life easier:
    reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
    To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.

  3. #3

    Thread Starter
    Frenzied Member
    Join Date
    Sep 1999
    Location
    Phoenix, az
    Posts
    1,517
    kedaman,

    Hey.. I always use Option Explicit.
    And there are no errors what so ever.
    To give you more detail. The labels
    are loaded fine.. the only problem is
    you can not see the text ( I debug printed
    the string array and its fine).
    You can see the text when I set the
    backstyle to 0, but not 1.

    Whys that?

  4. #4
    transcendental analytic kedaman's Avatar
    Join Date
    Mar 2000
    Location
    0x002F2EA8
    Posts
    7,221
    Backstyle=0 means the control is transparent. The text is drawn directly on the form, and if the form and the text is the same color, you can't see it. I can't think of any other reasons, since it works for me.
    Use
    writing software in C++ is like driving rivets into steel beam with a toothpick.
    writing haskell makes your life easier:
    reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
    To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.

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