Editable View Field

Can an editable view field be made to run a formula or script by virtue of clicking the field into edit mode? I’d like to have this formula currently used with a button: MapPath := “file:\servername\gen_user\tsd\iagprojects\officelocator\”;@If(@Trim(DeskLocation)=“”;@Do(@Prompt( [Ok];“Aborting”;“The Desk Location Field is Blank.”);@Return(“”));“”);

quad := @Text(@Left(DeskLocation;2));

mapfile := @If(quad = “11”;“floor1w.html”;quad = “12”;“floor1w.html”;quad = “13”;“floor1e.html”;quad = “14”;“floor1e.html”;quad = “21”;“floor2w.html”;quad = “22”;“floor2w.html”;quad = “23”;“floor2e.html”;quad = “24”;“floor2e.html”;quad = “31”;“floor3w.html”;quad = “32”;“floor3w.html”;quad = “33”;“floor3e.html”;quad= “34”;“floor3e.html”;quad = “41”;“floor4w.html”;quad = “42”;“floor4w.html”;quad = “43”;“floor4e.html”;quad = “44”;“floor4e.html”;“”);

pinx := @DbLookup(“Notes”:“NoCache”;“”;“LocCoords”;DeskLocation;2);

piny := @DbLookup(“Notes”:“NoCache”;“”;“LocCoords”;DeskLocation;3);

@If(@Trim(@Text(pinx))=“” | @Trim(@Text(piny))=“”;@Do(@Prompt([Ok];“Aborting”;“The desk information could not be located.”);@Return(“”));“”);

@URLOpen(MapPath+mapFile + “?OpenPage&pinx=”+@Trim(@Text(pinx)) + “&piny=”+ @Trim(@Text(piny)))

to run when a user clicks on the field to edit it within a view…can it be done?

Subject: RE: Editable View Field

You can put LotusScript in the InViewEdit event that will be invoked when the user tries to edit a field. I haven’t read your formula carefully but I suspect there’s nothing there that couldn’t be done in script. Read the designer help about InViewEdit, and ask a more specific question if you run into an obstacle.

Subject: RE: Editable View Field

Thanks Andre, I wish I could be more specific and I had the knowledge to translate that formula to lotuscript. The code goes to a network drive where there are some maps of our building, it looks at a field on the form and goes and puts a pointer at that location on the map…All I want to do is not have the user need to open the form, just click on the field in the view and automatically execute the formula. I have reviewed the InViewEdit event but can’t figure out if I can make it execute this formula…I appreciate your help in this and I am still learning so maybe my questions will become a little more intelligent…Thanks