Announcement

Collapse
No announcement yet.

hsp address updater

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • jrfuda
    replied
    OK, I partially figured this out.

    My Telco passes CID as 1234567890, not 123-456-7890, ot 1-123-456-7890.

    The script seemed to be setup for 1-123-456-7890, so I adjusted it so it reads:
    Code:
    area_code = Mid(callnmbr, 1, 3)
    city_code = Mid(callnmbr, 4, 3)
    local_code = Mid(callnmbr, 7, 4)
    and
    Code:
     Area_code2 = Mid(callnmbr, 1, 3)
    City_Code2 = Mid(callnmbr, 4, 3)
    Local_Code2 = Mid(callnmbr, 7, 4)
    and I changed
    Code:
    newcallnmbr = "1-" & area_code & "-" & city_code & "-" & local_code
    to:
    Code:
    newcallnmbr = area_code & "-" & city_code & "-" & local_code
    I threw in a couple of writelogs to ensure the variables were being populated correctly too, and it worked, with the phone numbers being matched-up with the correct entries, however, now the script errors-out when it goes to perform the lookup, perhaps what Jebus was refering to. I get this error:
    Code:
    Error~!~Script error in file: Phone_Book_Address_Updater2.txt: 9:Subscript out of range: 'j' in line 122
    , and since our lines probably don't match up anymore since I'ev added some log entries and comments, the line in question is:
    PHP Code:
    while spldata(j) <> "map" 
    How can this be fixed?
    Last edited by jrfuda; January 20th, 2006, 02:19 PM.

    Leave a comment:


  • jdr2bpa
    started a topic hsp address updater

    hsp address updater

    Here is a simple script to update hsp address book with the current addresses based on phone numbers received. Once caller id is received, via an event, the script performs a reverse number lookup and then updates the address book based on the information acquired. Directions are within the file and it does work with hs2.
    Attached Files
Working...
X