Reading a file help please

BlitzPlus Forums/BlitzPlus Programming/Reading a file help please

Do you mean like this:

Function LoadApplicableData()
	Local Dir = ReadDir("Blitz")
	Local File$
	Repeat
	File$ = "Blitz"+NextFile$(Dir)
	If FileType(File$)=1 Then
		N.Node = New Node
		N\Txt$ = File$
		N\Dat = AddTreeViewNode(ProgNode,N\Txt$)
	EndIf
	Until File$=""
End Function


I have already established that it is finding the files and reading from them, I just can't get the node to actually appear in the tree view. I think it might be a Global vs. Local problem or something, but the whole tree view root and it's sub-roots are global.

Any thoughts?