Cancel
Showing results for 
Search instead for 
Did you mean: 

Custom UI Builder Add/Delete/Copy Button

Valued Contributor
Valued Contributor

 

Capture.JPGIs there a way to disable each of these buttons individually?

 IE. Disable Add or Disable Copy or Disable Add and Disable.

 

 

 

4 REPLIES
Highlighted

Re: Custom UI Builder Add/Delete/Copy Button

Valued Contributor
Valued Contributor

Hi Bob,

 

Hope you are doing well - it's been a long time!!!

 

You can definitely drive the 'Delete' button using the 'Can Delete' attribute in CustomUI for this control. The 'Copy' can also be shown or hidden but it is static (can't drive its enable/disable feature using a property like you can for 'Delete'. Add will be enabled or disabled based on the subpart collection it is mapped to.

 

And of course, the other way to do it is use your own separate button for these 3 functions and drive them individually.

 

I know this is an old post and you've found the solution that works for you but just wanted to leave it out there for future reference.

 

Dharmesh

Re: Custom UI Builder Add/Delete/Copy Button

Valued Contributor
Valued Contributor
Thanks Dharmesh.

Robert J. Mattern
Supervisor, Model Based Enterprise Team

The Babcock & Wilcox Company
20 S. Van Buren Ave
Barberton, OH 44203
PhoneSmiley Sad330) 860-1075
Cell: (234) 571-7320
Email: rjmattern@babcock.com
Web: http://www.babcock.com



----------------------------------------- This message is intended only for the individual or entity to which it is addressed and contains information that is proprietary to The Babcock & Wilcox Company and/or its affiliates, or may be otherwise confidential. If the reader of this message is not the intended recipient, or the employee agent responsible for delivering the message to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please notify the sender immediately by return e-mail and delete this message from your computer. Thank you.

Re: Custom UI Builder Add/Delete/Copy Button

Experimenter
Experimenter

Hi DharmeshS,

 

I have an issue that is connected to this post. I am trying to figure out how to create my own action button that does exactly what the Delete button do, but without beeing bound to the triple button. I'm having a hard time figuring out a script in custom.vb that can remove, from the subpart connected to a grid, the selected part. Do you have any idea about how to do it? More generally speaking, is there a way to read the functions called by the default buttons in Custom UI?

 

Thanks

Re: Custom UI Builder Add/Delete/Copy Button

Valued Contributor
Valued Contributor

Hi Carico,

 

Yes, you can absolutely replicate the functionality of the individual buttons in ADD/COPY/DELETE combo...not only that but you can additional logic to those based on your unique situation. I am traveling now and don't have access to the exact snippet that removes a subpart but can you try this:

Dim _p As Object = <reference to some RS part object>

 

'remove the part from a subpart collection

_p.Owner.Remove(_p.ObjName)

 

The above code should do what you want. If it doesn't please let me know and I will find the correct code that does it.

 

Dharmesh