December 21, 200520 yr Hi all Usually when a user login, system will bring user to last system record. How to actually bring user to his/her last record instead of system last record. I worked on it but only manage to come up with this.. Go to record[First] Loop If[RecordOwner = Get(AccountName)] Omit Record End If Go to Record[Next] Exit Loop If[Get(RecordNumber)=?] End Loop Show Omitted Only In '?', lets say if i were to put 25, it will only loop through the first 25 records. But i wish to loop till the last record which may consist hundreds of records.. And even when i put 'Exit Loop If[Get(RecordNumber)=25]', i have 7 'staff' records but only shows '4'.. And Im working in a IWP environment but i guess it makes no difference between iwp and with client. Help needed.. Thanks a lot.. Kelvin
December 21, 200520 yr But why not such: Enter Find Mode Set Field[RecordOwner,Get(AccountName)] Perform Find Go To Last Record If your file contains 100000 records your script will work very long time.
December 22, 200520 yr Author Hi aaa Thanks so much.. You mean the method you mention will work very long time if there are like 100000 records? 1. I actually having 2 different forms, so i am having 2 scripts that doing almost the same thing except 'RecordOwner' from different table. I tried this calling the field from other table but it don't works.. Set Field[TravelReport::RecordOwner,Get(AccountName)] Is there anyway to use 1 'RecordOwner' for all? 2. 'Show All Records' default will bring us to first 25 records. But I wish to view last 25 records. I done this it works, but is there any other better way? cos mine dun looks nice i feel.. haha.. Enter Find Mode[] Set Field[Travel Request::RecordOwner; Get(AccountName)] Perform Find[] Go to Record/Request/Page [Perform with dialog (NOT COMPATIBLE); Last] Go to Record/Request/Page [No dialog; Get(RecordNumber) - 24] Thanks a lot Kelvin
December 30, 200520 yr Hi, Rushhour ! I wanted to say that omiting method will work about a long time.But the second method must work very quickly: Enter Find Mode[] Set Field[Travel Request::RecordOwner; Get(AccountName)] Perform Find[] Go to Record/Request/Page [Perform with dialog (NOT COMPATIBLE); Last] Go to Record/Request/Page [No dialog; Get(RecordNumber) - 24] I think that this is good method.What other? I am sorry! The first question i can not understand. Can you explain me attaching in the simple example. Edited December 30, 200520 yr by Guest
January 3, 200620 yr Author Hi aaa Oh! i thought you are referring to this method that it will work very long so its okie now thanks. I have this field Get(RecordOwner) which gets it input from Get(AccountName). It is use to only see user own record by doing this, under account and privileges, set records can only be view when Exact (Lower(Get(AccountName)); Lower (RecordOwner)). I have 2 forms, 'travel request' and 'travel report' in my file. Both form uses this method, is it possible to combine it so i only need to create 1 'RecordOwner' field to use in both forms?? Thanks a lot Cheers, Kelvin
January 14, 200620 yr Hi, Roshour! In the finish it seems that i understood your question. Let you have Record_Owner in one table. How you can know that the record_owner in the other table. May be your records in two table joined by owner...? I think that easy way is anythink like this: If you want to have one script for two tables you must to check in script layout then find. I can suggest you example, which i attached. The acount_names is: admin aaa bbb ccc ddd I attached you idea, not solution. In this way i think you can have only one script for your tables. Edited January 14, 200620 yr by Guest
January 16, 200620 yr Author Hi aaa, i can't dl the file theres some error. Maybe can you try compressing it with winzip..? Thanks a lot.. Cheers, Kelvin
January 17, 200620 yr Hi, Roshhour! I am sorry! I must to send you zipfile, but i attached rar. Here is the zip archiv. Rosh.zip Edited January 17, 200620 yr by Guest
Create an account or sign in to comment