View Single Post
  #1 (permalink)  
Old 05-14-2007, 08:42 PM
Peter's Avatar
Peter Peter is offline
Junior Member
 
Join Date: May 2007
Location: The Netherlands
Posts: 18
Default Error when moving treeview to a tabcontrol

I'm trying to move a treeview control to a tab page.
Basic4PPC responds with the error message : Unable to cast object of type 'Dbasic.Other.SwrapObject' to type 'System.Windows.Forms.Control'

Am I doing something wrong?

Code:
Sub App_Start

    Form1.Show
    
sip(true)
    AddLabel (form1,
"Label2"556020"Option:")
    AddTextBox (Form1,
"TextBox1",40,20,100,25,"")
    tbc.New1 (
"Form1", -5,0245280)
        tbc.AddTabPage(
"Aantallen")    
          tbc.AddTabPage(
"Hoorspel")
           tbc.AddTabPage(
"Personen")
        tbc.AddTabPage(
"Zoeken")
        tbc.AddTabPage(
"Lijsten")
        tbc.AddTabPage(
"X")
        tbc.AddTabPage(
"Z")
        tbc.AddTabPage(
"Configuratie")
        
'tbc.AddControl("label1",0,20,20)
        tbc.AddControl("label2",0,20,60)        
    Con.New1
    Reader.New1
    tv.New1(
"Form1"55, Form1.Width - 10, Form1.Height - 10)    
    Node.New1
    <font color=
"Red">tbc.AddControl("tv",1,20,20)</font>
    Cmd.New1(
"",con.Value)
    Con.Open(
"Data Source = " & AppPath & "\DNH4ppc.sl3")

End Sub
__________________
PC : P4 3gHz, 2GiB
PPC : LOOX 500 + 1 GiB SD
---------------------------------------------------
(Reminder to self: )
Reply With Quote