Hi I need to place a small spread sheet on one of my forms. I decided to use OLE for this purpose. Unfortunatly the OLE thing does not seem to want to load files. I get the error message
"contents of ole stream not in correct format"
Here is the code I am using:
Dim fnum As Integer
CommonDialog1.ShowOpen
fnum = FreeFile
Open CommonDialog1.FileName For Binary As #fnum
OLE1.ReadFromFile (fnum)
Close #fnum
Or is there a better way to embed a spreadsheet on a form?
I am using vb6 SP5 on Win 2k professional.
Any ideas?
Thanks,
Alex


Reply With Quote
, but try this