Jump to content

wayancenik

Members
  • Posts

    0
  • Joined

  • Last visited

Reputation Activity

  1. Like
    wayancenik reacted to kme in Timestamp When "y" Clicked   
    MayMusic - Thanks so much, it is working now.
     
    For those interested in the solution, 
    The additional problem was that Timestamp field in the Table had to have a datatype of Text(255).
    In the Details Page, Timestamp was changed to a Text Field. Once Yes was clicked, the textfield was filled with a timestamp, and then when Update was clicked, the field in the Results Page was filled with the timestamp.
     
    Thanks again.
  2. Like
    wayancenik reacted to docmgt in Authentication Logouts - Windows 7/IE9 vs. Windows XP/IE8   
    Hi all,
    I'm deploying Caspio Bridge on an Intranet. For datapages that include a secondary details link - we consistently experience authentication errors with IE - depending on the OS or browser version. For Windows 7/IE9 - I get booted out; XP/IE8 - I can get to detail pages fine.
    Has anyone else encountered this? Using Chrome and Firefox - I do not get a boot out issue for detail links - HOWEVER, because we link to files on a server for the intranet - the preferred browser must be IE. The plugins for Chrome/Firefox don't correct our file linking.
    I don't want the end user experience to be bad - having to use 2 browsers is not acceptable. Any suggestions?
  3. Like
    wayancenik reacted to caspio in JS: Format Phone Number   
    JavaScript Solution: Format phone number

    Feature Description:
    This JavaScript solution shows how to format an entered phone number as (XXX)-XXX-XXXX  in a Submission Form.
     
    Implementation:
    This solution can be used "as-is", without any changes if
    a. It is used in a Submission Form DataPage.
    b. There is a text field in the table called "Phone".
    To use this solution copy and paste the code below, inside the HTML Footer section of the Form using the Caspio Bridge DataPage Wizard.
     
    <SCRIPT LANGUAGE="JavaScript"> var arrEl = Array.from(document.querySelectorAll('#InsertRecordPhone1, #InsertRecordPhone2, #InsertRecordPhone3')); let regExp = /^[0-9]+$/; arrEl.forEach(function(el) { el.maxLength = 14; el.addEventListener('input', function(v_e) { if (regExp.test(v_e.key)) { this.value = this.value.substr(0, this.value.length - 1); return false; } let v_value = (this.value.replace(/[^\d]/g, '')); console.log(v_value, this.value); if (v_value.length >= 7 && v_value.length < 10) { this.value = (v_value.substring(0, 3) + "-" + v_value.substring(3, 7) + v_value.substring(7, v_value.length)); } else if (v_value.length >= 10) { this.value = ("(" + v_value.substring(0, 3) + ") " + v_value.substring(3, 6) + "-" + v_value.substring(6, 10) +v_value.substring(10, v_value.length)); } }); }); </SCRIPT> Tips for Customization
    To customize this script to be used on an Update WebForm or a Details page of a Report DataPage, replace the prefix "InsertRecord" with "EditRecord" in the code. And make sure the field is not "Display Only" because this script is used for input fields.
     
    Tested Browsers
    This JavaScript solution was tested on the following platforms and Internet Browsers only.
    # MS Windows - IE 10, Firefox 23.0.1, Chrome 29.0.1547.57, Safari 5.1.7
    # Macintosh # Firefox 3.6.22, Safari 5.1.7

    Disclaimer: Use these JavaScript solutions at your own risk! They are provided to assist you in the customization of your programs and while we believe they work properly, by using them you accept all responsibility about them and confirm that they are not a feature of Caspio's platforms and as such are provided "as is" without any warranties, support or guarantees.
     
     
  4. Like
    wayancenik reacted to caspio in JS: Format tabular display on result page in four ways   
    JavaScript Solution: Format tabular display on result page in four different ways

    Feature Description:
    This JavaScript solution shows how to format the Results page of a Search and Report DataPage in four different ways. For ease of reference, these formats are referred to as Type A, Type B, Type C and Type D respectively. The details are:
    a. Type A: Individual column - Background color
    b. Type B: Individual column - Font weight
    c. Type C: Individual row - Font weight
    d. Type D: Individual column - Conditionally format background color

    Features in this solution that can be easily customized are,
    a. Column number for Type A formatting.
    b. Column number for Type B formatting.
    c. Row number for Type C formatting.
    d. Column number for checking if a specified condition is met.

    Implementation:
    This solution can be used "as-is", without any changes if
    a. It is used in a Search and Report DataPage and
    b. The table to be formatted is the first table of the web page in which the DataPage is embedded,
    c. The 2nd column is to be formatted as Type A,
    d. The 3rd column is to be formatted as Type B,
    e. The 2nd row is to be formatted as Type C,
    f. The 3rd column is to be formatted as Type D if a cell in the column contains the value Yes.
    Note: Conditional formatting may not be displayed if the condition being checked is not satisfied by the data in the specified column.

    To use this solution,
    a. Highlight the code provided in the text area shown below and copy it.
    b. Paste it inside the HTML Footer section of the Results page using the Caspio Bridge DataPage Wizard.
     
    <SCRIPT LANGUAGE="JavaScript"> /*(1) tablenum is the number of the table to be formatted */ var tablenum = 0; /*(2) Two columns used for the different formatting styles */ var columnNum1 = 1; /*used in Type A */ var columnNum2 = 2; /*used in Type B and Type D */ /*(3) rowNum is the number of the row to be formatted */ rowNum = 2; //used in Type C /*(4) variables for colors. */ var white = '#FFFFFF'; var lightGrey = '#CCCCCC'; var yellow = '#FFFF00'; /*(5) variables for font style */ var fontStyle1 = 'bold'; /*(6) variable for condition to check in conditional formatting, Type D.*/ var conditionString = "Yes"; var tbl = document.getElementsByTagName('table')[tablenum]; var rows = tbl.getElementsByTagName('tr'); /*(7) Type C: style individual row: fontWeight */ rows[rowNum].style.fontWeight = fontStyle1; for (var row=0; row<rows.length;row++) { var cells = rows[row].getElementsByTagName('td'); /*(8) Type A: style individual column: background color */ cells[columnNum1].style.backgroundColor = lightGrey; /*(9) Type B: style individual column: fontweight */ cells[columnNum2].style.fontWeight = fontStyle1; /*(10) Type D: conditional formatting. */ if (cells[columnNum2].innerHTML == conditionString) { cells[columnNum2].style.backgroundColor= yellow; } } </SCRIPT> To customize this solution, change the values of the variables tablenum, columnNum1, columnNum2 and rowNum as required.

    Additional Considerations
    This solution may be difficult to customize if the web page in which the DataPage is embedded, contains a large number of tables. In order to see the full effect of this solution, the appropriate columns and rows have to exist in the data table. Variations of such formatting can be implemented easily by using this solution as a guideline.

    Tested Browsers
    This JavaScript solution was tested on the following platforms and Internet Browsers only.
    # MS Windows - IE 8.0, Firefox 3.5.7, Chrome 3.0.195.38, Safari 4.0.3
    # Macintosh - Firefox 3.5.7, Safari 4.0.3

    Disclaimer: Use these JavaScript solutions at your own risk! They are provided to assist you in the customization of your programs and while we believe they work properly, by using them you accept all responsibility about them and confirm that they are not a feature of Caspio's platforms and as such are provided "as is" without any warranties, support or guarantees.
  5. Like
    wayancenik reacted to supra01 in Passing value to a variable in a query dynamically(Web API)   
    In the Select Query while using Caspio Web Services API, SAY
    stub.selectDataRaw("acnt name", "API profilename ", new String(""), "tablename", true, "proj_comp_id, timesheet_from_date , timesheet_to_date", "criteriaField.getText()" , orderByField.getText(), ",", ",");
    Need to know how to pass the criteria dynamically as "proj_comp_id = $project_Id" for criteriaField.getText()???
    If I hard code the value of project id to be some value say 140, it works..Struck with passing it dynamically.
    Thanks
  6. Like
    wayancenik reacted to lugoimports in User authentication   
    I have a table used to authenticate access. For some reason, I currently have 24 users and it works. The problem is I'm trying to add more and the id/password doesn't work for the new users. What am I doing wrong? Is there a restriction as far as how many users you can have???
×
×
  • Create New...