Jump to content

This topic is 7716 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

hi, thanks for your help. i'd to make a simple edit to multiple records at the same time, using a valuelist, radio buttons or checkboxes. is this possible? appreciate any input!

Posted

It's possible using a script. But there are questions that have to be answered first.

Which records would need to be changed? Marked records? The found set? Related or self-related records?

The 2nd question is what interface to use to run the script. Any of the above types of value list formats would work, if you first let them choose, then hit a button to run the script. But of course the problem then is what if they don't hit the button.

A checkbox could be made to run automatically, by placing a separate invisible script button over each different choice. But then they could only make 1 choice, which is counter to the way a checkbox normally works.

Radio buttons could also be done this way, by creating a separate value list for each single choice (trick), then using script buttons over each (like the checkbox above). This is probably the best choice.

The "multiple records" part is just a Loop script, with the action inside, and Go To Record/Request [Exit after last, "Next"]. Or the Replace step, which is easier but less flexible and less multi-user friendly.

A last question, if the multiple records are not the current Found set is whether you want/need to restore the original found set and original record (also Sort order, if known). All of this can be done, but involves a bit more scripting. Its method(s) must also consider the size of the original found set, due the 64 character limit on fields (can handle larger sets, but requires another file and is slower).

Of course, it's much easier if the current set is all records.

Posted

Fenton, I believe you've missed that randyinla is using CWP. What you are discussing is, at best, for peer-to-peer solutions, not CWP. I don't know that IWP recognies the kind of ScriptMaker event which you are suggesting. In fact (I know this well), there are serious issues with ScriptMaker when it fails to process an event. These issues have been discussed widely on this forum. From your answer it seems that you are unaware of the problems and you have not rigorously tested ScriptMaker events in browser solutions.

Yes, it is possible to use ScriptMaker on the web, but a solution to the problem of unprocessed events must be resolved. I have done such a thing, so I can tell you it is possible to develop such a solution. And even with that, not all ScriptMaker events are suitable for the browser, especially an event which loops.

Now to answer randyinla's question. Yes, it is possible with CWP to edit multiple records. Search this forum for solutions which involve JavaScript. Through the use of JavaScript the client's machine gets tied up processing a loop while the FMPro Unlimited db on the server remains free to accept requests from other clients.

Posted

thanks fenton and keith! i am the only user who will make changes to multiple records. i have not yet made a script (was trying to avoid that, perhaps i should embrace my fears), i'll attempt using javascript. i appreciate both of your efforts in helping me!

Posted

Oops, yes, I clicked on the link on the main forum page, which doesn't say which particular forum the question is in. Next time I'll pay more attention. And no, I don't know how to do it either :-|

  • Newbies
Posted

Yes, multiple records can be editted ot one time (assuming you mean edit a series of records with each on a separate row and each record being edited with a different value).

You can do it thru Javascript, but I've always done it using a portal inside a Form arrangement via CDML. You do this by adding the ".[fmp-currentportalrow]" tag to the end of your field name, so it looks like this:

 

<FORM ACTION="FMPro" METHOD="POST">

<INPUT TYPE="hidden" NAME="-DB" VALUE="dbase_.fp5">

<INPUT TYPE="hidden" NAME="-Lay" VALUE="web">

<INPUT TYPE="hidden" NAME="-Format" VALUE="search_results.htm">

<INPUT TYPE="hidden" NAME="-Error" VALUE="record_detail_error.htm">

<INPUT TYPE="hidden" NAME="-recid" VALUE="[fmp-currentrecid]">

			

   [FMP-PORTAL: relationship_name]

   <TABLE>

    <tr>            

     <TD valign="top">

     <input type=text name=relationship_name::lname.[FMP-CurrentPortalRowNumber] value=[FMP-field:relationship_name::lname]>

     </TD>

     <TD valign="top">

     <input type=text name=relationship_name::fname.[FMP-CurrentPortalRowNumber]  value=[FMP-field:relationship_name::fname]> 

     </TD>

    </tr>

   </table>

  [/FMP-portal]



<INPUT SRC="http://ohiojcl.org/img/submit_changes.gif" NAME="-edit"  TYPE=image>

</FORM>

All of that is, of course, performed after completing a find of the parent file which collects the related child records into the portal. Note: you do not need the ".[FMP-currentportalrow]" after the "value" tag. Also, if you use portal row value of .0 (zero) it will create a new related record, but be careful - it is too easy to overwrite data).

Hope that helps get you started!

This topic is 7716 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.