576

(10 replies, posted in General)

+1 smile

577

(9 replies, posted in Script)

Thank you Dmitry for fixing my project beyond expectation. You rock!

there was a little mistake in the script, this is how it has been fixed:


procedure Form1_GridTop_OnCellClick (Sender: string; ACol, ARow: Integer);
begin
    if Form1.GridTop.Cells[9,ARow]='Yes' then
        Form1.bottom_grid.dbPopupMenu.Items[0].Enabled:= False
    else Form1.bottom_grid.dbPopupMenu.Items[0].Enabled:= True;
end;

578

(9 replies, posted in Script)

Project sent by email, thanks in advance Dmitry.

579

(9 replies, posted in Script)

When I say it does not work, I mean that even with your script, I still can edit the value of a row in bottom grid using double click which should not be the case smile

It makes no difference in short.

580

(9 replies, posted in Script)

Unfortunately it does not work, column 9 is a Boolean value.

581

(9 replies, posted in Script)

Hi,

yes I want to disable editing by double click on bottom grid if a column in top grid is contains a certain value.

I do not understand your script, could you explain please?

http://myvisualdatabase.com/forum/misc.php?action=pun_attachment&item=1409

582

(9 replies, posted in Script)

Hi all,

Is it possible to disable edit function in a result grid if a condition is met?

e.g: I have 2 grids: "top" and "bottom" and it is possible to edit the records in each grid

"bottom" grid results are based on "top" grid results

I would like to disable edit on bottom grid if result of top grid match a condition(Boolean column) so it would not be possible to edit the data.

583

(3 replies, posted in Script)

Oh, is that simple as that? smile



I used this script

procedure Form1_OnShow (Sender: string; Action: string); 
begin
if Form1.Checkbox1.Checked then Form1.color := $003333FF else Form1.color:= $00FFCC99; 
end;

Works like a charm

Thanks Derek

584

(3 replies, posted in Script)

Hi all,

does anyone knows if it is possible to change the background color of a form according to the status of a checkbox?

e.g: I have an edit form with a default blue background and if one specific checkbox if ticked, I would like the background to change to red

585

(2 replies, posted in General)

Great, thanks Dmitry. Super fast as usual smile

You should implement an answer scoring on your forum wink

586

(2 replies, posted in General)

Is there a way to set the alignment of a column content in a grid? I would like to center some of them and align to the right on others without too much script if possible smile

587

(30 replies, posted in General)

Sounds good for the future!! A multiplatform easy way to develop database application, thumbs up!

588

(24 replies, posted in General)

It works perfectly thank you, I even have the "bubble text" when hovering the mouse on the result grid when the text is too long smile

This is the magic line

ADD_switch.Descript1.Clear;

589

(24 replies, posted in General)

Ok I see, we do not use it the same way smile

I actually use the memo component to be able to write a multiline comment with clear view on what is being written, then I click on "Save Maintenance", it records all entries in a table "Maintenances" using scripts shown below. When opening back the form for the same switch (show record) last entry remains.

// Save maintenance into separate table
procedure ADD_switch_Button1_OnClick (Sender: string; var Cancel: boolean);
begin

   SQLExecute ('INSERT INTO maintenances (Hostname,Description,DateMaint,IMAC,MAC_ADDRESS) VALUES ('+ ADD_switch.hostname_add.sqlValue+','+ADD_switch.Descript1.sqlValue+','+ADD_switch.DateMaint.sqlDate+', '+ADD_switch.IMAC.sqlValue+','+ADD_switch.mac_add.sqlValue+' )');

    ADD_switch.Close;

end;


// Display maintenances related to current Switch

procedure ADD_switch_OnShow (Sender: string; Action: string);
var
    sSW_ID: string;
begin
    sSW_ID := ADD_switch.mac_add.sqlValue; // get current MAC Address

    ADD_switch.MaintHistory.dbSQL:='SELECT Hostname, MAC_ADDRESS, Description, strftime("%d.%m.%Y" ,Datemaint), IMAC FROM Maintenances where MAC ='+sSW_ID+;
    ADD_switch.MaintHistory.dbListFieldsNames :='Hostname,Details Maint,Date Maint, IMAC';
    ADD_switch.MaintHistory.dbSQLExecute;
end;

590

(2 replies, posted in SQL queries)

This might be a good starting point: http://myvisualdatabase.com/forum/viewtopic.php?id=92

591

(10 replies, posted in General)

This might be possible using a parameter form in your application. You would have to replace 'c:\Test' by a SQL query like for a variable I guess. Master Dmitry may have a better idea, though big_smile

592

(24 replies, posted in General)

The component is not cleared until I restart the application, you could easily try it yourself smile

To clear it, I must exit my application and restart it? I am using 2.03 alpha.

593

(35 replies, posted in Script)

This is an issue I already raised for encrypted database, the script files are readable with password not being encrypted. It would be better in a future release to embed the scripts into the ".exe". Doing so, it would be harder to hack the database.

Playing with anchor does not work that well, I already tried it and most of the time the full UI is totally messed up when trying to resize to a smaller screen.

I had to entirely re-design my UI to fit small screens...

595

(24 replies, posted in General)

Any news for a true multiline textbox component?

I need to support multiline entries in my project and I struggle to get it working properly. When designing I can draw a very nice big textbox which reduces automatically to 1 line when starting the application.

I tried to use memo instead but it retains latest entry every time I display the edition form without closing the application on same record. Is there a way to at least clear the memo component when closing the form?

http://myvisualdatabase.com/forum/misc.php?action=pun_attachment&item=1396

Hello Dmitry,

thanks for fast reply, this is kind of an intricate solution but as long as it works smile


And it works actually big_smile

Hi everybody,

I know how to perform what I am looking for using a SQL Query but I wonder if there would be an easier way to do it using only MVDB internal engine.

In one of my project, I have a table which must contain 2 columns with different values but using a "dictionary table" to avoid data redundancy and I would like to display the value instead of the "id" in my query (see attached picture).

For instance, my table "Ports" has id_VLANS and id_VLANS1 referring both to table VLAN but I cannot figure out how to display the proper VLAN_ID for each using default tools. To do so, I would need a "join" feature in the properties...

The idea is to display only the VLAN_ID for id_VLANs and id_VLANS1.

This project is developed using 2.03 alpha.


http://myvisualdatabase.com/forum/misc.php?action=pun_attachment&item=1394

598

(30 replies, posted in General)

I would recommend to export the data from your current project using SQLite Studio and import them into Mysql using MySQL tools.

599

(5 replies, posted in Script)

Of course, use Combobox component and enter manually the name of your table or select the foreign key.

600

(8 replies, posted in FAQ)

Great, this is simple control but how do you manage the error when at least one of the entry already exists, I would like to know what is groing wrong.

For instance, I want to detect duplicates on whichever column and also wrong csv format (people forget sometimes to remove the headers) to display appropriate error for easy remediation.