1,976

(1 replies, posted in Russian)

Здравствуйте,
Извинения - используя переводчик google!
Вот два способа изменить значение ячейки непосредственно в tablegrid без использования другой формы.
Первый способ использует кнопку, как вы задали в своем вопросе. Во-вторых, вы просто щелкаете по соответствующей ячейке в tablegrid (быстрее и интуитивно, я думаю).
Возможно, это поможет вам?
С уважением
Derek.

Hi Alex,
I'm afraid I'll have to pass on how to print the chart together with the data;  reporting is one of the areas that I'm pretty weak on (there doesn't seem to be much call for print-outs with the stuff that I'm asked to write). 
Feeble excuse, I know (LOL!) and I should take the opportunity to get up to speed but I think it would take me quite a while.
Maybe someone else who's worked more with charts/reports will have a few ideas.
Derek.

1,978

(19 replies, posted in Russian)

Здравствуйте,
Помогает ли вам этот пример?
Если я правильно понимаю вашу проблему, один простой способ ее решить - использовать рассчитанные поля.
Надеюсь, я объяснил это четко (используя переводчик google)
Derek

Hello Alex,
In the script, just add the line
  Chart.View3D:=false;   
You could actually remove the legend as well, as it is now simply repeating the information that displays against each slice of the piechart.  You can do that with the line. 
  Chart.legend.visible:=false;
Obviously, in some examples and with lots of 'slices' it starts to get a bit impractical, but it's something to bear in mind.
Both these options are in the attachment.
Derek.

Hi Alex,
Does the attached give you the sort of thing you're after (values and percentages with the legend)?
Regards,
Derek.

1,981

(3 replies, posted in Russian)

Здравствуйте,
Я не могу запустить проект, потому что вы используете удаленную базу данных.
Но одно я не понимаю -
on frmadmin, editklass определяется как tablename 'test' и fieldname '123', но в tablegrid2 он определяется как klass.nomera & litera
Возможно, это имеет какое-то отношение к вашей проблеме (см. Скриншот)
Извините, если это неясно - я использую переводчик Google.
С Уважением,
Derek.

