BTW:
if you really need to enter the data in a tab delimited format, try this pseudo code:
dim mystring as string
'get field names from dao
mystring = mystring & rs.field(1).name & vbtab & rs.field(2).name & vbcrlf
do until rs.eof
mystring = mystring & rs!field1 & vbtab & rs!field2& vbcrlf
rs.movenext
loop
ClipBoard_SetData(mystring)
To get data from clipboard try this pseudo code:
dim mystring as string
mystring = ClipBoard_GetData()
parse(mystring)
sub parse(byval mystring)
dim firstloc, secondloc, vbcrlfloc as integer
'no table exist yet
'first line of string contains headings
firstloc = 1
secondloc = instr(1, mystring, vbtab)
vbcrlfloc = instr(firstloc, mystring, vbcrlf)
do until vbcrlfloc < secondloc
fieldname[index] = mid(mystring, firstloc, secondloc - firstloc)
index = index + 1
firstloc = secondloc
secondloc = instr(1, mystring, vbtab)
loop
'todo:
create table using fieldname[index]
open table using rs
'populate table
do until secondloc = 0 'not found; end of string
rs.addnew
firstloc = secondloc
do until vbcrlfloc < secondloc
secondloc = instr(1, mystring, vbtab)
vbcrlfloc = instr(firstloc, mystring, vbcrlf)
rs.field(index) = mid(mystring, firstloc, secondloc - firstloc)
firstloc = secondloc
loop
rs.update
loop
end sub
the pseudo code is somewhat crude, but i hope you get the picture :)
hope this helps.