I have two connectable webparts but i want to have them on different pages is it possible? If it is , how to i solve this??
public interface IData
{
string Mydata { get; }
}
How are you connecting the two webparts together? I presume you have an interface class? this interface class needs to be in a seperate project and built. Add the interface class to the gac (dll into the assembly folder). Then add the dll to the references in both the consumer and provider webparts.
EDIT
MSDN Cross-page Web Part Connections
http://msdn.microsoft.com/en-us/library/dd585662(v=office.11).aspx
END EDIT
It is possible, check this out:
http://www.codeproject.com/Articles/37142/Connecting-Custom-Web-Parts-in-SharePoint
msdn example
http://msdn.microsoft.com/en-us/library/ff597538.aspx
question answered by me:
Connectable WebPart Problems......................?
and
Connection between 2 web parts
hope it helps :)
When you connect web parts you provide some information to Another Web part!
If they are on two different pages, you can use Query String to transfer information between Web Parts!
Below is an example of query string:
http://server-name/SitePages/DesiredPage.aspx?selectedId=1
So from Source Web Part you can do Response.Redirect(aboveUrl);
Now you can access it via code using Request.QueryString["selectedId"]
on the destination page web part!