Showing posts with label created. Show all posts
Showing posts with label created. Show all posts

Saturday, March 31, 2012

System.EventHandler created but event not fired

I'm having this exact same problem:

http://groups.google.com/group/micr...d072e420a5a96ea
I'm having problems with dropdownlists in a random fashion, some of
them work, and some dont, and the code for eventhandler binding is
there.

for example:

private void InitializeComponent()
{
this.cbBranches.SelectedIndexChanged += new
System.EventHandler(this.cbBranches_SelectedIndexC hanged_1);
..
..
..
}

SelectedIndexChanged_1 never gets called
anyone ever solved this?Make sure InitializeComponent is being called. (breakpoint)

Are you setting the AutoPostBack property to True?

If you set it to false, then the code will only run when you do a postback
(which could be several different things triggering a postback)

<lauralucas@.gmail.comwrote in message
news:1154448495.232168.8670@.s13g2000cwa.googlegrou ps.com...

Quote:

Originally Posted by

I'm having this exact same problem:
>
>


http://groups.google.com/group/micr...d072e420a5a96ea

Quote:

Originally Posted by

>
I'm having problems with dropdownlists in a random fashion, some of
them work, and some dont, and the code for eventhandler binding is
there.
>
for example:
>
private void InitializeComponent()
{
this.cbBranches.SelectedIndexChanged += new
System.EventHandler(this.cbBranches_SelectedIndexC hanged_1);
.
.
.
}
>
SelectedIndexChanged_1 never gets called
anyone ever solved this?
>


AutoPostBack property!!! that was it!! thanks a lot!! =D
sloan wrote:

Quote:

Originally Posted by

Make sure InitializeComponent is being called. (breakpoint)
>
Are you setting the AutoPostBack property to True?
>
If you set it to false, then the code will only run when you do a postback
(which could be several different things triggering a postback)
>
>
>
>
<lauralucas@.gmail.comwrote in message
news:1154448495.232168.8670@.s13g2000cwa.googlegrou ps.com...

Quote:

Originally Posted by

I'm having this exact same problem:


http://groups.google.com/group/micr...d072e420a5a96ea

Quote:

Originally Posted by


I'm having problems with dropdownlists in a random fashion, some of
them work, and some dont, and the code for eventhandler binding is
there.

for example:

private void InitializeComponent()
{
this.cbBranches.SelectedIndexChanged += new
System.EventHandler(this.cbBranches_SelectedIndexC hanged_1);
.
.
.
}

SelectedIndexChanged_1 never gets called
anyone ever solved this?


You should go post your new found knowledge at that other post.

To keep making the world a better place.

<lauralucas@.gmail.comwrote in message
news:1154453257.813172.113540@.b28g2000cwb.googlegr oups.com...

Quote:

Originally Posted by

AutoPostBack property!!! that was it!! thanks a lot!! =D
sloan wrote:

Quote:

Originally Posted by

Make sure InitializeComponent is being called. (breakpoint)

Are you setting the AutoPostBack property to True?

If you set it to false, then the code will only run when you do a


postback

Quote:

Originally Posted by

Quote:

Originally Posted by

(which could be several different things triggering a postback)

<lauralucas@.gmail.comwrote in message
news:1154448495.232168.8670@.s13g2000cwa.googlegrou ps.com...

Quote:

Originally Posted by

I'm having this exact same problem:
>
>



http://groups.google.com/group/micr...d072e420a5a96ea

Quote:

Originally Posted by

Quote:

Originally Posted by

Quote:

Originally Posted by

>
I'm having problems with dropdownlists in a random fashion, some of
them work, and some dont, and the code for eventhandler binding is
there.
>
for example:
>
private void InitializeComponent()
{
this.cbBranches.SelectedIndexChanged += new
System.EventHandler(this.cbBranches_SelectedIndexC hanged_1);
.
.
.
}
>
SelectedIndexChanged_1 never gets called
anyone ever solved this?
>


>

Wednesday, March 28, 2012

System.IO.Path.GetTempFileName

Hi,
System.IO.Path.GetTempFileName( ) is supposed to create a temporary file and give us the path to the created file.
By default, where does this temp file get created? C:\Temp, C:\WinNT ?
Bcos right now this fails and error we get is "Access denied". But we dont know which folder's permissions to change as we dont know where this temp file is supposed to get created.

