VBA Code - InfoPath Dev
in

InfoPath Dev

VBA Code

Last post 06-20-2006 07:41 AM by dlgross. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 06-19-2006 04:58 AM

    • G105ALY
    • Not Ranked
    • Joined on 05-17-2006
    • United Kingdom
    • Posts 8

    VBA Code

    Hi guys,

    I am using VBA in Excel with imported data, can anyone tell me why this code won't work:

    Sub Test()
    Dim mycomment As String
    mycomment = Range("a1")
    Range("a1").Comment.Text.mycomment
    End Sub

    I want it to show the contents of a cell in a comments box. Any help would be most appreciated?
  • 06-20-2006 07:41 AM In reply to

    The range property needs to be assigned to an Object (e.g. the worksheet needs to be defined)
    Dean
    Charlotte, NC
Page 1 of 1 (2 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.