Installation Instructions
Prerequisites
- Visual Studio 2010 beta 2
- .Net Framework 4.0
- Microsoft Sharepoint 2010 beta 2
Deploying the VSIX to Microsoft Visual Studio 2010
- Double click on LightningTools.BCSMetaMan.vsix file
- Choose the product where you want to install the extension to and click on 'Install' button.
3. Open Visual Studio Instance and go to Tools->Options->Environment->Extension Manager and tick the check box to allow loading per user extensions.
4. Restart Microsoft Visual Studio
Checking it is installed properly
- Open Microsoft Visual Studio 2010
- Go to Tools->Extension Manager
- Make sure BCSMetaMan is installed
How to use
Create Empty Sharepoint Project
- Open Microsoft Visual Studio 2010
- Go to File->New->Project and choose "Empty Sharepoint Project" from Sharepoint\2010 node
3. Set some name to your project and click on "OK" button
4. Set the site url where you want to deploy solution to, choose "Deploy as a farm solution" as trust level and click on "Finish" button
Add BCS Meta Man Item Template
- Open Solution Explorer, right click on the project and choose "Add New Item" .
- Choose "BCSMetaMan" from "Add new item" dialog
3. Click on Add button.It will add new folder to your project which contains diagram to configure BCS Model and required files for F5 deployment. New feature will be added to "Features" folder as well.
Configure BCS Model with Lightning Tools BCS Meta Man
1. Double click on diagram file in solution explorer( it is the file with *.bcsmm extension )
2. When the diagram file is opened you can see the "BCS Meta Man" menu item in Visual Studio's menu. Click on it and choose "BCS Meta Man Data Source Explorer"
3. Data source explorer window will be opened and you can setup connection to your back end database (SQL Server so far). Click on "Add Connection"
4. When you setup connection, it will populate tree view with databases and tables. You can dock the data source explorer as well.
5. You can drag and drop any table from the data source explorer to BCS Meta Man diagram. When you drop the table it will popup "Entity Creation Wizard" where you can select identifiers and methods to be generated.
6. When configuration is completed , it will draw a shape on the diagram appropriate to your table and settings,it will add also 3 files to your project - DBML for Linq to SQL, table representive class and service class where the methods are implemented.
7. You can make extra settings(set title, modify identifiers or create actions) in "Entity Management dialog". To view this dialog you should right click on shape's title and choose "Manage Entity".
8. If you want to create an association between two entities you should open the toolbox and use "Association". When you drag and drop the "Association" it will popup a dialog to configure the association. You should set source and destination type descriptors. Just after that, new C# method will be generated and added to destination external content type's service class.
Deploy solution
At this point when BCS Model is configured you can deploy the solution. When you use Lightning Tools BCS Meta Man item template it adds folder to your project and that folder contains required files for F5 deployment, e.g. *.spdata. It also adds new feature to "Features" folder.
- Set the created project as Start up Project
- Click F5 or CTRL+F5(without debugging). It will deploy BCS Model after which you can use External Content Lists or BCS Web Parts to view/edit database's records.
Using External Content List
1. Navigate to the site where you have deployed the BCS Model.
2. Click on Lists and it will show already created lists and "Create" button to add new one.
3. Choose External Content List from available templates and click on "Create" button at right hand side.
4. Do appropriate settings.
5. Now it will call Finder method of the External Content Type and view the records list.
6. If you define Specific Finder, Creator and Updater in BCS Model, you can use "View Item","Edit Item","New Item" buttons to view/update/insert records. Below are the screenshots.
