Jump to content

kme

Members
  • Content Count

    24
  • Joined

  • Last visited

  • Days Won

    2

Everything posted by kme

  1. How do you store the Calculated Field values into a table? I'd like it done automatically as the value is being calculated.
  2. Does anyone know of a workaround for this, without having to pay the support team for customization?
  3. When creating a Report DataPage, one of the first things you can do is "Select Filtering Data". When I've selected a field, I want the filtering value to be from a View (which is not part of this DataPage's data source). The View itself has filters and contains only one row, which contains the value that I want to filter the DataPage with. Is there anyway that I can select the value from the View and input it into the DataPage filter value field?
  4. Thank you so much, the fields are non-editable and everything is working now. Here is my code: <script> document.getElementById('EditRecordSupportReadyYes').disabled= true; document.getElementById('EditRecordSupportRequiredYes').disabled= true; document.getElementById('EditRecordSupportRequired0').onclick= function () { if (document.getElementById('EditRecordSupportRequired0').value == 'Y'){ var currentdate = new Date(); var datetime = (currentdate.getMonth()+1) + "/" + currentdate.getDate() + "/" + currentdate.getFullYear() + " " + currentdate.getHours() + ":" + currentdate.getMinutes(); document.getElementById('EditRecordSupportRequiredYes').disabled= false; document.getElementById('EditRecordSupportRequiredYes').value = datetime; document.getElementById('EditRecordSupportRequiredYes').disabled= true; } } document.getElementById('EditRecordSupportRequired1').onclick= function () { if (document.getElementById('EditRecordSupportRequired1').value == 'N'){ document.getElementById('EditRecordSupportRequiredYes').disabled= false; document.getElementById('EditRecordSupportRequiredYes').value = ""; document.getElementById('EditRecordSupportRequiredYes').disabled= true; } } document.getElementById('EditRecordSupportReady0').onclick= function () { if (document.getElementById('EditRecordSupportReady0').value == 'Y'){ var currentdate = new Date(); var datetime = (currentdate.getMonth()+1) + "/" + currentdate.getDate() + "/" + currentdate.getFullYear() + " " + currentdate.getHours() + ":" + currentdate.getMinutes(); document.getElementById('EditRecordSupportRequiredYes').disabled= false; document.getElementById('EditRecordSupportReadyYes').value = datetime; document.getElementById('EditRecordSupportReadyYes').disabled= true; } } document.getElementById('EditRecordSupportReady1').onclick= function () { if (document.getElementById('EditRecordSupportReady1').value == 'N'){ document.getElementById('EditRecordSupportRequiredYes').disabled= false; document.getElementById('EditRecordSupportReadyYes').value = ""; document.getElementById('EditRecordSupportReadyYes').disabled= true; } } function enableElements(){ document.getElementById('EditRecordSupportRequiredYes').disabled= false; document.getElementById('EditRecordSupportReadyYes').disabled= false; } document.getElementById("caspioform").onsubmit=enableElements; </script> I had to add the function at the end and extra .disabled lines everywhere because initially the .disabled made it so that when I clicked Update, the timestamps wouldn't show. =) Thanks again.
  5. So there is no way to do it, whether with Javascript or..?
  6. Is there a way to create a search filter for a calculated field?
  7. This is the solution: SELECT TOP 1 RonOpportunity FROM Routing_1 WHERE RonOpportunity !='' AND Current_Open_NEF_Data_Ship=AcNum
  8. This is the SQL that works, for Table A and Table B. Table B is the data source for the DataPage, and Table A isn't. I want to update Table B's column "City" according to Table A's column "Letter". TABLE A +----------+-------+ | Number | Letter| +----------+-------+ | 1 | A | | 1 | | | 1 | | | 2 | | | 2 | | | 3 | | | 3 | B | | 3 | | | 3 | C | +----------+-------+ TABLE B +--------+-------+ | AC | City | +--------+-------+ | 1 | A | | 1 | A | | 1 | A | | 1 | A | | 2 | | | 2 | | | 2 | | | 2 | | | 3 | B | | 3 | B | | 3 | B | +--------+--------+ UPDATE TableB SET City = Letter FROM ( SELECT Number, Letter, ROW_NUMBER() OVER(PARTITION BY Number ORDER BY number ) AS SortOrder FROM TableA WHERE Letter IS NOT NULL AND Letter != '' ) AS A WHERE SortOrder = 1 AND TableB.AC = A.Number; Where do I add this code and format it for it to work in the DataPage?
  9. Thanks so much. How do I make it so that the aircraft number in "(aircraft number) not complete; please process." refers to the number the user typed into the form?
  10. There is a form where user can input aircraft number, and records/results are shown accordingly. When there are no records found, it says "No records found". However, I want the text to say "(aircraft number) not complete; please process." How do you do this? Thanks for any help.
  11. [Please skip to the first comment I made] I have a slightly complicated procedure I'd like to implement. DataPage D's data source is from View V In the Results Page of DataPage D, I'd like to include a field F that's from Table T But Table T is not included in View V. This is a sample Table T: [iD] [fieldF] 1 A 1 1 B 2 2 C 2 2 3 3 This is a sample View V, according to Table T: [iD] [fieldF] 1 A 1 A 1 A 1 A 1 A 1 A 2 C 2 C 2 C 3 3 3 3 3 3 ID from Table T = ID from View V Here is how field F in View V is inputted: The top most field F value for ID 1 is A, so all field F for corresponding ID's will be A. The top most field F value for ID 2 is C (blank is not included), so all field F for corresponding ID's will be C. There are no field F value for ID 3, so all field F for corresponding ID's will be blank. Periodically the top most row will be removed, and then new values will be added, etc. though I'm not sure if that really matters. Now how do I do this? Here are some problems I'm thinking: - There needs to be a way to link Table T's ID with View V's ID, when Table T is not included in View V Here are the steps I'm thinking: 1. In View V, create a new field/column for the Results Page, named fieldF 2. For each ID in View V, select Table T ID's field F 3. Loop through the field F values from top to bottom to search for the top most value, like I explained above. If there are no values, leave blank. 4. Populate all of the View V's field F for each ID ..How do you code this?! Thanks for any help
  12. 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.
  13. I would really appreciate any feedback on this - Here are some other forum threads very similar to this. http://forums.caspio.com/index.php/topic/3488-time-stamp-field-based-on-selection-in-drop-down/ http://forums.caspio.com/index.php/topic/3547-if-then-and-else-for-timestamp/ http://forums.caspio.com/index.php/topic/3567-how-do-you-timestamp-when-the-checkbox-is-checked/ I've tried their code as well, and changing my SupportReady to checkbox, dropdown, etc. and changing the DataType around, but it doesn't seem to be working. Thoughts? This should be relatively simple. Thanks so much
  14. I changed the line to document.getElementById('EditRecordTimestamp').value=datetime; and the Timestamp field is included in the Details Page. But it's not working... Thanks so much for your help so far by the way - I can't thank you enough.
  15. I tried this: <script> function myFunction() { if (document.getElementById('EditRecordSupportReady0').value == 'Y'){ var currentdate = new Date(); var datetime = "Last Sync: " + currentdate.getDate() + "/" + (currentdate.getMonth()+1) + "/" + currentdate.getFullYear() + " " + currentdate.getHours() + ":" + currentdate.getMinutes() + ":" + currentdate.getSeconds(); document.getElementById('Timestamp').value = datetime; } } document.getElementById("caspioform").onsubmit=myFunction(); </script> But it's also not doing it.. I've tried adding it in Footer section, I've tweaked with changing it to ('EditRecordSupportReady')[0], etc. but it doesn't seem to be working... Here are some extra info just in case: Tables SupportReady = Text(255) Timestamp = Date/Time DataPage - Report Results Page SupportReady = Render value as: Text, Formatting: None Timestamp = Formatting: None Details Page SupportReady = Radio buttons HTML Block = where code inputted Anyone have any ideas?
  16. On the Results Page, the column "Timestamp" is the field for timestamp. There is no field for "Timestamp" in the details page, although there could be if necessary. I'm wondering how the code could specify what's shown on Details Page and what's shown on Results Page. In the Tables, I changed the datatype for the "Timestamp" field to Date/Time when it used to be Text(255), but it doesn't seem to be working. Is the code saying that the field "Timestamp" will be changed as soon as "Y" is clicked? How about doing the function when the update button is clicked, or something like document.getElementById("caspioform").onsubmit=myFunction; ?
  17. I'm guessing Details Page, but it still doesn't seem to be working. Here is the link: <http://b4.caspio.com/dp.asp?AppKey=b05320005057b918f4354d1992ba>
  18. An HTML Block after radio buttons and timestamp field would create another field - do I add the HTML Block under Results Page or Detail Page? [edited]
  19. Thanks for the reply. I added this to the "Footer" section of details page on DataPage: <script> document.getElementById('SupportReady').onchange = function() { if (document.getElementById('SupportReady').checked){ var currentdate = new Date(); var datetime = currentdate.getDate() + "/" + (currentdate.getMonth()+1) + "/" + currentdate.getFullYear() + " " + currentdate.getHours() + ":" + currentdate.getMinutes() + ":" + currentdate.getSeconds(); document.getElementById('Timestamp').value = datetime; } } </script> It doesn't seem to be working. One concern I have is the part where it says "checked" - I'm wondering if it knows what it is checked to. How about if I do something like value=="Y"? This is the code I have so far based off of info I got from caspio forums but it also isn't working: <script> function myFunction() { var v = document.getElementById("SupportReady").value; if (v=='Y'){ document.getElementById("Timestamp").value = "[@cbTimestamp]"; } document.getElementById("caspioform").onsubmit=myFunction; </script> This is a Report DataPage. When clicking on details, "SupportReady" has radio buttons with 2 options Display:YES, Value:Y, and Display:NO, Value:N. Default value is N, and when it's updated to Y I want the field "Timestamp" to have a timestamp. In Tables, SupportReady has DataType of "Text(255)".
  20. Hello, In a table, there is a field (field 1) for selecting "Y" or "N", and default is set to N. However, I'd like another field (field 2) for a timestamp when it is updated to "Y". So, somehow field 2 should be connected to field 1, and I've written the following function so far for field 2 through a Data Page: CASE WHEN [@field:NEF_Plan_of_Execution_Material_Support_Required] = 'Y' THEN GetUTCDate() END But it's not getting the timestamp for the exact time when field 1 was clicked "Y"; it's just getting the current server time. Also, when creating a field in a table and assigning a DataType to it, there's an option for "Timestamp" and at the bottom some additional options for "Stamp on Insert" and "Stamp on Update", but there isn't a way to make it tie to another field. How should I go about completing this task of making field 2 a timestamp for when field 1 is updated to Y? Thank you so much
×
×
  • Create New...