Skip to main content

Questions tagged [custom-web-part-property]

The Web Part base class contains a set of properties that you and the users of your Web Part can use to control its appearance and behavior. For example, a Web Part's Height and Width properties can be set by your code, the user, or the Web Part definition file (.dwp) you use to import a Web Part. A custom property is a property that you create when you need additional properties to enhance your Web Part's functionality.

Filter by
Sorted by
Tagged with
1 vote
1 answer
227 views

Pass Array Values from webpart.ts to Main.tsx

I am fetching data from webpart.ts using this.properties.data and present it as list items in Main.tsx. However, It only displays as a string like Select Google rather than select Google What am I ...
Random I.T's user avatar
1 vote
1 answer
2k views

How do I get the selected value text(display name) from the web-part Property pane dropdown?

I have a Web-part that I would like to show a title on the component that is dynamically populated from the selected value from a property pane drop down. I am able to get the value from this....
J.Bigham's user avatar
0 votes
1 answer
24 views

Hide one of hosted app part from solution

I have developed a solution which have 20 SharePoint hosted app part. Now i want to hide one of the app-part from this hosted app solution, so that user can not see and add that one app part on page. ...
Dilip Kumar Yadav's user avatar
2 votes
0 answers
64 views

Unable to create custom Web part properties for custom content search web part in sharepoint 2013?

