1 (edited by thezimguy 2020-03-22 20:48:15)

Topic: Possible Bug

Hello Dmtry,
Please check this for me

1. Why does the form shown with action: "Show Form" not loose data on form close?
2. The sqlValue of an Edit comes within quotes when the form is shown with action : "Show Record"
Thank you.

@thezimguy

Re: Possible Bug

1. Action "ShowForm" just makes form visible. May be you should use action "NewRecord"


2. Unfortunately, I can't figure out what the relationship is between "Show Record" and sqlValue

Dmitry.

Re: Possible Bug

thezimguy,
If I may put my little tidbit of information here as my understanding of the two items you mentioned.


1) The ShowForm, as Dimitry said, only shows the form. It is not meant to be a data entry type form UNLESS you manually populate the fields and do your own saves and clearing of the fields. If you enter data into the fields and don't clear them, they will remain present for the duration of the program. So every time you show the form the fields will remain populated unless you clear them through script.


2) Typically SqlValue is used inside SQL (SqlExecute) statements. At least that's all I ever used it for. For text type fields it places the quotes around the string for you otherwise if you use the TEXT attribute of a field (Form1.edit1.Text) inside the SQL statement, then you need to place the quotes around yourself. Also, this works the same whether you are on ShowForm or ShowRecord.


Hope this helps.