De fleste virksomheder har efterhånden bevist, at AI virker.
Pilotprojekter leverer resultater. Medarbejdere bruger generative AI-værktøjer. Nye use cases dukker op på tværs af organisationen.
I am assuming that you enter your data on a form. So in the forms properties (desgign view) you can choose the BeforeUdate event and then just add the code I mentioned. What happens here is that just before the record gets written it takes the values of the other two forms and calculates the third field.
Well.. I vill not have to worry about formatting the data for input in a currency-field for one thing.. it seems to me that ther\'s a lot less things that coud go wrong this way.... But i guess it\'s a long discussion.. Your remark that it will not help is now noted :o)
You dont have to format the data as a currency field if you already have two valid fields (antal + stk_pris). If your using an SQL INSERT statemnet then you could have variable which gets the value from the other two fields.
Dim myVar myVar = Request.Form(\"Antal\") * Request.form(\"stk_pris\")
Then include myVar in your INSERT statement No nothing about ASP but I assume it ssomething like that
I can see the logic in what you are attempting to do but I must admit, I dont think it is possible. I dont think the values of these fields are available when the default value is set into the pris_ialt field. Another thing, why have a pris_ialt field, it can always be calculated?
Your right... im sacreficeing data space in order to eleminate the need for calculations.. wich is not as great an idea as i thougt to begin with.
Im going to drop the pris_ialt field...
Tanks for helping me out :o)
Synes godt om
Ny brugerNybegynder
Din løsning...
Tilladte BB-code-tags: [b]fed[/b] [i]kursiv[/i] [u]understreget[/u] Web- og emailadresser omdannes automatisk til links. Der sættes "nofollow" på alle links.