
-----------------------------------
Ben
Sun May 08, 2005 6:42 pm

absolute beginner
-----------------------------------
Hi. I'm am completely just beggining to use VB. I have used Turing before, but i know pretty well nothing about Visual Basic, but I would like to learn. But first, I'm having a problem. I was reading a tutorial that was posted, and I tried a small piece of code -msgbox ("hello")-   and ten I hit f5 to run it. I then get this messege: 

An unhandled exception of type 'System.Security.Policy.PolicyException' occurred in Unknown Module.

Additional information: Execution permission cannot be acquired.

Can anyone help me with this?

-----------------------------------
GlobeTrotter
Sun May 08, 2005 8:05 pm


-----------------------------------
first of all, it sgould be 

Call MsgBox ("Hello")


But that wouldn't cause the error you have.  I'm not really sure what to tell you.  Are you doing it on a school computer?

-----------------------------------
Ben
Sun May 08, 2005 8:32 pm


-----------------------------------
Nope, my home computer.

-----------------------------------
Maverick
Sun May 08, 2005 8:51 pm


-----------------------------------
Thats vbecause your using the wrong command

Im not positive but i think its

Msgbox("Message", vbOkOnly, "Title")

Ill post the correct one tomorrow since im not positive

-----------------------------------
Maverick
Mon May 09, 2005 7:40 am


-----------------------------------
Dim Response as Integer
Response = MsgBox(Message, Type, Title)

-----------------------------------
GlobeTrotter
Mon May 09, 2005 5:08 pm


-----------------------------------
Dim Response as Integer
Response = MsgBox(Message, Type, Title)

That's not necessary.  Once can simply put
Call MsgBox ("Hello")
And it will work, assigning defaults to type and title.

-----------------------------------
diqua
Tue May 10, 2005 12:51 pm


-----------------------------------
msgbox "Hello" 
should still work


other wise check your user permissions in the windows user control panel module

-----------------------------------
Maverick
Tue May 10, 2005 6:11 pm


-----------------------------------
Dim Response as Integer
Response = MsgBox(Message, Type, Title)

That's not necessary.  Once can simply put
Call MsgBox ("Hello")
And it will work, assigning defaults to type and title.

Ya but if he wanted to make changes to it, that way is more difficult

-----------------------------------
Ben
Wed May 11, 2005 6:59 pm


-----------------------------------
i tried all the codes you guys suggested, but its still coming up...

-----------------------------------
Ben
Wed May 18, 2005 3:24 pm


-----------------------------------
i fixed it. Thanks for your help. now i just need to learn how to do anything lol
