<div dir="ltr">It works!<div>Many thx<div>c</div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Il giorno lun 2 mag 2022 alle ore 16:28 bb <<a href="mailto:adamnt42@gmail.com">adamnt42@gmail.com</a>> ha scritto:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Mon, 2022-05-02 at 16:20 +0200, Charles Bukowski wrote:<br>
> Hi, I am a new gambas user and I have just installed the current<br>
> stable ide<br>
> release which is 3.17.2.<br>
> I am trying to show a "message box" when clicking on a button inside<br>
> the<br>
> form main () using comp â€¢ gb.qt4 â€¢ message class .<br>
> this message box must show a text inside and a title.<br>
> Compilation is successful, but at runtime I get "Type mismatch :<br>
> wanted<br>
> _BoxedString, got string instead" at the source code line that sets<br>
> the<br>
> property "title".<br>
> I have checked documentation at<br>
> <a href="http://gambaswiki.org/wiki/comp/gb.qt4/message/title" rel="noreferrer" target="_blank">http://gambaswiki.org/wiki/comp/gb.qt4/message/title</a> and that<br>
> property<br>
> datatype is a normal string.<br>
> <br>
> Here my code :<br>
> Public Sub Button1_Click()<br>
> Dim a As String<br>
> a = "teststring"<br>
> Print a<br>
> Â  Message.Title(a)  ------>  error Type mismatch : wanted<br>
> _BoxedString, got<br>
> string instead<br>
> Â  Message.Info(a)  -------> printed correctly<br>
> End<br>
> <br>
> I have attached my current environment configuration.<br>
> What's wrong?<br>
> Thank you<br>
> <br>
> ----[ <a href="http://gambaswiki.org/wiki/doc/netiquette" rel="noreferrer" target="_blank">http://gambaswiki.org/wiki/doc/netiquette</a> ]----<br>
Use Message.Title = a<br>
Message.Title is a property<br>
<br>
hth<br>
b<br>
<br>
<br>
----[ <a href="http://gambaswiki.org/wiki/doc/netiquette" rel="noreferrer" target="_blank">http://gambaswiki.org/wiki/doc/netiquette</a> ]----<br>
</blockquote></div>