hmm... just to be clear, your statement: "Just remove the inverted commas" is not entirely accurate.
Those are quotes (") not commas(,) and, "inverted" means up-side-down. The quotes that were used is what is called "curly quotes" or "book quotes" or techincally called "reversed" or "double prime" quotes. In some cases, an editor (html, or possibly MS Word), when using a specific font, may convert them as to indicate an "opening" and "closing" quote. Nevertheless, while some programming languages utilize them, VBA does not. So, as you indicated, if the code was entered into one of these editors which converted the symbol, it would have to be corrected before VBA would recognize it. Paul ----------------------------------------- “Do all the good you can, By all the means you can, In all the ways you can, In all the places you can, At all the times you can, To all the people you can, As long as ever you can.” - John Wesley ----------------------------------------- ________________________________ From: Rajan_Verma <rajanverma1...@gmail.com> To: excel-macros@googlegroups.com Sent: Tue, October 23, 2012 10:24:20 AM Subject: RE: $$Excel-Macros$$ MsgBox Query It seems that you copy it from somewhere, Just remove the inverted commas and put them again Private Sub CommandButton2_Click() contents = Worksheets("Sheet1").Range("A1").Value MsgBox contents ' I WANT THE VALUE OR ANY TEXT IN A1 CELL SHOULD APPEAR IN THE MESSAGE BOX End Sub Regards Rajan verma +91 7838100659 [IM-Gtalk] From:excel-macros@googlegroups.com [mailto:excel-macros@googlegroups.com] On Behalf Of SAJID MEMON Sent: 23 October 2012 10:41 To: Sundarvelan Natarajan Subject: $$Excel-Macros$$ MsgBox Query Dears, Find enclosed above attachemnt I WANT THE VALUE OR ANY TEXT IN A1 CELL SHOULD APPEAR IN THE MESSAGE BOX Awiting... Sajid Memon -- Join official facebook page of this forum @ https://www.facebook.com/discussexcel FORUM RULES (1120+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. 6) Jobs posting is not allowed. 7) Sharing copyrighted ebooks/pirated ebooks/their links is not allowed. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. --- You received this message because you are subscribed to the Google Groups "MS EXCEL AND VBA MACROS" group. To post to this group, send email to excel-macros@googlegroups.com. To unsubscribe from this group, send email to excel-macros+unsubscr...@googlegroups.com. -- Join official facebook page of this forum @ https://www.facebook.com/discussexcel FORUM RULES (1120+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. 6) Jobs posting is not allowed. 7) Sharing copyrighted ebooks/pirated ebooks/their links is not allowed. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. --- You received this message because you are subscribed to the Google Groups "MS EXCEL AND VBA MACROS" group. To post to this group, send email to excel-macros@googlegroups.com. To unsubscribe from this group, send email to excel-macros+unsubscr...@googlegroups.com. -- Join official facebook page of this forum @ https://www.facebook.com/discussexcel FORUM RULES (1120+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. 6) Jobs posting is not allowed. 7) Sharing copyrighted ebooks/pirated ebooks/their links is not allowed. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. --- You received this message because you are subscribed to the Google Groups "MS EXCEL AND VBA MACROS" group. To post to this group, send email to excel-macros@googlegroups.com. To unsubscribe from this group, send email to excel-macros+unsubscr...@googlegroups.com.