I tried to create custom web properties for custom content search web part Extended CSWPby using [WebBrowsable(true), WebDisplayName("Page Title"), WebDescription("Title displayed on the page"), ...
Debugger's user avatar
  • 1,722
2 votes
1 answer
898 views

Custom radio button property for SharePoint web part

I have created Custom property for string and drop down list . Currently I'm trying to create radio button custom web part property. Custom property name will be City 2 radio button will be Las ...
Akshay Dattatray Nangare's user avatar
2 votes
1 answer
243 views

Add same webpart multiple times on a webpage

I have a webpart i need to add multiple times on a webpage, how can I restrict in javascript the the variable to read from each webpart property? In webpart ascx file, I have hidden fields like: &...
Jennifer T's user avatar
1 vote
1 answer
67 views

Web Part with a Custom Tool Part error "Sorry this site is not shared with you”

I created Web Part with Custom Properties My issue is that only the admin profile can edit the properties Users with contributerole can't edit the webpart. He gets this error : Sorry this site is ...
Imen Turki's user avatar
  • 2,193
1 vote
1 answer
2k views

Populate Custom Web Part Property from List

I have a custom web part (Contact Info) with a property (Topic). The topic is a drop down list (ie behind the scenes its an enum type. What I would like is for the values of this dropdown property to ...
Neberu's user avatar
  • 178
3 votes
2 answers
2k views

Getting custom webpart property with JSOM

I have a webpart with a custom property setup like so: public static string TargetUrl; [WebBrowsable(true), WebDisplayName("My DisplayName"), WebDescription("My Description."), Personalizable(...
KidBatman's user avatar
  • 381
0 votes
1 answer
326 views

visual webpart custom properties not working

I am trying to create visual webpart custom properties but it is not appearing. my code: <?xml version="1.0" encoding="utf-8"?> <webParts> <webPart xmlns="http://schemas.microsoft....
abc's user avatar
  • 375
0 votes
2 answers
3k views

Create a custom dropdown in webpart property that loads values from a list

I want to create a custom webpart property which will be a dropdown list. and i want to load values from a sharepoint list. So far i could only find a way to provide static values for list contents. ...
mallu coder's user avatar
3 votes
2 answers
12k views

How to get web part id

This is a follow up question to the one i asked earlier : Reading web part properties using javascript object model In my earlier question I had been able to access the properties using jsom but i am ...
Tanmay's user avatar
  • 517
0 votes
0 answers
31 views

Things to lookout for, when adding a button to the properties menu of a webpart and even handler not executing

Ive built a custom Web Part properties menu, using a class which extends the Editor Part following this tutorial . I created a button with the following code this.testButton = new Button(); ...
user2987348's user avatar
3 votes
3 answers
4k views

Missing my custom webpart property, what did I miss in my code?

I am using SharePoint 2013. I developed a visual webpart in visual studio 2013. I have added this code in the code-behind of my webpart: public partial class VisualWebPart1UserControl : UserControl { ...
Ola's user avatar
  • 4,385
0 votes
1 answer
931 views

color picker in custom webpart properties

I want to have custom color picker in web part properties to let users select colors for headings. Any idea how to achieve this.
Rajeev K's user avatar
  • 331
2 votes
2 answers
2k views

Use a Managed Metadata Field as custom property of a WebPart

I'm trying to add a custom property to a WebPart to select multiple terms from a TermSet in SharePoint 2013. I have found this article: http://msdn.microsoft.com/en-us/library/dd584178(v=office.11)....
Kaethe's user avatar
  • 21
2 votes
2 answers
695 views

Web part custom properties are cleared after save - until page refresh

I have noticed a bug that occurs on all custom web parts I created. Let's assume I have following web part (sandbox solution) with two properties: using System; using System.ComponentModel; using ...
movax's user avatar
  • 172
1 vote
2 answers
1k views

Add RichtextBox editor in webpart properties

I have a requirement to add a rich text box in the custom properties of web part. Is it possible to add the rich text editor in custom properties of web part. The following links tells it is not ...
Sushri's user avatar
  • 425
3 votes
1 answer
697 views

Visual Web Part Property Validation in Sandbox Solution [SharePoint Online 2013]

How can I validate a custom web part property in a Sandbox solution (SharePoint Online 2013 environment)? I am throwing a WebPartPageUserException when validation fails, as shown below. private ...
Rachel's user avatar
  • 133
1 vote
2 answers
317 views

How to fetch all list titles in editor part of web part?

I want to fetch all the list titles of the current site in a dropdown in my web part's editor part. Based on this selection I want to show list items in web part when Apply is hit. My web part is ...
Sankalp Mishra's user avatar
0 votes
1 answer
781 views

Create Password Field in webpart properties

I have created a custom web-part. this web-part have a custom web-part properties. i want a Password field in this property. How can i do this ? Any help will appreciated ..
Vikalp Kapadiya's user avatar
2 votes
1 answer
513 views

Setting the value of a sandbox web part's custom properties in .webpart file

I've created a new web part in a sandbox solution. This web part has a custom string property called 'PetName'. I'd expect to be able to set the initial value of this property in the .webpart file. ...
user16537's user avatar
2 votes
2 answers
1k views

Question about webpart properties

How can I access a custom property in my webpart? I have a page that contains webparts, which contains multiple instances of the same custom webpart. I wanted to use the .webpart file to add my own ...
Ronen's user avatar
  • 119
0 votes
1 answer
68 views

WebPart Properties

I would like to manage my WebPart Properties. I would store an ID -> this id is the id of a configuration for my webpart. First: How can i Store it? Second: How can i Find it? I'm using the ...
roironm's user avatar
0 votes
1 answer
217 views

Custom webpart property with mutiple fields

I have written a web part that has 3 extra properties that are all related. Right now each has its own title & input field. Is there a way I could make it 1 title with 3 fields? I was not ...
user13186's user avatar
  • 886
0 votes
1 answer
297 views

Custom Web Part Properties in SharePoint 2010 Visual Web Parts-How to set it different for each user login

I have custom webpart properties for a visual webpart. This thread helped me develop the custom webpart properties. Now my issue is once a user sets the custom property it gets applied for all users, ...
Ishan's user avatar
  • 774
1 vote
0 answers
1k views

Custom Web Part Properties in SharePoint 2010 Visual Web Parts-Dynamic Dropdown

I want to have a custom webpart property with a dynamic dropdownlist (data coming from sharepoint list). I was able to make a static dropdownlist as mentioned here. Can anyone help me how to make a ...
Ishan's user avatar
  • 774
0 votes
2 answers
722 views

Does web part property validation only work for visual web parts?

Suppose I define a web part property like this: private string _myString = "default value"; [WebBrowsable(true), WebDisplayName("My string"), WebDescription("A simple bit of text to ...
Kenneth Van Coppenolle's user avatar
0 votes
1 answer
195 views

How Can I Have Multiple Editor Part Collections?

I have created a web part in SharePoint 2007 which has over 40 controls and I was able to make two different Tool Part classes to hold the different sections of the custom controls. I am converting ...
lazoDev's user avatar
  • 1,806
2 votes
1 answer
678 views

Pass Parameter to specific instance of Web Part with GetLimitedWebPartManager

I'm passing parameters to a WebPart from a textbox to have a better UI experience for a personalizable WebPart which in this case takes the form of a twitter feed. The problem I have, is in the ...
Wesley's user avatar
  • 707
2 votes
2 answers
1k views

sharepoint webpart property disappear after a day (C#)

I developed a custom webpart with a webpart property with some textboxes and it works partially. If I deploy the project, the written text in the property is away. This is ok. But my MAIN Problem is,...
grekko's user avatar
  • 47
0 votes
1 answer
91 views

Add web part properties in separate file

I am developping a web part that customizes the SharePoint Ribbon (hide or show buttons). Can I store some properties in a separate file? If the web part is active on three sites, I should have three ...
Joey Lemmens's user avatar
2 votes
2 answers
488 views

Webpart with custom properties - cancel does not work

I have implemented a webpart with custom properties in an editor part. If I click apply or ok, the values are successfully updated (code in OnPreRender). The problem is now that if I click apply and ...
Mel's user avatar
  • 23
2 votes
2 answers
2k views

Custom webpart to set and get Property per user (PersonalizationScope.User)

I am trying to create a custom webpart in point to set and get a property per user on page. To change the background and save it per user. I'm using code like this: public static string SampleColor=...
Hassan's user avatar
  • 21
0 votes
2 answers
291 views

Does webpart property validation code execute every page load

I have a custom webpart with custom webpart property. I have created a complex validation in the property. My question is, does this validation execute on every page load or happens only when ...
Hojo's user avatar
  • 167
0 votes
1 answer
1k views

Set web part custom property when adding to page from code

We have a solution that adds All Assignments Web Part from Sharepoint Learning Kit into a page. Here are code snippets we use to do that: public static string AddWebPartToPage(SPWeb web, string ...
jjczopek's user avatar
  • 1,547
3 votes
1 answer
380 views

Custom SearchPage in SearchBoxEx Control

I was pushed to replace the default search box in a site collection with a customized one. At the moment it looks like this: <Elements xmlns="http://schemas.microsoft.com/sharepoint/"> <...
Smokefoot's user avatar
  • 310
3 votes
2 answers
762 views

Is it possible to swap out urls pointing to MySite with urls to custom pages?

We've developed a custom userprofile page for a costumer. This page is supposed to be linked to by all default sharepoint buttons and links pointing to the MySite. One example is the SharePoint ...
user avatar
3 votes
2 answers
2k views

Is it possible to access the web part properties from a dialog?

In my web part I use the create_DialogOptions JS function to create a new aspx site as a dialog box. That works fine. Now I would like to have access to the custom properties from the web part. I ...
user avatar
1 vote
2 answers
3k views

Custom properties in XSL

Is it possible to pull the value of a property, from a web part into XSL? I need to build something similar to the standard Summary Link Web Part, but would like to extend the default control with ...
JadedEric's user avatar
  • 523
2 votes
2 answers
2k views

How to Show the loading message

i am working on a custom web part where i have a few dropdowns in the tool pane so it take a while to load the dropdownlist and i have total three dropdownlist... i need to show the Loading message ...
Nick Kahn's user avatar
  • 531
2 votes
1 answer
936 views

PageViewer setting Height/Width

i am creating a dynamic Page Viewer web part from the user control code behind .. something like this: PageViewerWebPart oWebPart = new PageViewerWebPart(); oWebPart.ContentLink = WebPart....
Nick Kahn's user avatar
  • 531
4 votes
1 answer
12k views

Setting default value for custom webpart property

im trying to set a DefaultValue for my custom webpart property.. namespace Beraterprofil.VisualWebPart1 { [ToolboxItemAttribute(false)] public class VisualWebPart1 : WebPart { ...
Peter's user avatar
  • 575
0 votes
2 answers
108 views

MSDN example scenario

I am working with the MSDN example scenario creating creating a custom web part. Can anybody tell me why is it showing the square bottom div below (see in the image). It says "Bottom" and it ...
Nick Kahn's user avatar
  • 531
1 vote
1 answer
212 views

Changing WebPart Custom Property

I want to change a string inside my Code using the customization for the WebPart. Currently I created a custom WebPart Property like this: [WebBrowsable(true), Category("Miscellaneous"), ...
Peter's user avatar
  • 575
1 vote
3 answers
8k views

Sharepoint 2010 and Saving variables in VIEWSTATE

UPDATE1 I tried with EnableViewState in Page directive: but no avail. End I am running as a usercontrol in sharepoint. (using SmartPart) Everything's fine. Just the Viewstate-Variables! The ...
Nick Kahn's user avatar
  • 531
0 votes
1 answer
675 views

how to access or have reference using web parts?

public partial class VisualWebPart1UserControl : UserControl { public string SetId{ get; set; } protected void ddl_SelectedIndexChanged(object sender, EventArgs e) { SetId = ddl....
Nick Kahn's user avatar
  • 531
0 votes
3 answers
4k views

SP 2010 The maximum number of Web Parts for all zones on this page has been exceeded

I am developing SharePoint web parts and as soon as I click on the left navigation to add a web part to the page I get the below error. I am using SP 2010 VS 2010 Server Error in '/' Application. --...
Nick Kahn's user avatar
  • 531
4 votes
2 answers
29k views

A Web Part or Web Form Control on this Page cannot be displayed or imported

I'm working on Create a Custom Web Part i'm able to do a build and run the new project in debug mode. However, after trying to add the new web part to the site, I get the following error. "A Web Part ...
Nick Kahn's user avatar
  • 531
1 vote
2 answers
2k views

custom editor web part - disappears other property

Update: protected override void CreateChildControls() { // autopostback ddlTopic = new DropDownList { CssClass = "...
Nick Kahn's user avatar
  • 531