Hello Kkalgidim,
I had a problem with your attachment so I made a small example for you to show you one way - there may be other ways too. 
Please look at the calculated fields to see how you can show orders that have not been paid (I have used 4 calculated fields - 1. all orders, 2. unpaid orders, 3. paid orders and 4. all of these combined.
If you just copy the code into your own application, I think you will be okay.  Please note that you need to add a line of script to refresh form1.tablegrid1 (your customer tablegrid) otherwise the changes to the calculated fields do not immediately display.
Let me know if there is any problem and I hope this helps,
Regards,
Derek.

1,983

(4 replies, posted in Script)

Hi Alex, Hi Jean,
You have a good memory Jean - I don't remember writing it - LOL!  But now you reminded me, I have managed to find it and add it to the attachment.
So, in the attachment are actually 2 examples using checkboxes.
The first example is more simple, using standard MVD with no script
The second example has a script to keep sub-totals and things like that and it uses a slightly different style / approach.
Personally, I find check boxes are okay if you have a small number of set alternatives (male or female, small, medium, large - that sort of thing).  Also, it can get a bit confusing if you have more than a couple of checkboxes and they 'allow grayed' as well.
If the options are more numerous or liable to change, then I'd probably go with comboboxes.  But it really depends on the application.
Hope this helps but if not, get back with some more details about what you're trying to do and I'm sure someone can give you some ideas.
Regards,
Derek

1,984

(3 replies, posted in General)

Hi Dmitry,
My understanding was that raggedright would equally space out the tabsheet labels even if it there was only a single line. 
It's not a problem - I can just adjust the tabsheet labels by filling them out with blank space.
Thanks,
Derek.

1,985

(3 replies, posted in General)

Hi Dmitry,
I have been trying to set the 'raggedright' property = true for a PageControl object but it is making no difference.
Is there anything else that needs to be set at the same time?
I'm using MVD 3.5
Thanks,
Derek.

1,986

(11 replies, posted in Russian)

Привет Антон.
Извините за задержку.
Исходный запрос не просил превысить более 1 дня.
Теперь я изменил его, чтобы использовать 2 datepickers и 2 timepickers.
Делает ли это сейчас то, что вам нужно?
Regards,
Derek.

Hi There,
If I understand you correctly, then yes, it's possible.
Please have a look at the attached.
There is a bit more to the script than is necessary to cover your question but it addresses a couple of extra scenarios.
Using the example in the attachment
1.  When a student record is created, a .txt file gets automatically created (using the student's name as the file name).
2.  The contents of the .txt file are displayed within a memo field on Form 2.
3.  The contents of the .txt file can be edited within MVD and the changes written back to the .txt file.
4.  The contents. of the .txt file can, as usual, still be edited outside of MVD.
Please note that memo fields only support .txt files so if you want to preview anything else (ie with formatting, with pictures etc), then the better option is to make external calls (ie the call is made from within MVD but you preview it outside of MVD).
Hope this helps,
Derek.

1,988

(4 replies, posted in General)

Hi Asirotenko555,
If you can upload your project, I'm sure someone in the forum will be able to have a look and let you know what the problem is / how to fix it.
Derek.

1,989

(3 replies, posted in Script)

Hi Vasco,
I believe there are Delphi commands 'sendtoback' and 'bringtofront' but I don't think they are supported in MVD.
When I want to bring objects to the front (either completely (so one object totally hides the other) or partially overlapping (so both objects remain visible at the same time)), I make the objects visible / invisible as required.  Perhaps there are other ways as well.
Please see the attached as an example (click on the various coloured boxes to see them change).
Maybe this helps,
Derek.

1,990

(3 replies, posted in Russian)

Hello Asirotenko,
Вам необходимо распространять все файлы в папке, содержащей ваше приложение, а не только .exe.
Возможно, это твоя проблема?
С Уважением,
Derek.

1,991

(11 replies, posted in Russian)

Здравствуйте,
Это то, что тебе надо?
Сценарий не очень хорош, но он работает!
Возможно, Дмитрий знает лучший способ.
Надеюсь, поможет.
Derek.

возникла проблема при использовании кнопки «поиск» - теперь исправлено.

1,992

(7 replies, posted in Russian)

Здравствуй,
Посмотрите на приложение.
Вам нужно добавить дополнительные кнопки поиска, по одному для каждого подчиненного стола. Я сделал это для «событий» в качестве примера.
Кроме того, добавьте новую строку в сценарий, чтобы щелкнуть каждую новую кнопку.
Надеюсь, вы поймете - с помощью переводчика Google.
С Уважением,
Derek

1,993

(11 replies, posted in Russian)

Здравствуй,
Это показывает часы и минуты. Также вы можете сделать это либо с вычисленными полями, либо со сценарием.
С Уважением,
Derek.

1,994

(11 replies, posted in Russian)

Здравствуй Antongusevv,
Помогает ли это? (пожалуйста, посмотрите приложение)
Я использую вычисленное поле, но вы также можете использовать скрипт.
С Уважением,
Derek.

1,995

(2 replies, posted in SQL queries)

Hi,
I would do it this way (by script rather than sqlquery - see attached) but there are probably a few other ways too.
Regards,
Derek.

1,996

(3 replies, posted in Russian)

Здравствуй,
Вы связали объект monthcalendar1 с таблицей и именем поля, которое содержит дату? Возможно, это проблема.
См. Прилагаемый файл.
С уважением,
Derek.

1,997

(8 replies, posted in General)

Hi Tony,
With projects like yours that I've done before (3 tier hierarchy - customers - appliances - results), I've often been asked for a 'total view' all on one screen.  It might be of interest to you so I've added this sort of view to your project.  It's not as 'seamless' as it should be because I didn't want to mess up your existing project too much, but I hope you get the idea.
I've also created a calculated field on each table to do 'free format' searches (users often don't know which field they might have put data into!). so rather than have multiple discrete search fields, they can just type anything in to one search and it scans across all fields (hope that makes sense).  For example, in the 'appliance' search, you can enter maker or model or serial no' or location etc etc.
All of the above can be done without using a script (although I've added a few lines, just to automate things and make it more user-friendly).
Hope it helps,
Derek.

1,998

(8 replies, posted in General)

Hi Tony,
Just checked on your original attachment and on my subsequent attachments and I can't see how the combobox on the appliance search form would have ever been filled with the customer details.
Not sure that's the best way to do it anyway though because, as I understand it,  it presupposes that the user knows what customer the appliance belongs to and I wonder if that is actually the case.  If I have a bit of time, I can mock up some other ways of doing it if that would be of any use to you - or at least give you some more ideas.
The tabbed form is done by dropping the 'page control' object onto a form;  you can then add as many 'tabs' (tabbed sheets) as you want.  Depending on your application, it can be a useful way to present the data.
Regards,
Derek.

1,999

(8 replies, posted in General)

Hi Tony,
I use a free utility called SQLiteStudio. 
Once downloaded and installed, if you click the sqlite.db that gets created when you first run your application, it opens in sqlitestudio showing all the structures, indexes etc. 
Among many features, there is, for each table, a data view and that is where you can see the 'raw' data and how the relationships between tables are being maintained (or not!).  I find it very useful for tracking down problems (the clue is almost always in the data!!), but it also gives you a much better understanding of how MVD actually hangs together and what it's doing 'behind the scenes'.
Using SQLiteStudio, it was very easy to spot that the relationship between 'test' and 'customer' wasn't being maintained.  I referred to the appliance table to find out the correct customer id for each appliance and then went back to the 'tests' table and manually copy and pasted in the missing keys (it's actually a lot more straightforward than it sounds!)..
If you don't want to use SQLiteStudio, you can also do a 'datacheck' yourself within MVD - please have a look at the attachment where I've added a 'datacheck' button to your main screen.   It's a quick and easy way to 'sight-check' your data and if you make your 'datacheck' tablegrids editable, you can fix the problem there and then. 
When you're happy with the quality of the data (typically just before you roll your application out), you can then delete the datacheck form and button (although I tend to just make the button invisible so that the facility is always there in case of future problems).
Hope all of that makes sense,
Regards,
Derek.

2,000

(8 replies, posted in General)

Hello TC,
You are right - you could manually maintain the links with comboboxes but basically, MVD takes care of that side of things for you if you've set up your data structures and your forms in the correct way.
Taking your example, if you have a form with a specific customer on it and a tablegrid listing all the appliances for that customer, when you click to add a new appliance, it automatically 'relates' the new appliance record with that customer.  Similarly, you have a form with the details of a specific appliance and a tablegrid of test resutls, so when you add a new test result, it automatically 'relates' the new test result with that appliance.
A couple of things to note - all this presupposes your data structure is correct and that your tablegrids are either set up to show 'child records' or filled using a 'search' action (otherwise you will see ALL records irrespective of the customer or irrespective of the appliance).
Your 'businessinfo' form on your original post didn't have a tablegrid to display appliances on it so (for the reasons outlined above), it wasn't able to 'relate' the relevant customer to appliances correctly.  As a result of that, you had a lot of records that had a 'null' value in appliance.id_customer.  I went through them and added them all in but you might want to have a check (if this is real data that you are intending to use).  Likewise, I created a few new records to test my changes (which I've left in for you to see) that you'll want to delete.
Haven't had time to test it thoroughly as I'm on my way out, but if there's anything I've done that's not clear, please get back..
Regards,
Derek.