• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

VBA Intro

KishorKK

Member
Hi All,

In VBA why can't we write like this..? Where it is going wrong can some one explain me?

For Ex:

sub msgbox()
msgbox("Hello!!")
End Sub

Why it's not executing like this if write like sub title() it will execute but if i use the same string like 'msgbox in sub' it won't work pls explain? Thanks

Regards,
Kishor
 
Msgbox is a keyword as it is a VBA Function
Title isn't a function or keyword

I'd suggest

Code:
Sub msg_box()
  msgbox ("Hello!!")
End Sub
 
Back
Top