Topic: calculate sum of project events

I have 2 table
Project and event

Project has many events

Project table has totalincome field

Event table has income field

I want to sum all the events income of that project

I can do it on events table with grid settings sum for footer but i cannot do it on project table. How can i do it?

I shoulf say that goto this project events and sum all the income and put it project table`s totalincome field

Re: calculate sum of project events

Hello


Please attach your project (zip)  to the topic (without exe and dll)
I'll try to help you.


Merry Christmas! )

Dmitry.

3 (edited by kkalgidim 2014-12-26 14:17:11)

Re: calculate sum of project events

i find the correct sql to do that but now my db table not let me adding new field.
i am sending you project. Look at the "proje"  table its not let me add new field

2. Question: Is it possible to remove about button on application? Or just remove myvisualdatabase name on it?

3.Question:  How to refresh grid on Form1 after click on "kapat" (close form) button on frmYeniProje?
i want to refresh it because grid not update new calculated value if i dont refresh grid.

Post's attachments

Attachment icon Proje Takip Yedek.rar 8.41 kb, 915 downloads since 2014-12-26 

Re: calculate sum of project events

I fixed the problem on question 1 which table not let adding new field. After i recreated db it fixed.
I am still waitng to find a solution for question 2: about button removal and question 3: refreshing table grid for see updated vules

Re: calculate sum of project events

kkalgidim
Sorry for delay.


You can do it, using a script.
Please, download your the fixed project here:

Post's attachments

Attachment icon Proje Takip Yedek_fixed.zip 11.64 kb, 939 downloads since 2014-12-30 

Dmitry.

Re: calculate sum of project events

Not enough just paste the event (frmYeniProje_Button6_OnAfterClick) in a script editor, you must create the event, here you can find, how to do it right:
http://myvisualdatabase.com/help_en/scr … rview.html



Please, let me know result.

Dmitry.

Re: calculate sum of project events

Nice, i understand the logic now!
Thank you very much.

Your Framework is really cool and it looks like new generation application builder.