link to a cell in another page in vbe..

  • Thread starter Thread starter pls123
  • Start date Start date
P

pls123

hi all !!
i need that !!
how do i write in vb editor
the link to a cell in another page..
like this:
aWS.Range("C28") = C:\sourcepage\sheet1\cell_A27

i also need no edit link prompt in case that page doesn't exist...
ty!!!
 
Range("c28").Select
ActiveCell.FormulaR1C1 = _
"='C:\path\[workbookname.xls]Sheet1'!R27C1"
 
im sorry all i explained bad...
i need to copy paste that cell's value ... to here...


and i need just visual basic..not formula...
because i can have need to cancel other workbook but i need the value to
stay..
ty







dmoney said:
Range("c28").Select
ActiveCell.FormulaR1C1 = _
"='C:\path\[workbookname.xls]Sheet1'!R27C1"


pls123 said:
hi all !!
i need that !!
how do i write in vb editor
the link to a cell in another page..
like this:
aWS.Range("C28") = C:\sourcepage\sheet1\cell_A27

i also need no edit link prompt in case that page doesn't exist...
ty!!!
 
you can open the workbook with the information you need copy the data you
need paste the values to the new location and then close the workbook

Workbooks.Open Filename:= _
"C:\path\workbookwithinfo.xls"
. Windows("workbookwithinfo.xls").Activate
Range("your range here").Select
Selection.Copy
Windows("Book1").Activate
Range("your destination range here").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone,
SkipBlanks _
:=False, Transpose:=False

pls123 said:
im sorry all i explained bad...
i need to copy paste that cell's value ... to here...


and i need just visual basic..not formula...
because i can have need to cancel other workbook but i need the value to
stay..
ty







dmoney said:
Range("c28").Select
ActiveCell.FormulaR1C1 = _
"='C:\path\[workbookname.xls]Sheet1'!R27C1"


pls123 said:
hi all !!
i need that !!
how do i write in vb editor
the link to a cell in another page..
like this:
aWS.Range("C28") = C:\sourcepage\sheet1\cell_A27

i also need no edit link prompt in case that page doesn't exist...
ty!!!
 
IM WORKING ON IT ty p !!





dmoney said:
you can open the workbook with the information you need copy the data you
need paste the values to the new location and then close the workbook

Workbooks.Open Filename:= _
"C:\path\workbookwithinfo.xls"
. Windows("workbookwithinfo.xls").Activate
Range("your range here").Select
Selection.Copy
Windows("Book1").Activate
Range("your destination range here").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone,
SkipBlanks _
:=False, Transpose:=False

pls123 said:
im sorry all i explained bad...
i need to copy paste that cell's value ... to here...


and i need just visual basic..not formula...
because i can have need to cancel other workbook but i need the value to
stay..
ty







dmoney said:
Range("c28").Select
ActiveCell.FormulaR1C1 = _
"='C:\path\[workbookname.xls]Sheet1'!R27C1"


:

hi all !!
i need that !!
how do i write in vb editor
the link to a cell in another page..
like this:
aWS.Range("C28") = C:\sourcepage\sheet1\cell_A27

i also need no edit link prompt in case that page doesn't exist...
ty!!!
 
Back
Top