Linking cells in excel file -
i want link 2 cell in excel sheet. can edit cell values both side.
for example:
i have 2 sheets in excel. sheet01 sheet02
a1 cell of sheet01 connected a1 cell of sheet02.
i can edit sheet01 cell , display value in sheet02 sheet02 cell have =sheet01!a1
now want way edit sheet02 a1 cell that's display data in a1 cell of sheet01.
simply, both side communication 2 linked cell in excel.
use code "sheet1" object :
private sub worksheet_change(byval target range) if not intersect(target, range("a1")) nothing thisworkbook.sheets("sheet2").range("a1").value = target.value end if end sub
you can copy code "sheet2" object. have change sheets("sheet2") part sheets("sheet1").
Comments
Post a Comment