octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #59620] Matlab script error in Octave


From: Arve F
Subject: [Octave-bug-tracker] [bug #59620] Matlab script error in Octave
Date: Fri, 11 Dec 2020 03:54:13 -0500 (EST)
User-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:83.0) Gecko/20100101 Firefox/83.0

Follow-up Comment #9, bug #59620 (project octave):

Thanks, Pantxo. I found the run.m and uicontrol.m function files and am trying
to separate the creation and property modification. When I do that I receive
the following error message:

'error: set: invalid string property value for "string"
error: called from
    OpenPropSingle at line 701 column 8
    run at line 93 column 5
    openprop at line 59 column 1'

The property value for "string" is set to 'Js_def'.
Js_def = Vs_def/(n_def*D_def); 

Here all input parameters are numeric. Is this perhaps causing the problem?

[comment #6 comment #6:]
> @arve_v: You should separate the creation and property modification in your
script so that you can see which one is causing problems. Something like:
> 
> 
> Values(1)   = uicontrol (Calculator, 'style', 'edit');
> 
> set (Values(1), 'units', 'characters','string', Js_def,...
>      'position',[cavtextbox-4, Valuesboxht-4, editbox, editboxht], ...
>      'backgroundcolor',[1 1 1], 'enable','off'); 
> 
> 
> BTW, if you want to locate a function file, like run.m or uicontrol.m, just
type "which uicontrol" at the prompt. This won't help here since the error
happens in a buit-in compiled function, not in uicontrol.m.
> 
> @Markus: I'll push a change along those lines, to obtain a more informative
error message:
> 
> 
> diff -r fbfa420380e3 libinterp/corefcn/graphics.cc
> --- a/libinterp/corefcn/graphics.cc     Sun Dec 06 20:34:37 2020 +0100
> +++ b/libinterp/corefcn/graphics.cc     Thu Dec 10 11:29:35 2020 +0100
> @@ -13228,8 +13228,8 @@
>      }
>    catch (octave::execution_exception& e)
>      {
> -      error (e, "__go_%s__: unable to create graphics handle",
> -             go_name.c_str ());
> +      error (e, "__go_%s__: unable to create graphics handle, %s",
> +             go_name.c_str (), e.message ().c_str ());
>      }
>  
>    try
> @@ -13239,8 +13239,8 @@
>    catch (octave::execution_exception& e)
>      {
>        delete_graphics_object (h);
> -      error (e, "__go_%s__: unable to create graphics handle",
> -             go_name.c_str ());
> +      error (e, "__go_%s__: unable to create graphics handle, %s",
> +             go_name.c_str (), e.message ().c_str ());
>      }
>  
>    adopt (parent, h);
> 
>  some property/value pairs in your script to wee which one is the offending
one

    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?59620>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]