Not sure how to explain it but here goes.
I have 2 projects that reference SQLite. 1 is for Windows and 1 is for Windows Phone.
Now i need to create a class library for each platform, and reference the correct SQLite project for each. Ideally i would like to create my code in one place and then reference it in each project. Problem is my code uses SQLite.
I do not really want to have a separate copy in each project for each platform.
Can i do what i want, or not possible?
I only thought i maybe able to because if i create a windows application using cordova, it somehow creates 3 projects, 1 for windows, 1 for phone and the other has its shared resources in.
Here is a the sort of thing of what i would like
SQLite - Windows SQLite - Phone
Library - Windows (references SQLite Windows) Library - Phone (references SQLite Phone) Library - Shared (shared code that both library projects can use)
Cordova - Windows (references Library Windows) Cordova - Phone (references Library Phone) Cordova - Shared (shared resources that both cordova projects can use)
This is all because the SQLite cannot run on both WIndows and Phone, so need a separate project for each
Use file linking in the project.
This is an old Silverlight trick to share one set of code between two projects or two different versions of the CLR.
Create the code in project 1. Then for project 2, add the files by linking them from project 1. To do that type of add link this is the process:
The trick is to include as a link into the project. Here is how
Add
then Existing Item...
or shift alt A.Add
button select the drop down arrow.Select Add as link
to add the common files(s) as a link into the project.
That will give access to the file as if the file was actually within the project, but the file physically resides elsewhere.