CodeCharge Studio
search Register Login  

Visual PHP Web Development

Visually Create Internationalized Web Applications, Web Reports, Calendars, and more.
CodeCharge.com

YesSoftware Forums -> CodeCharge -> Programming

 New Record, Field Default Value is last update

Print topic Send  topic

Author Message
mitch

Posts: 2
Posted: 03/03/2005, 12:23 PM

How i can get parameter from form_1 to form_2 in this case
for example,
recordform name form_1 event new record, tbl_emon
field_1 = user_id ( type number) default value auto, hidden
field_2 = date ( type date ) default value [ value "date" form_2 ] field_n = count ( type number) custom

form name form_2 hidden sql select from tbl_emon, user_id, max(date) group by user_id
field_1 = user_id ( type number) hidden
field_2 = date ( type date ) max value

Your help would be greatly appreciated.

Thanks

mitch
View profile  Send private message
Nicole

Posts: 586
Posted: 03/04/2005, 12:55 AM

Mitch,
I’m afraid that it is impossible to obtain a value from one form on another form in CodeCharge.
Please use Before Show event of form_2 to call DLooUp() function and retrieve max(date) value from tbl_emon

Regards,
Helen

_________________
Regards,
Nicole
View profile  Send private message
mitch

Posts: 2
Posted: 03/07/2005, 4:43 AM

:-):-):-)
tanks to Nicole for quick responce.

i have a solution by funktion DLookup. Works pretty

Here are the basics:

$u_id = get_session("UserID"); // User login
if($u_id > 0) { // check if it exist
// get parameter date max
$last_date_from_user = Dlookup("tbl_emoni", "max(date2)", "user_id=" . $u_id );
if($flddate_02 == "") // New Record Default Value
// Das Datum dem Field DeinDateField vorgeben.
$flddate_02 = $last_date_from_user;
}

nicole, how is cc compare value count_01 to count_02
it is important that user can only insert a
value in count_02 > count_01. By false give user
a message what is wrong.

New Record in Form_01 by use Default Value
-------------------------------------------
def-Val. | def-val. | user | user |
date_01 | Count_01 | date_02 | Count_02 |
-------------------------------------------
20.02.05 | 199 | 22.02.05 | 205 | Ok
22.02.05 | 205 | 24.02.05 | 215 | OK
24.02.05 | 215 | 26.02.05 | 195 | false


hop to hear again
regards,

mitch
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Internet Database

Visually create Web enabled database applications in minutes.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.