It will be in the ASPNET user's Temp Directory. For example, on mine:
C:\Documents and Settings\ComputerName\ASPNET\Local Settings\Temp


You are right ! I just found that out by using

tempPathString = Path.GetTempPath()
Thanks !


correctomundo!!
I know this is an old post, but System.IO.Path.GetTempPath() only puts stuff in the ASPNET user directory when the app runs on XP Pro. That is fine for development, but when the app is deployed to a Windows 2003 server the method returns C:\Windows\Temp. Calling GetTempFileName() creates a temp file there. Surely, it isn't safe or a best practice to write to the Windows directory, is it?

Saturday, March 24, 2012

System.Net.WebException: The underlying connection was closed:

Hi Tim,

From your description, you've a ASP.NET webservcie and created a Winform
client app to consume it. However, when calling the webservice, you found
it worked well the first time but occured unexpected error the second time
after a few minutes, yes?

From the code you provided(calling the webservice), it seems all right and
I don't think the problem is likely in the client application. I'm not sure
about the webservice's detailed code logic in its webmethods but from the
method's signature:

WebSvcW.OMTestAddOrderXML(comboBox3.Text,int.Parse (textBox2.Text),comboBox4.
Text);

it takes simply type params, so I think we can test the webservice through
IE, open the certain url (http://...... .asmx) in the IE and call the
webservice thourgh it. It is better if you can use VS.NET to debug the
webservice on the serverside to see whether the problem also occured when
calling it from IE. If still remains, we can confirm that the problem is
not caused by the winform client , do you think so?

In addition, as for creating client application to consume webservice,
below is the related web link in MSDN:
#Creating Clients for XML Web Services
http://msdn.microsoft.com/library/e...atingclientsfor
webservices.asp?frame=true

Hope also helps. Thanks.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspxHi Tim,

Have you had a chance to view the suggestions in my last reply or have you
got any progresses on this issue? If there is anything else I can help,
please feel free to post here. Thanks.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
Thanks for your reply. However, when I try to go directly to the ..asmx url via IA, when I click on the name of the web service in order to test, I receive this message - Tes
The test form is only available for requests from the local machine. Therefore, I am unclear on how to proceed. The server is in another state so I can't logon directly to it in order to test from my location. How shall I proceed

Thank you
Tim Reynold
Verizon
Hi Tim,

From your reply, you haven't the certain permission to logon the server
which host the webservice, yes? Then, I think we can do the following tests
on the webservice:

1. Creating a client proxy through the following guide(using wsdl.exe
rather than via VS.NET) and consume the webservice by the geneated proxy to
see whether the webservice still fail.
#Creating an XML Web Service Proxy
http://msdn.microsoft.com/library/e...atingWebService
Proxy.asp?frame=true

2. I'm not sure whether you have ever tried calling a webservice via
javascript(DHTML) in a webpage, if not, you may have a look at the
following reference:
#Accessing Web Services From DHTML
http://msdn.microsoft.com/library/e...001.asp?frame=t
rue

If you're able to perform a test via the DHTML way, we can further confirm
whether the problem is with the serverside or not.

In addtion, you can create a simple webservice( similiar with the one
you're consuming, maybe just take 2 string parameters) on your local
machine or a remote machine which you have full control on it. And then
call it on the local machine to see whether the same problem occurs. If
not, that also probably proof that the problem is likely due to the
webservice's serverside processing.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
Hi Tim,

Any progress on this issue? If you have any problems on this or if there're
anything else I can help, please feel free to let me know. Thanks.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx

System.Net.WebException: The underlying connection was closed:

Hi Tim,

From your description, you've a ASP.NET webservcie and created a Winform
client app to consume it. However, when calling the webservice, you found
it worked well the first time but occured unexpected error the second time
after a few minutes, yes?

From the code you provided(calling the webservice), it seems all right and
I don't think the problem is likely in the client application. I'm not sure
about the webservice's detailed code logic in its webmethods but from the
method's signature:

WebSvcW.OMTestAddOrderXML(comboBox3.Text,int.Parse (textBox2.Text),comboBox4.
Text);

it takes simply type params, so I think we can test the webservice through
IE, open the certain url (http://...... .asmx) in the IE and call the
webservice thourgh it. It is better if you can use VS.NET to debug the
webservice on the serverside to see whether the problem also occured when
calling it from IE. If still remains, we can confirm that the problem is
not caused by the winform client , do you think so?

In addition, as for creating client application to consume webservice,
below is the related web link in MSDN:
#Creating Clients for XML Web Services
http://msdn.microsoft.com/library/e...atingclientsfor
webservices.asp?frame=true

Hope also helps. Thanks.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspxHi Tim,

Have you had a chance to view the suggestions in my last reply or have you
got any progresses on this issue? If there is anything else I can help,
please feel free to post here. Thanks.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
Thanks for your reply. However, when I try to go directly to the ..asmx url via IA, when I click on the name of the web service in order to test, I receive this message - Tes
The test form is only available for requests from the local machine. Therefore, I am unclear on how to proceed. The server is in another state so I can't logon directly to it in order to test from my location. How shall I proceed

Thank you
Tim Reynold
Verizon
Hi Tim,

From your reply, you haven't the certain permission to logon the server
which host the webservice, yes? Then, I think we can do the following tests
on the webservice:

1. Creating a client proxy through the following guide(using wsdl.exe
rather than via VS.NET) and consume the webservice by the geneated proxy to
see whether the webservice still fail.
#Creating an XML Web Service Proxy
http://msdn.microsoft.com/library/e...atingWebService
Proxy.asp?frame=true

2. I'm not sure whether you have ever tried calling a webservice via
javascript(DHTML) in a webpage, if not, you may have a look at the
following reference:
#Accessing Web Services From DHTML
http://msdn.microsoft.com/library/e...001.asp?frame=t
rue

If you're able to perform a test via the DHTML way, we can further confirm
whether the problem is with the serverside or not.

In addtion, you can create a simple webservice( similiar with the one
you're consuming, maybe just take 2 string parameters) on your local
machine or a remote machine which you have full control on it. And then
call it on the local machine to see whether the same problem occurs. If
not, that also probably proof that the problem is likely due to the
webservice's serverside processing.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
Hi Tim,

Any progress on this issue? If you have any problems on this or if there're
anything else I can help, please feel free to let me know. Thanks.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx

System.Net.WebException: The underlying connection was closed:

Hi Tim,

From your description, you've a ASP.NET webservcie and created a Winform
client app to consume it. However, when calling the webservice, you found
it worked well the first time but occured unexpected error the second time
after a few minutes, yes?

From the code you provided(calling the webservice), it seems all right and
I don't think the problem is likely in the client application. I'm not sure
about the webservice's detailed code logic in its webmethods but from the
method's signature:

WebSvcW.OMTestAddOrderXML(comboBox3.Text,int.Parse (textBox2.Text),comboBox4.
Text);

it takes simply type params, so I think we can test the webservice through
IE, open the certain url (http://...... .asmx) in the IE and call the
webservice thourgh it. It is better if you can use VS.NET to debug the
webservice on the serverside to see whether the problem also occured when
calling it from IE. If still remains, we can confirm that the problem is
not caused by the winform client , do you think so?

In addition, as for creating client application to consume webservice,
below is the related web link in MSDN:
#Creating Clients for XML Web Services
http://msdn.microsoft.com/library/e...atingclientsfor
webservices.asp?frame=true

Hope also helps. Thanks.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspxHi Tim,

Have you had a chance to view the suggestions in my last reply or have you
got any progresses on this issue? If there is anything else I can help,
please feel free to post here. Thanks.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
Thanks for your reply. However, when I try to go directly to the ..asmx url via IA, when I click on the name of the web service in order to test, I receive this message - Tes
The test form is only available for requests from the local machine. Therefore, I am unclear on how to proceed. The server is in another state so I can't logon directly to it in order to test from my location. How shall I proceed

Thank you
Tim Reynold
Verizon
Hi Tim,

From your reply, you haven't the certain permission to logon the server
which host the webservice, yes? Then, I think we can do the following tests
on the webservice:

1. Creating a client proxy through the following guide(using wsdl.exe
rather than via VS.NET) and consume the webservice by the geneated proxy to
see whether the webservice still fail.
#Creating an XML Web Service Proxy
http://msdn.microsoft.com/library/e...atingWebService
Proxy.asp?frame=true

2. I'm not sure whether you have ever tried calling a webservice via
javascript(DHTML) in a webpage, if not, you may have a look at the
following reference:
#Accessing Web Services From DHTML
http://msdn.microsoft.com/library/e...001.asp?frame=t
rue

If you're able to perform a test via the DHTML way, we can further confirm
whether the problem is with the serverside or not.

In addtion, you can create a simple webservice( similiar with the one
you're consuming, maybe just take 2 string parameters) on your local
machine or a remote machine which you have full control on it. And then
call it on the local machine to see whether the same problem occurs. If
not, that also probably proof that the problem is likely due to the
webservice's serverside processing.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
Hi Tim,

From your reply, you haven't the certain permission to logon the server
which host the webservice, yes? Then, I think we can do the following tests
on the webservice:

1. Creating a client proxy through the following guide(using wsdl.exe
rather than via VS.NET) and consume the webservice by the geneated proxy to
see whether the webservice still fail.
#Creating an XML Web Service Proxy
http://msdn.microsoft.com/library/e...atingWebService
Proxy.asp?frame=true

2. I'm not sure whether you have ever tried calling a webservice via
javascript(DHTML) in a webpage, if not, you may have a look at the
following reference:
#Accessing Web Services From DHTML
http://msdn.microsoft.com/library/e...001.asp?frame=t
rue

If you're able to perform a test via the DHTML way, we can further confirm
whether the problem is with the serverside or not.

In addtion, you can create a simple webservice( similiar with the one
you're consuming, maybe just take 2 string parameters) on your local
machine or a remote machine which you have full control on it. And then
call it on the local machine to see whether the same problem occurs. If
not, that also probably proof that the problem is likely due to the
webservice's serverside processing.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
Hi Tim,

Any progress on this issue? If you have any problems on this or if there're
anything else I can help, please feel free to let me know. Thanks.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
Hi Tim,

Any progress on this issue? If you have any problems on this or if there're
anything else I can help, please feel free to let me know. Thanks.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx

System.Net.WebException: The underlying connection was closed:

Team,
We have deployed a webservice (asmx.cs) to a server. We have created a windo
ws app (C# using visual studios.net 2003 Enterprise Arch) that refers to the
web service. In the windows app, we added the web reference - referring to
the ?wsdl file. The C# co
de is quite simple:
VOSEWebServicesDevW.WebServices WebSvcW = new VOSEWebServicesDevW.WebService
s();
returncode = WebSvcW.OMTestAddOrderXML(comboBox3.Text,int.Parse(textBox2.Tex
t),comboBox4.Text);
This works fine the first time- but when it sits a few minutes and we retry
, we receive...
See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.
************** Exception Text **************
System.Net.WebException: The underlying connection was closed: An unexpected
error occurred on a send.
at System.Web.Services.Protocols.WebClientProtocol.GetWebResponse(WebRequest
request)
at System.Web.Services.Protocols.HttpWebClientProtocol.GetWebResponse(WebReq
uest request)
at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String method
Name, Object[] parameters)
at TestWebServiceW.VOSEWebServicesDevW.WebServices.OMTestAddOrderXML(String
strCompany, Int32 intOrderNo, String strOrderType)
at TestWebServiceW.Form1.button1_Click(Object sender, EventArgs e)
at System.Windows.Forms.Control.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, I
nt32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ButtonBase.WndProc(Message& m)
at System.Windows.Forms.Button.WndProc(Message& m)
at System.Windows.Forms.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr
wparam, IntPtr lparam)
The project for the web service has a web.config file. I see no settings in
there of interest. I am new to this.
I would appreciate the guidance on what to do in the windows app C# code to
correctly access the web service on the team's server without having to clos
e & restart the windows app.
Thanks,
Tim Reynolds
VerizonHi Tim,
From your description, you've a ASP.NET webservcie and created a Winform
client app to consume it. However, when calling the webservice, you found
it worked well the first time but occured unexpected error the second time
after a few minutes, yes?
From the code you provided(calling the webservice), it seems all right and
I don't think the problem is likely in the client application. I'm not sure
about the webservice's detailed code logic in its webmethods but from the
method's signature:
WebSvcW.OMTestAddOrderXML(comboBox3.Text,int.Parse(textBox2.Text),comboBox4.
Text);
it takes simply type params, so I think we can test the webservice through
IE, open the certain url (http://...... .asmx) in the IE and call the
webservice thourgh it. It is better if you can use VS.NET to debug the
webservice on the serverside to see whether the problem also occured when
calling it from IE. If still remains, we can confirm that the problem is
not caused by the winform client , do you think so?
In addition, as for creating client application to consume webservice,
below is the related web link in MSDN:
#Creating Clients for XML Web Services
http://msdn.microsoft.com/library/e...atingclientsfor
webservices.asp?frame=true
Hope also helps. Thanks.
Regards,
Steven Cheng
Microsoft Online Support
Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)
Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
Hi Tim,
Have you had a chance to view the suggestions in my last reply or have you
got any progresses on this issue? If there is anything else I can help,
please feel free to post here. Thanks.
Regards,
Steven Cheng
Microsoft Online Support
Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)
Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
Thanks for your reply. However, when I try to go directly to the ..asmx url
via IA, when I click on the name of the web service in order to test, I rec
eive this message - Test
The test form is only available for requests from the local machine. There
fore, I am unclear on how to proceed. The server is in another state so I ca
n't logon directly to it in order to test from my location. How shall I pro
ceed?
Thank you,
Tim Reynolds
Verizon
Hi Tim,
Any progress on this issue? If you have any problems on this or if there're
anything else I can help, please feel free to let me know. Thanks.
Regards,
Steven Cheng
Microsoft Online Support
Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)
Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
Hi Tim,
From your reply, you haven't the certain permission to logon the server
which host the webservice, yes? Then, I think we can do the following tests
on the webservice:
1. Creating a client proxy through the following guide(using wsdl.exe
rather than via VS.NET) and consume the webservice by the geneated proxy to
see whether the webservice still fail.
#Creating an XML Web Service Proxy
http://msdn.microsoft.com/library/e...atingWebService
Proxy.asp?frame=true
2. I'm not sure whether you have ever tried calling a webservice via
javascript(DHTML) in a webpage, if not, you may have a look at the
following reference:
#Accessing Web Services From DHTML
http://msdn.microsoft.com/library/e...001.asp?frame=t
rue
If you're able to perform a test via the DHTML way, we can further confirm
whether the problem is with the serverside or not.
In addtion, you can create a simple webservice( similiar with the one
you're consuming, maybe just take 2 string parameters) on your local
machine or a remote machine which you have full control on it. And then
call it on the local machine to see whether the same problem occurs. If
not, that also probably proof that the problem is likely due to the
webservice's serverside processing.
Regards,
Steven Cheng
Microsoft Online Support
Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)
Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx

Tuesday, March 13, 2012

System.Security.SecurityException: That assembly does not allow

I have created an ActiveX control that does word automation. Once I
creat an instance of work I get the following message
System.Security.SecurityException: That assembly does not allow
partially trusted callers.
I am using .net 2. I have a key and use the regasm tool after it the
dll is compiled
I am really lost on how to make this work any help will be appreciated
JohnDid this work for you?
I have a .NET class that i have made com visible and the client is
trying to access it using Visual Objects over a network shar and is
getting the same exception.
i have added the AllowPartiallyTusterCallers attribute to my
assemblyinfo.cs but is hasnt fixed it.
i have ben trying to test using something non .NET (VB 6.0) but i cant
even reference the tlb or dll but i think that is a VB 6.0 issue.
if anyone has any suggestions pleae let me know.
the Client has advised that the dll works if it is copied locally.
thanks

System.Security.SecurityException: That assembly does not allowpartially trusted callers.

I have created an ActiveX control that does word automation. Once I
creat an instance of work I get the following message
System.Security.SecurityException: That assembly does not allow
partially trusted callers.

I am using .net 2. I have a key and use the regasm tool after it the
dll is compiled

I am really lost on how to make this work any help will be appreciated

Johnyou prolly have to add this to your code:

[assembly: AllowPartiallyTrustedCallers]

--
Dominick Baier (http://www.leastprivilege.com)

Developing More Secure Microsoft ASP.NET 2.0 Applications (http://www.microsoft.com/mspress/books/9989.asp)

Quote:

Originally Posted by

I have created an ActiveX control that does word automation. Once I
creat an instance of work I get the following message
System.Security.SecurityException: That assembly does not allow
partially trusted callers.
>
I am using .net 2. I have a key and use the regasm tool after it the
dll is compiled
>
I am really lost on how to make this work any help will be appreciated
>
John
>

'System.ServiceModel/ServiceHostingEnvironment' configuration section cannot be created.

Hi All,

I deployed an ASP.NET Web Service on Server1 and it worked fine.
However when I deployed the same Web Service on Server2 I am getting the
following error,

The 'System.ServiceModel/ServiceHostingEnvironment' configuration section
cannot be created.
The Machin.config file is missing information.
Verify that this configuration section is properly registered and that you
have correctly splled the section name.
For Windoes Communication Foundation sections, run ServiceModelReg.exe -i to
fix this error.
....................

I never saw this error. What could be wrong?

Any pointer?

Thanks in advance
SachinOn Jun 5, 10:10 pm, "Sachin" <Sachi...@.Email.comwrote:

Quote:

Originally Posted by

Hi All,
>
I deployed an ASP.NET Web Service on Server1 and it worked fine.
However when I deployed the same Web Service on Server2 I am getting the
following error,
>
The 'System.ServiceModel/ServiceHostingEnvironment' configuration section
cannot be created.
The Machin.config file is missing information.
Verify that this configuration section is properly registered and that you
have correctly splled the section name.
For Windoes Communication Foundation sections, run ServiceModelReg.exe -i to
fix this error.
...................
>
I never saw this error. What could be wrong?
>
Any pointer?
>
Thanks in advance
Sachin


Verify the version of ASP.NET.

aspnet_regiis -ls
aspnet_regiis -i
etc...
On both server its .NET 2.0

"Alexey Smirnov" <alexey.smirnov@.gmail.comwrote in message
news:1181074886.601979.301780@.n4g2000hsb.googlegro ups.com...

Quote:

Originally Posted by

On Jun 5, 10:10 pm, "Sachin" <Sachi...@.Email.comwrote:

Quote:

Originally Posted by

>Hi All,
>>
>I deployed an ASP.NET Web Service on Server1 and it worked fine.
>However when I deployed the same Web Service on Server2 I am getting the
>following error,
>>
>The 'System.ServiceModel/ServiceHostingEnvironment' configuration section
>cannot be created.
>The Machin.config file is missing information.
>Verify that this configuration section is properly registered and that
>you
>have correctly splled the section name.
>For Windoes Communication Foundation sections, run ServiceModelReg.exe -i
>to
>fix this error.
>...................
>>
>I never saw this error. What could be wrong?
>>
>Any pointer?
>>
>Thanks in advance
>Sachin


>
Verify the version of ASP.NET.
>
aspnet_regiis -ls
aspnet_regiis -i
etc...
>


On Jun 5, 11:22 pm, "Sachin" <Sachi...@.Email.comwrote:

Quote:

Originally Posted by

On both server its .NET 2.0
>


Did you installed the .NET 3.0 on the Server2?
No.

This is what I get at the bottom of the error page.

Version Information: Microsoft .NET Framework Version: 2.0.50727.42; ASP.NET
Version:2.0.50727.210

"Alexey Smirnov" <alexey.smirnov@.gmail.comwrote in message
news:1181079744.934238.48060@.q66g2000hsg.googlegro ups.com...

Quote:

Originally Posted by

On Jun 5, 11:22 pm, "Sachin" <Sachi...@.Email.comwrote:

Quote:

Originally Posted by

>On both server its .NET 2.0
>>


>
Did you installed the .NET 3.0 on the Server2?
>


re:
!This is what I get at the bottom of the error page.
!Version Information: Microsoft .NET Framework Version: 2.0.50727.42;
!ASP.NET Version:2.0.50727.210

That looks like a W2K3 R2 install on Server2. Is it ?

Is it the same version which is installed on Server1 ?

Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en espaol : http://asp.net.do/foros/
======================================
"Sachin" <SachinGp@.Email.comwrote in message news:uX0uSz7pHHA.3892@.TK2MSFTNGP05.phx.gbl...

Quote:

Originally Posted by

No.


Quote:

Originally Posted by

This is what I get at the bottom of the error page.
>
Version Information: Microsoft .NET Framework Version: 2.0.50727.42; ASP.NET Version:2.0.50727.210


Quote:

Originally Posted by

"Alexey Smirnov" <alexey.smirnov@.gmail.comwrote in message
news:1181079744.934238.48060@.q66g2000hsg.googlegro ups.com...

Quote:

Originally Posted by

>On Jun 5, 11:22 pm, "Sachin" <Sachi...@.Email.comwrote:

Quote:

Originally Posted by

>>On both server its .NET 2.0
>>>


>>
>Did you installed the .NET 3.0 on the Server2?


On Jun 5, 11:58 pm, "Sachin" <Sachi...@.Email.comwrote:

Quote:

Originally Posted by

No.
>


I don't know what your service does, but Windows Communication
Foundation required .NET 3.0