Topic: Plus and minus button
Hello, how to use this kind of button to multiply or subtract a number.
My Visual Database → General → Plus and minus button
Hello, how to use this kind of button to multiply or subtract a number.
Here's a workaround I've made in my project that act like numberbox. It doesn't have button thou.
Thanks, I will try it in my prog.
Doesn't work, I can't match my calculation boxes with this button, but it's okay.
Can you elaborate your calculation?
I would like to calculate the sums of the "Addition" form to display them in the "Collection" form with the total.
Hello Destiny
In my stamp management application (French) made with MVD (6.6), I display at the bottom of the welcome grid the updated value of my collection using in the parameters of the columns concerned of the grid the option Formula for display the value of new, hinged and canceled stamps.
Then, via the Save procedure of the input form, I display in an EditBox the total value resulting from the addition of the 3 values (behind a button).
In the screenshot of my grid that I sent you, this amount appears to the left of the button illustrated by a piggy bank.
In addition, find a place on the entry page to display this total, this will prevent you from creating a form dedicated to this, which can be deleted to lighten the weight of your application.
Dans mon application de gestion de timbres (français) faite avec MVD (6.6), j'affiche en bas de la grille d'accueil la valeur réactualisée de ma collection en utilisant dans les paramètres des colonnes concernées de la grille l'option Formula pour afficher la valeur des timbres neufs, avec charnière et oblitérés.
Ensuite, via la procédure Sauver du formulaire de saisie, j'affiche dans un EditBox la valeur totale résultant de l'addition des 3 valeurs (derrière un bouton).
Dans la copie d'écran de ma grille que je t'avais envoyée, cette somme apparait à gauche du bouton illustrée par une tirelire.
Par ailleurs trouve un endroit sur la page de saisie pour afficher ce total, cela t'évitera de créer une form dédiée à cela, qui peut être supprimée pour alléger le poids de ton application.
JB
Hi Jean, thank you for your advice, it helped me a lot.
I finished my stamp program which I adapted to my needs because in the trade I could not find the one that suited me.
I collect stamps from all over the world and I absolutely needed software to classify them, now with your help I will finish it.
Thank you
Destiny
Hello Destiny
In my application managing my stamp collection, I decided to only manage French stamps.
For foreign stamps, I wouldn't. I have ten full albums for these stamps, if I had to put them in, I would have no more fingers, but stumps.
Glad to have helped you finish yours.
At your disposal if necessary
Dans mon application gérant ma collection de timbres, j'ai décidé de n'y gérer que les timbres français.
Pour les timbres étrangers, je ne le ferais pas. J'ai dix albums pleins pour ces timbres, si je devais les rentrer, je n'aurais plus de doigts, mais des moignons.
Heureux de t'avoir aidé à terminer le tien.
A ta disposition si besoin
JB
Hello Jean, how do you proceed to have the total of your collection and the stamp counter outside the Table, in your example it is excellent and it does not take up space.
Destiny
Hello Destiny
First, at the foot of the grid displaying all the stamps seized (opening page), at the foot of the columns presenting the price of new stamps, stamps with hinges and canceled stamps, I created a footer sum of each of the values in each of the columns (Formula: SUM).
Then, on the welcome grid I place a button (hidden) with this code behind the OnClick procedure:
Form1.Edit1.value: = Form1.TableGrid1.Columns [20] .footer.formulavalue + form1.tablegrid1.columns [21] .footer.formulavalue + form1.tablegrid1.columns [22] .footer.formulavalue;
It's all hidden behind the button with the little pig.
Thus, once the new stamp has been entered and saved, as soon as the updated grid is displayed, the value is automatically incremented by those of the new stamp.
At your disposal if necessary.
Dans un premier temps, au pied de la grille affichant tous les timbres saisis (page d'ouverture), au pied des colonnes présentant le prix des timbres neufs, des timbres avec charnière et des timbres oblitérés, j'ai créé un en-pied faisant la somme de chacune des valeurs dans chacune des colonnes (Formula : SUM).
Ensuite, sur la grille d'accueil je place un bouton (caché) avec ce code derrière la procédure OnClick :
Form1.Edit1.value := Form1.TableGrid1.Columns[20].footer.formulavalue + form1.tablegrid1.columns[21].footer.formulavalue + form1.tablegrid1.columns[22].footer.formulavalue;
Tout cela est caché derrière le bouton avec le petit cochon.
Ainsi, une fois le nouveau timbre saisi et sauvé, dès l'affichage de la grille réactualisée, la valeur est automatiquement incrémentée de celles du nouveau timbre
A ta disposition si besoin.
JB
Your procedure works fine, but is there a way to have a direct display without clicking the button.
I found, I placed a second Table in hidden and I removed the buttons, with the event "OnChange" and 2 TexBox I added two formulas for the number of stamps and the price of the collection. The update is done when you click on the table.
// ------------------------------------------------ ---------------------------------------
procedure Form1_TableGrid2_OnChange (Sender: TObject);
begin
Form1.Edit3.value: = Form1.TableGrid1.Columns [4] .footer.formulavalue;
Form1.Edit4.value: = Form1.TableGrid1.Columns [5] .footer.formulavalue;
end;
Hello Destiny
In fact, to refresh the total value of my stamp collection, I don't need to click on the dedicated button.
I simply added this statement in the OnChange procedure of the home grid: Form1.Button10.Click; (Button 10 is the hidden button that I don't click).
I don't even need to click on the table to refresh the general amount of the collection.
Computing is still a lazy thing
En fait, pour réactualiser la valeur totale de ma collection de timbres, je n'ai pas besoin de cliquer sur le bouton dédié.
J'ai simplement ajouté cette instruction dans la procédure OnChange de la grille d'accueil : Form1.Button10.Click; (Bouton 10 est le bouton caché sur lequel je ne clique pas).
Je n'ai même pas besoin de cliquer sur la table pour rafraîchir le montant général de la collection.
L'informatique est quand même un truc de fainéant
JB
My Visual Database → General → Plus and minus button
Powered by PunBB, supported by Informer Technologies, Inc.
Theme Hydrogen by Kushi