简体   繁体   English

将.aspx页部署到SharePoint 2010

[英]Deploy a .aspx page to the Sharepoint 2010

I am new to sharepoint and have a scenario 我是新来的Sharepoint并有一个场景

1) I have a aspx page which displays some data from a xml. 1)我有一个aspx页面,显示来自xml的一些数据。

2) The data is populated in a table in the aspx page using a code behind .cs file. 2)使用.cs文件后面的代码将数据填充到aspx页的表中。

3) I use some dll's which I have made to access the data. 3)我使用我制作的一些dll来访问数据。

Note:- This things are done on my local pc which does not have a sharepoint server installed. 注意:-这些是在没有安装共享点服务器的本地PC上完成的。

Now my question is 现在我的问题是

1) I want a way using which I can use this page as a webpart in a sharepoint site. 1)我想要一种可以将此页面用作共享点网站中的Webpart的方式。

2) Can you please guide me a by which the compiled dll of the web application can be used as webpart. 2)您能否指导我,通过它可以将Web应用程序的已编译dll用作webpart。

Note:- I have access to put files on the server but cannot develop anything on that 注意:-我有权将文件放到服务器上,但不能在该服务器上开发任何东西

You can use the User Control in SharePoint and add it to your site page.. 您可以在SharePoint中使用用户控件,并将其添加到您的网站页面。

OR 要么

Use Visual Studio and create an empty SharePoint project (deploy as farm solution). 使用Visual Studio并创建一个空的SharePoint项目(部署为服务器场解决方案)。

Then, right click project and add mapped layouts folder. 然后,右键单击项目并添加映射的布局文件夹。

Rename this folder to whatever name you want to appear (this folder will get created on the servers layout folder in the hive) after you deploy the solution. 部署解决方案后,将此文件夹重命名为您想要显示的名称(此文件夹将在配置单元中的服务器布局文件夹中创建)。

Add your aspx page and cs into this folder 将您的aspx页面和cs添加到此文件夹中

Then, double click on package.package (its inside package, above layouts folder, under project)--> Advanced --> Add (existing assembly) and add your dll references here.(this will add the dlls under your sites sharepoint web.config. 然后,双击package.package(位于包中,位于布局文件夹上方,位于项目下)->高级->添加(现有程序集)并在此处添加您的dll引用(这将在您的站点sharepoint网站下添加dll。 .config。

After deploy, you can access page using: http://sharepointsite/_layouts/foldername/youraspxfilename.aspx 部署后,您可以使用以下页面访问页面: http://sharepointsite/_layouts/foldername/youraspxfilename.aspx

Let us know about the progress. 让我们知道进展情况。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM