Solved

Status not updated in a field and error not repeatable

Posted on 2001-07-12
1
199 Views
Last Modified: 2013-12-18
Now, i have to find a possible cause of error for the following piece of code:

@If(CMRStatus = "Business Input/Review Required" & CurrentStatus != CMRStatus; @Do(@MailSend(CreatedBy; ""; ""; "CR #" + CMRNo + " requires some additional Business Input/Review in the FS Destination database" ; "" ; "This change request for the " + Project +
 " project is either ready for your review or requires your additional input.  Follow this link for further details" +" ==>  "; [IncludeDoclink]);
@SetField("CurrentStatus"; CMRStatus); @PostedCommand([FileSave]));
CMRStatus = "Business Review Complete" & CurrentStatus != CMRStatus;
@Do(@MailSend("Rabinder X Kaur"; ""; ""; "CR #" + CMRNo + " has been updated by Business in the FS Destination database" ; "" ;
"This change request for the " + Project + " project has been updated by Business.  Follow this link for further details" +" ==>  "; [IncludeDoclink]);
@SetField("CurrentStatus"; CMRStatus); @PostedCommand([FileSave]));
CMRStatus = "Complete" & CurrentStatus != CMRStatus; @Do(@MailSend("Rabinder X Kaur"; ""; ""; "CR #" + CMRNo + " has been completed in the
FS Destination database" ; "" ; "This change request for the " + Project + " project has been completed.  Follow this link for further details" +" ==>  "; [IncludeDoclink]);
@SetField("CurrentStatus"; CMRStatus); @PostedCommand([FileSave]));"");
@PostedCommand([FileCloseWindow])


I tried recreating the error but i dont get it. therefore, it may have occured because-
1) if there are any replicas- the changes did not get replicated.
2) someone changed the status back to Build.
3) dont know!!!


Error as observed was:
I got this automated message that says this request has been completed, but when I go to the database, it is still listed in build with no comments.
0
Comment
Question by:puneetfred
1 Comment
 
LVL 18

Accepted Solution

by:
marilyng earned 100 total points
ID: 6447230
puneetfred;

Think the problem is the IF comparison.  You never really set the value of CMR status, and you need to declare the field before you use the @setfield statement.

Try this:
Field CurrentStatus :=CurrentStatus;
Status1="Business Input/Review Required";
Status2 ="Business Review Complete";
Status3="Complete";

@If(!@contains(CurrentStatus;Status1: Status2:Status3);
        @Do(
                     @MailSend(CreatedBy; ""; ""; "CR #" + CMRNo + " requires some additional Business Input/Review in the FS Destination database" ; "" ; "This change request for the " + Project +  " project is either ready for your review or requires your additional input.  Follow this link for further details" +" ==>  "; [IncludeDoclink]);
          @SetField("CurrentStatus"; Status1)          
                    );

      CurrentStatus= Status1;

    @Do(
               @MailSend("Rabinder X Kaur"; ""; ""; "CR #" + CMRNo + " has been updated by Business in the FS Destination
database" ; "" ; "This change request for the " + Project + " project has been updated by Business.  Follow this link
for further details" +" ==>  "; [IncludeDoclink]);    
            @SetField("CurrentStatus"; Status2)      
             );

             CurrentStatus = Status2;

             @Do(
                   @MailSend("Rabinder X Kaur"; ""; ""; "CR #" + CMRNo + " has been completed in the FS Destination database" ; "" ; "This change request for the " + Project + " project has been completed.  Follow this link for further details" +" ==>  "; [IncludeDoclink]);
                     @SetField("CurrentStatus"; Status3)              
                     );
"");

@PostedCommand([FileSave]);
@PostedCommand([FileCloseWindow])

See if it works for you,

Marilyng
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For Desktop Techs: How to retain a user's Notes configuration data when swapping out the end user's computer. (Assuming that you are not upgrading to a completely different version of Notes client) All you need to do is: 1) install Notes o…
IBM Notes offer Encryption feature using which the user can secure its NSF emails or entire database easily. In this section we will discuss about the process to Encrypt Incoming and Outgoing Mails in depth.
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

808 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question