I have an agent that is adding documents to a database and depending on 
whether additional information is needed, I want to display one of two 
forms upon it's completion. Here is the code snippet I'm having a problem 
with:

 
        Dim vPath As Variant
        Dim vOption As String

        'Set URL path for return
        vPath=Evaluate({@ReplaceSubstring (@Subset (@DbName; -1); "\\" : " 
"; "/" : "+")})
 
        If cDoc.Personalized = "Y" Then
                vOption="/OrderItemLookup/" & oiDoc.UniversalID & 
"?EditDocument"
        Else
                vOption="/cart?ReadForm"
        End If
 
        Print "[" + vPath(0) + vOption + "&CartID=" + vCartID(0) + "]"


When I run the agent as listed, I receive the "Agent done" web page. If I 
comment out the "If", "Else", "End If" and either of the "vOption=" 
statements, I get the results I want. It doesn't matter which "vOption=" 
statements I comment out, they both work.

Can anyone tell me why it doesn't work with the "If" statement activated?

John Techmeier
IT Director
The Medalcraft Mint, Inc.
Phone:  920-499-4249
Fax:    920-499-7092
Email:  jtechmeier@xxxxxxxxxxxxxx
http://www.medalcraft.com

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.