@newuserkantu
Below is the code and log…I have a separate macro for saving images from logging into the website to keep things easy to edit.
Since your response, I made some changes to where my macro now functions as intended.
(I realized unique values were not necessary since the csv has no column headers, so I rewrite the same value with each new image and save to the csv)
I am still interested in how to store those values in the csv as an array instead of in separate columns
{
“Name”: “Image Extract-1”,
“CreationDate”: “2020-3-26”,
“Commands”: [
{
“Command”: “storeText”,
“Target”: “css=td.d77m39 > span”,
“Value”: “mls_number”
},
{
“Command”: “echo”,
“Target”: “The MLS number is {mls_number}",
"Value": "blue"
},
{
"Command": "store",
"Target": "{mls_number}”,
“Value”: “!csvLine”
},
{
“Command”: “verifyElementPresent”,
“Target”: “xpath=//*[@id=“m_DisplayCore_dpy1”]/div[2]/font[3]”,
“Value”: “”
},
{
“Command”: “gotoIf_v2”,
“Target”: “{!statusOK} == false",
"Value": "no_images"
},
{
"Command": "echo",
"Target": "Property Images Exist",
"Value": "green"
},
{
"Command": "click",
"Target": "xpath=//*[@id=\"m_DisplayCore_dpy1\"]/div[2]/font[3]",
"Value": ""
},
{
"Command": "selectWindow",
"Target": "tab=1",
"Value": ""
},
{
"Command": "clickAndWait",
"Target": "xpath=//*[@id=\"m_trGallery\"]/td/table/tbody/tr[1]/td[1]/a/img",
"Value": ""
},
{
"Command": "storeText",
"Target": "xpath=//*[@id=\"m_trPaging\"]/td/table/tbody/tr/td[2]/b[2]",
"Value": "imgcount"
},
{
"Command": "echo",
"Target": "Photo gallery contains {imgcount} photos”,
“Value”: “blue”
},
{
“Command”: “executeScript_Sandbox”,
“Target”: “return Number ({imgcount}) - 1;",
"Value": "last_image_saved"
},
{
"Command": "while_v2",
"Target": "{last_image_saved} != {imgcount}",
"Value": ""
},
{
"Command": "storeText",
"Target": "xpath=//*[@id=\"m_trPaging\"]/td/table/tbody/tr/td[2]/b[1]/span",
"Value": "current_img"
},
{
"Command": "storeAttribute",
"Target": "xpath=//*[@id=\"m_trGallery\"]/td/div[1]/a/img@src",
"Value": "image_src"
},
{
"Command": "storeText",
"Target": "id=PopupCaption",
"Value": "caption_{current_img}”
},
{
“Command”: “executeScript_Sandbox”,
“Target”: “return Number ({current_img});",
"Value": "last_image_saved"
},
{
"Command": "store",
"Target": "{image_src}”,
“Value”: “!csvLine”
},
{
“Command”: “echo”,
“Target”: “Image source {last_image_saved} of {imgcount} saved”,
“Value”: “green”
},
{
“Command”: “echo”,
“Target”: “Image {last_image_saved} source is {image_src}”,
“Value”: “green”
},
{
“Command”: “click”,
“Target”: “linkText=Next”,
“Value”: “”
},
{
“Command”: “endWhile”,
“Target”: “”,
“Value”: “”
},
{
“Command”: “csvSave”,
“Target”: “listing_export”,
“Value”: “”
},
{
“Command”: “echo”,
“Target”: “CSV saved”,
“Value”: “blue”
},
{
“Command”: “localStorageExport”,
“Target”: “listing_export.csv”,
“Value”: “”
},
{
“Command”: “echo”,
“Target”: “CSV downloaded”,
“Value”: “blue”
},
{
“Command”: “label”,
“Target”: “no_images”,
“Value”: “”
}
]
}