can you attach the sample workbook On Wed, Jan 26, 2011 at 8:59 PM, roberto mensa <robb....@gmail.com> wrote:
> look here > http://www.contextures.com/xlcomments03.html#Picture > > regards > r > > > > 2011/1/26 Seba <sebastjan.hri...@gmail.com> > > Hello, >> >> I recorded a macro which adds content from certain range of cells to >> another range of cells. Each cell serves as a content source for the >> target cell comment. >> >> My problem is this. The source content is added periodically and if I >> trigger the macro for the second time, when I add source content to >> another source cell, I get this error: >> 'Run-time error 1004' >> Application defined or object defined error >> >> I suppose macro should be adapted in a way, that all content is >> cleared and added again or something like that... >> >> Here is the test macro: >> >> -------------------------------------------------------------------------- >> Sub komentar() >> ' >> ' komentar Makro >> ' >> >> ' >> Range("F14").Select >> Range("F14").AddComment >> Range("F14").Comment.Visible = True >> Range("F14").Comment.Text Text:="User:" & Chr(10) & "" >> Range("F20").Select >> Selection.Copy >> Range("F14").Comment.Shape.Select True >> Application.CutCopyMode = False >> Range("F14").Comment.Text Text:="User:" & Chr(10) & "" >> Range("F20").Select >> ActiveCell.FormulaR1C1 = "asdasda" >> Range("F14").Comment.Shape.Select True >> Range("F14").Comment.Text Text:="User:" & Chr(10) & "asdasda" >> Range("G21").Select >> End Sub >> >> -------------------------------------------------------------------------------------- >> >> Could anyone please help? >> >> regards, >> >> seba >> >> -- >> >> ---------------------------------------------------------------------------------- >> Some important links for excel users: >> 1. Follow us on TWITTER for tips tricks and links : >> http://twitter.com/exceldailytip >> 2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310 >> 3. Excel tutorials at http://www.excel-macros.blogspot.com >> 4. Learn VBA Macros at http://www.quickvba.blogspot.com >> 5. Excel Tips and Tricks at http://exceldailytip.blogspot.com >> >> To post to this group, send email to excel-macros@googlegroups.com >> >> <><><><><><><><><><><><><><><><><><><><><><> >> Like our page on facebook , Just follow below link >> http://www.facebook.com/discussexcel >> > > -- > > ---------------------------------------------------------------------------------- > Some important links for excel users: > 1. Follow us on TWITTER for tips tricks and links : > http://twitter.com/exceldailytip > 2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310 > 3. Excel tutorials at http://www.excel-macros.blogspot.com > 4. Learn VBA Macros at http://www.quickvba.blogspot.com > 5. Excel Tips and Tricks at http://exceldailytip.blogspot.com > > To post to this group, send email to excel-macros@googlegroups.com > > <><><><><><><><><><><><><><><><><><><><><><> > Like our page on facebook , Just follow below link > http://www.facebook.com/discussexcel > -- *Regards* * * *Ashish Koul* *akoul*.*blogspot*.com <http://akoul.blogspot.com/> *akoul*.wordpress.com <http://akoul.wordpress.com/> My Linkedin Profile <http://in.linkedin.com/pub/ashish-koul/10/400/830> P Before printing, think about the environment. -- ---------------------------------------------------------------------------------- Some important links for excel users: 1. Follow us on TWITTER for tips tricks and links : http://twitter.com/exceldailytip 2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310 3. Excel tutorials at http://www.excel-macros.blogspot.com 4. Learn VBA Macros at http://www.quickvba.blogspot.com 5. Excel Tips and Tricks at http://exceldailytip.blogspot.com To post to this group, send email to excel-macros@googlegroups.com <><><><><><><><><><><><><><><><><><><><><><> Like our page on facebook , Just follow below link http://www.facebook.com/discussexcel