Effacer les filtres
Effacer les filtres

Character's usage for parameter callbacks doesn't allow using the | character inside a string : It can be a bug on Matlab 7.8 (R2009a)?

1 vue (au cours des 30 derniers jours)
Hello everyone,
I'm working on a masked block, when I try to associate this command to a mask parameter callback http://www.mathworks.nl/help/toolbox/simulink/slref/f23-18517.html
set_param(gcb,'MaskPromptString','Ninputs|Summary|Toggle to negative sign the input IN1?|Toggle to negative sign the input IN2?|')
and click on apply. I have this popping up error message shows up:
for mask parameter 1 contains a '|' character, which conflicts with the character's usage as a delimiter between mask callbacks. Replace the boolean expression containing the '|' character with a matlab 'or' command e.g. 'a|b' with 'or(a,b)'
And that is very weird because I'm not doing any logical operation. Is that a bug? Do you know if it's possible to overcome this problem or if I can achieve my aim, in a different way?
I saw the MaskPropmts parameter but I'm very confused about how to use the cell variable
thanks 4 reading
a good day

Réponse acceptée

grapevine
grapevine le 14 Mai 2012
finally guys I wrote this code
set_param(gcb,'MaskPromptString','Ninputs|Summary|Toggle to negative sign the input IN1?|Toggle to negative sign the input IN2?|')
I put this code within a m file call it in the dialog callback
it looks like it's working
I'm going to test it
  2 commentaires
Walter Roberson
Walter Roberson le 14 Mai 2012
That looks to me like the same as above? I'm not sure what you changed?
grapevine
grapevine le 15 Mai 2012
I just wrote this code inside a m file then I made a reference to it inside the dialog callback
set_param(gcb,'MaskPromptString','Ninputs|Summary|Toggle to negative sign the input IN1?|Toggle to negative sign the input IN2?|')
before, this code was directly inside the dialog callback.

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Author Block Masks dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by