By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,025 Members | 2,118 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,025 IT Pros & Developers. It's quick & easy.

Error accessing mscorlib.dll

P: n/a
Hola amigos,

Me he creado una biblioteca de clases y dentro una clase (Class1)
que hereda de System.EnterpriseServices.ServicedComponent.
En la clase he creado una función de tipo System.Guid y
en el return le pongo: ContextUtil.ContexId.

En la misma solución me he creado otro proyecto
(Aplicaciones Windows) y en el formulario (en el evento
Load) le pongo:
Try
Dim obj As New Class1
Me.Label1.Text = obj.GetContextID.ToString
Catch ex As System.UnauthorizedAccessException
Me.Label1.Text = "El mensaje de error es: " &
ex.Message
End Try

Cuando ejecuta la instanciación de obj me da un error:
Acceso denegado. Se refiere a la librer*a mscorlib.dll.

¿Me podéis contar cómo solucionarlo?.

Muchas gracias.

Nov 21 '05 #1
Share this Question
Share on Google+
4 Replies


P: n/a
No Habol Espaneol

--

OHM ( Terry Burns )
. . . One-Handed-Man . . .
If U Need My Email ,Ask Me

Time flies when you don't know what you're doing

"Alonso" <Al****@discussions.microsoft.com> wrote in message
news:66**********************************@microsof t.com...
Hola amigos,

Me he creado una biblioteca de clases y dentro una clase (Class1)
que hereda de System.EnterpriseServices.ServicedComponent.
En la clase he creado una funcin de tipo System.Guid y
en el return le pongo: ContextUtil.ContexId.

En la misma solucin me he creado otro proyecto
(Aplicaciones Windows) y en el formulario (en el evento
Load) le pongo:
Try
Dim obj As New Class1
Me.Label1.Text = obj.GetContextID.ToString
Catch ex As System.UnauthorizedAccessException
Me.Label1.Text = "El mensaje de error es: " &
ex.Message
End Try

Cuando ejecuta la instanciacin de obj me da un error:
Acceso denegado. Se refiere a la librera mscorlib.dll.

Me podis contar cmo solucionarlo?.

Muchas gracias.

Nov 21 '05 #2

P: n/a
Alonso,

Please do this in this newsgroup in English, a very important part of the
visitors of this newsgroup have not English as native language, so you will
not be the only one who makes mistakes.

About your problem: I would add what I wrote inline in your situatuation,
because you are now not catching the general exeptions.
Try
Dim obj As New Class1
Me.Label1.Text = obj.GetContextID.ToString
Catch ex As System.UnauthorizedAccessException
Me.Label1.Text = "El mensaje de error es: " &
ex.Message
Catch ex as Exception
me.label1.text = ex.tostring
End Try


I hope this helps?

Cor
Nov 21 '05 #3

P: n/a
I am sorry. I repeat the question in English with the subject: Error
accessing mscorlib.dll (2).

Thank you for your answer.

Alonso

"One Handed Man ( OHM - Terry Burns )" wrote:
No Habol Espaneol

--

OHM ( Terry Burns )
. . . One-Handed-Man . . .
If U Need My Email ,Ask Me

Time flies when you don't know what you're doing

"Alonso" <Al****@discussions.microsoft.com> wrote in message
news:66**********************************@microsof t.com...
Hola amigos,

Me he creado una biblioteca de clases y dentro una clase (Class1)
que hereda de System.EnterpriseServices.ServicedComponent.
En la clase he creado una función de tipo System.Guid y
en el return le pongo: ContextUtil.ContexId.

En la misma solución me he creado otro proyecto
(Aplicaciones Windows) y en el formulario (en el evento
Load) le pongo:
Try
Dim obj As New Class1
Me.Label1.Text = obj.GetContextID.ToString
Catch ex As System.UnauthorizedAccessException
Me.Label1.Text = "El mensaje de error es: " &
ex.Message
End Try

Cuando ejecuta la instanciación de obj me da un error:
Acceso denegado. Se refiere a la librer*a mscorlib.dll.

¿Me podéis contar cómo solucionarlo?.

Muchas gracias.


Nov 21 '05 #4

P: n/a
I am sorry. I repeat the question in English with the subject: Error
accessing mscorlib.dll (2).

Thank you for your answer.

Alonso

"Cor Ligthert" wrote:
Alonso,

Please do this in this newsgroup in English, a very important part of the
visitors of this newsgroup have not English as native language, so you will
not be the only one who makes mistakes.

About your problem: I would add what I wrote inline in your situatuation,
because you are now not catching the general exeptions.
Try
Dim obj As New Class1
Me.Label1.Text = obj.GetContextID.ToString
Catch ex As System.UnauthorizedAccessException
Me.Label1.Text = "El mensaje de error es: " &
ex.Message


Catch ex as Exception
me.label1.text = ex.tostring
End Try


I hope this helps?

Cor

Nov 21 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.