Link Excel with Access

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi Jamie

Thanks for the reply, here I explain what I'm doing exactly.

I've a table.It has these fields SerialNo(Autonumber);Cleint
Name(Text);Remarks(Text).I'm using in Excel "Get External Data"; the data is
coming from my access file.I've given criteria as SerialNo so when my Excel
file refresh, it will pop-up for SerialNo.Then the give data will be dumped
in to Excel(Only one record).Here in my excel sheet i have given the check
boxes. What i am looking for is, when I check the check box, the system
should take the checkbox caption to my Access file's remark field and that
too in the corresposing record, for eg: if my excel file has the SerialNo
150, then text should be added in SerialNo 150 in access file. So the link
btween Access and Excel is the SerialNo

Can yu please help me.....
 
AN said:
I've a table.It has these fields SerialNo(Autonumber);Cleint
Name(Text);Remarks(Text).I'm using in Excel "Get External Data"; the data is
coming from my access file.I've given criteria as SerialNo so when my Excel
file refresh, it will pop-up for SerialNo.Then the give data will be dumped
in to Excel(Only one record).Here in my excel sheet i have given the check
boxes. What i am looking for is, when I check the check box, the system
should take the checkbox caption to my Access file's remark field and that
too in the corresposing record, for eg: if my excel file has the SerialNo
150, then text should be added in SerialNo 150 in access file. So the link
btween Access and Excel is the SerialNo

Although you can use MS Query ('Get External Data') to update a
datasource, it is easier to use ADO in VBA code, as I did in my
earlier example. You require an UPDATE e.g. something more like:

Con.Execute ("" & _
"UPDATE TableNameHere" & _
" SET remark = '" & CheckBox1.Caption & "'" & _
" WHERE SerialNo = " & Sheet1.Range("SerialNo").Value & _
";")

Jamie.

--
 
Back
Top