i have a treeview control to display file directory that works fine when i run the just form as a project in vb.
However when i add the form to a larger project i get a Run-time error '13' Type mismatch at the line to create the root node which is:
Set pnode = treeview1.nodes.add(, , file_name, file_name)
the file_name is a variable containing the file path to the root directory.
How can i correct this error? (the task is completed when i set execution to the next statement at runtime)
I also have a problem in the treeview click event, I get a compile error: Invalid use of New keyword at
Dim node as New node
I would also appreciate a solution to this. the form runs just fine on its own.
thanks
However when i add the form to a larger project i get a Run-time error '13' Type mismatch at the line to create the root node which is:
Set pnode = treeview1.nodes.add(, , file_name, file_name)
the file_name is a variable containing the file path to the root directory.
How can i correct this error? (the task is completed when i set execution to the next statement at runtime)
I also have a problem in the treeview click event, I get a compile error: Invalid use of New keyword at
Dim node as New node
I would also appreciate a solution to this. the form runs just fine on its own.
thanks