03-30-2012, 01:02 AM
I've read several form threads hoping to find an answer to this question and so far have not.
What I'm doing is simple. I have a WebEdit object and in this object, I'm inserting a string concatenated with a variable. It looks like this:
Once this web page saves, I want to check a WebElement to ensure my object saved the string and variable combination. For example, this is a "name" field and I'm entering something like "Everett Auto Sales3/29/2012 10:15 AM". Once I click the "save" button, I want to check to ensure that a particular Web Element on the subsequent page captured the "name" correctly.
I've looked into creating an environmental variable and calling that into a standard checkpoint parameter, however, based on the concatenation of a string and variable, I just can't get it to work. So, I started playing around with an if/else statement thinking that may be the answer. I tried something like this:
Unfortunately, I'm not as skilled as I'd like to be in VB and don't know were to go from here. I'm getting an "Object doesn't support this property or method" error. Even after I get passed that, I'm not sure if the micPass/micFail will even work. Can anyone please provide me some direction? I would assume that putting checkpoints on variables is commonplace, but I just can't seem to get this to work.
Thanks to anyone who can give me direction.
What I'm doing is simple. I have a WebEdit object and in this object, I'm inserting a string concatenated with a variable. It looks like this:
Code:
Browser("salesforce.com - Unlimited").Page("Campaign Edit: New Campaign").WebEdit("Campaign - Campaign Name").Set "Everett Auto Sales" & varDateTime
Once this web page saves, I want to check a WebElement to ensure my object saved the string and variable combination. For example, this is a "name" field and I'm entering something like "Everett Auto Sales3/29/2012 10:15 AM". Once I click the "save" button, I want to check to ensure that a particular Web Element on the subsequent page captured the "name" correctly.
I've looked into creating an environmental variable and calling that into a standard checkpoint parameter, however, based on the concatenation of a string and variable, I just can't get it to work. So, I started playing around with an if/else statement thinking that may be the answer. I tried something like this:
Code:
If Browser("salesforce.com - Unlimited").Page("Campaign: Everett Auto").WebElement("Everett Auto Sales")= "Everett Auto Sales" & varDateTime Then
micPass
Else
micFail
End If
Unfortunately, I'm not as skilled as I'd like to be in VB and don't know were to go from here. I'm getting an "Object doesn't support this property or method" error. Even after I get passed that, I'm not sure if the micPass/micFail will even work. Can anyone please provide me some direction? I would assume that putting checkpoints on variables is commonplace, but I just can't seem to get this to work.
Thanks to anyone who can give me direction.