Where should the client side control live in ASP.NET app fiolder?

Where should the client side control live in ASP.NET app fiolder?

Post by SGFuaSBBdG » Fri, 22 Oct 2004 03:21:07


I developed a client side control using Windows Forms and I want to deploy it
through IE inside an ASP.NET project.

I am using the object tag to deploy:

<OBJECT id="SSFileCtrl1" classid="SSCtrl.dll#SSCtrl.SSFileCtrl" VIEWASTEXT>
</OBJECT>

The previous code only works if SSCtrl.dll is inside the application root of
ASP.NET project. It doesn't work if the file is inside the "bin" folder,
which I assume it should work fine!!?

I tried the following classid="bin/SSCtrl.dll#SSCtrl.SSFileCtrl" and it
didn't work too.

Is there a way to make this work if the control is inside the bin folder?

Thanks for any help,
 
 
 

Where should the client side control live in ASP.NET app fiolder?

Post by bruce bark » Fri, 22 Oct 2004 07:35:20

look at the codebase attribute

-- bruce (sqlwork.com)



it
VIEWASTEXT>
of

 
 
 

Where should the client side control live in ASP.NET app fiolder?

Post by v-schan » Fri, 22 Oct 2004 12:10:35

Hi Hani,

Thanks for your posting. As for the problem you mentioned, based on my
test, if the web page that used the winform control is also in the web
app's root folder, it can find the assembly correctly if we assign the path
as
classid="bin/Assembly.dll#Namespace.Class"

So are your web pages also in the web app's root folder or is some other
folder hierarchy in the web app?
Also, I suggest you try using the dynamic generated path in your page such
as:

<OBJECT id="wlbl" classid='<%= ResolveUrl("~/bin/")
%>WindowsControlLib.dll#WindowsControlLib.WLabel' VIEWASTEXT></OBJECT>

#ResolveUrl("~/bin/") will return the path of the "bin" sub folder under
the application's root folder

Hope 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.)