Link to home
Start Free TrialLog in
Avatar of koray_uygun
koray_uygun

asked on

Update a field based on the value of another one on the web

Hi lotus masters, it's at least 3 years that i ask your help here and you've never failed me ;-) and what is incredible it's usually the same persons who answer me. What do you win guys?
Ok, here's the question :
My mask displayed on the web has a field A where the user can choose a name. As soon as the name is chosen i want to update another field that, if i was using the mask in notes client should contain :

userID:=@If(A!="";@Subset(@DbLookup("" : "NoCache";"" : "names.nsf";"($Users)";A;"FullName");-1);"");

temp:=@If(userID!="";@DbLookup("" : "NoCache";"";"AdminVwOrganigramme";userID;5 );"");

@If(@IsError(temp);"Unknown";temp)

Do you have any idea to do this except a button?

Thx,
Koray.
Avatar of Arunkumar
Arunkumar

Hobout refresh fields on keyword change option in the Form properties ????
Avatar of koray_uygun

ASKER

Impossible, field A has a button next to him that opens a dialogbox where to choose a name from NAB and the dgbox fills the field A.
All that is needed is to refresh the page after you set the field "A"  use javascript i think i have it somewhere let me find it for you hang on.
Field B is not a computed field, users must be able to enter other persons.
oh both are open fields is it ???
yes
Hm, interesting. The dialog box fills the name from address book.
How is this done?
1) By passing the value to the opener window using Javascript?
2) By updating the referenced document from script in an agent that then reopens the document?
If the last one is the case, you could in the same agent do your lookup and add the value to field B I guess.
Hello Koray,

may I repeat your request...

You have two fields: A and B
As soon as field A get a value you would like to preset field B
When field A changes its value should field B be preset again with corresponding value.
Important! As soon as field B is changed by user no value preset is allowed any more for this field.

Are this assumptions correct?

PS: refreshing the form onChange of a text field on web is not a problem for an Wiz <|;-)

It's also no problem for a whiz kid :-)
Hi, thanks for being interested in my problem.
Jerrith, the answer is 1)
Zvonko, you're right on understanding my request. Refreshing the doc is not a solution i think as soon as B is not a computed field.
My question did not contain any proposal :-)

And now that my assumptions are settled here my proposal packed in a question...
Should I write a @formula for you to do this field B presets?

I have done this in my application this way:
1.) The field A got an onChange JavaScript function to refresh the page.
2.) The InputValidation formula for field A checked whether its value changed; if not then do nothing
3.) The InputValidation formula for field A checked whether field B value is empty; If yes then preset with new proposal and save the proposal in a hidden field.
4.) If field B value is not empty and is equal to saved hidden field then preset field B with new proposal.
5.) Field B value is not empty and not equal to last saved preset value; that mean field B is edited by user and may not to be changed.

This checkings sound complicated in English words but are easy to implement in @Formulas. Should I give you an example?

ASKER CERTIFIED SOLUTION
Avatar of zvonko
zvonko

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Hello Koray,

do you need help?


Thanks Zvonko, i'll try it next wednesday and tell you...:-)
Ok, thanks.

So long,
zvonko

Sorry, i haven't found the time yet do check the solution, i have more urgent bugs to correct for now ;-). I'll do it as soon as i find a moment.
No problem, take your time :)

Avatar of Zvonko
koray_uygun,
No comment has been added to this question in more than 711 days, so it is now classified as abandoned..
I will leave the following recommendation for this question in the Cleanup topic area:

RECOMMENDATION: Award points to zvonko http:#7073160

Any objections should be posted here in the next  4  days. After that time, the question will be closed.

Thanks,
Zvonko
EE Cleanup Volunteer
Sorry for the delay, I didn't even remember this question now ;-)
Thank you for closing this one.
Please have also a look for this old one: http:Q_20823630.html

Either grant points to qwaletee or ask for points refund at https://www.experts-exchange.com/Community_Support/