Click here to Skip to main content
12,702,933 members (32,752 online)
Rate this:
 
Please Sign up or sign in to vote.
See more: C#
Hi,

We have a website, to which we can add webparts like title bar, footer, left navigation and content etc....by dragging them to the page after the login.
But the customer requirement is to have some default webparts on the page layout after login for the first time instead of looking at a blank page .

I understand the aspnet_PersonalizationAllUsers and aspnet_PersonalizationPerUser stores the info abt the webparts

Can you please help me in understanding where exactly and how the added webparts info by bragging to webpage will be stored. And can we automaticaly add the webparts to the page programatically and save them?

Regards,
Uma.A
Posted 12-Nov-12 7:32am
Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 2

Hi Tapan,

Thanks for replying .

we are not using the share point.

But, now i undertsand that,the saved webparts to a page will be stored in the table's aspnet_Applications,aspnet_Paths,aspnet_PersonalizationAllUsers & .aspnet_PersonalizationPerUsers.

And it uses aspnet_PersonalizationAllUsers_SetPageSettings for storing the webparts information for an application.which takes applicationname,path,pagesettings and currentdatetime as inputs and set the pagesettings to the page(adds the defaults webparts we want to add).

Now, i want to run this storedparocedure to add some default webparts to my homepage through c# .net.
But,for Pagesettings, which is a 'image' datacolumn in SQL,i need to send pagesettings data as byte[] through C# .net

but the pagesetting value(which i got from aspnet_PersonalizationAllUsers_GetPageSettings) is like below.How can i convert it to byte[] and pass to the storedprocedure 'aspnet_PersonalizationAllUsers_SetPageSettings' thorugh C#??

Can you please able to help me to do this?

0xFF01142B000E02020201192A3153797374656D2E5765622E55492E576562436F6E74726F6C732E57656250617274732E576562506172744D616E6167657205055F5F77706D6602021E12576562506172745374617465536861726564142B0010051D777031393633353838333232436F6E666967757261626C655469746C6505095469746C655A6F6E656668051D777031303838383434303335566572746963616C4C696E6B734C697374050B4C6566744E61765A6F6E6566680518777035313734393230343047656E6572616C536561726368050B436F6E74656E745A6F6E65666805117770333935363834393937466F6F746572050A466F6F7465725A6F6E65666867681E1544796E616D69635765625061727473536861726564142B0010051D777031393633353838333232436F6E666967757261626C655469746C650537494349536F6C7574696F6E732E4B77696B576F726B4250462E5765622E57656250617274732E436F6E666967757261626C655469746C656464051D777031303838383434303335566572746963616C4C696E6B734C6973740537494349536F6C7574696F6E732E4B77696B576F726B4250462E5765622E57656250617274732E566572746963616C4C696E6B734C69737464640518777035313734393230343047656E6572616C5365617263680533494349536F6C7574696F6E732E4B77696B576F726B4250462E5765622E57656250617274732E47656E6572616C536561726368646405117770333935363834393937466F6F746572052C494349536F6C7574696F6E732E4B77696B576F726B4250462E5765622E57656250617274732E466F6F74657264646768

Regards,
Uma.A
  Permalink  
Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 1

Hi,
Are you using sharepoint or something else, please tell, so that I can help you out

Thanks
Tapan kumar
  Permalink  
Comments
umasrilakshmi 15-Nov-12 12:13pm
   
Hi Tapan,

Thanks for replying .

we are not using the share point.

But, now i undertsand that,the saved webparts to a page will be stored in the table's aspnet_Applications,aspnet_Paths,aspnet_PersonalizationAllUsers & .aspnet_PersonalizationPerUsers.

And it uses aspnet_PersonalizationAllUsers_SetPageSettings for storing the webparts information for an application.which takes applicationname,path,pagesettings and currentdatetime as inputs and set the pagesettings to the page(adds the defaults webparts we want to add).

Now, i want to run this storedparocedure to add some default webparts to my homepage through c# .net.
But,for Pagesettings, which is a 'image' datacolumn in SQL,i need to send pagesettings data as byte[] through C# .net

but the pagesetting value(which i got from aspnet_PersonalizationAllUsers_GetPageSettings) is like below.How can i convert it to byte[] and pass to the storedprocedure 'aspnet_PersonalizationAllUsers_SetPageSettings' thorugh C#??

Can you please able to help me to do this?

0xFF01142B000E02020201192A3153797374656D2E5765622E55492E576562436F6E74726F6C732E57656250617274732E576562506172744D616E6167657205055F5F77706D6602021E12576562506172745374617465536861726564142B0010051D777031393633353838333232436F6E666967757261626C655469746C6505095469746C655A6F6E656668051D777031303838383434303335566572746963616C4C696E6B734C697374050B4C6566744E61765A6F6E6566680518777035313734393230343047656E6572616C536561726368050B436F6E74656E745A6F6E65666805117770333935363834393937466F6F746572050A466F6F7465725A6F6E65666867681E1544796E616D69635765625061727473536861726564142B0010051D777031393633353838333232436F6E666967757261626C655469746C650537494349536F6C7574696F6E732E4B77696B576F726B4250462E5765622E57656250617274732E436F6E666967757261626C655469746C656464051D777031303838383434303335566572746963616C4C696E6B734C6973740537494349536F6C7574696F6E732E4B77696B576F726B4250462E5765622E57656250617274732E566572746963616C4C696E6B734C69737464640518777035313734393230343047656E6572616C5365617263680533494349536F6C7574696F6E732E4B77696B576F726B4250462E5765622E57656250617274732E47656E6572616C536561726368646405117770333935363834393937466F6F746572052C494349536F6C7574696F6E732E4B77696B576F726B4250462E5765622E57656250617274732E466F6F74657264646768

Regards,
Uma.A

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month


Advertise | Privacy | Mobile
Web02 | 2.8.170118.1 | Last Updated 15 Nov 2012
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100