I am trying to use the Shell()
function of Vba
in office 2010
, however it is returning me the following error:
Compile error
Expected Error: =
My code looks like this:
Dim programa As String: programa = "caminho do programa"
'Somente assim funciona
Shell(programa)
'Setando o parâmetro windowstyle ocorre o erro acima.
Shell(programa, vbNormalFocus)
Looking at the documentation and even then still giving error.