Jump to content

robelliott

Members
  • Posts

    9
  • Joined

  • Last visited

About robelliott

  • Birthday 11/25/1960

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

robelliott's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. I need to do a simple calculation on a datapage and store the result in a field in the table. However the result is not being stored so I'm doing something stupid but can't immediately see what despite looking at the few examples here in the forum. So I hope someone can help me out. The table has a lot of fields, two of which are number (general) fields called Miles and usual_co2. The miles figure is entered into the dataform by the user. The usual_co2 is a cascading listbox based on the type of vehicle they are using. That figure is saved with no problem in the table. I need to multiply the miles by the usual_co2 and store the result in the field calculated_co2 (also a number (general field) when the form is saved. The javascript calculation I have put into the footer of the datapage is: <SCRIPT LANGUAGE="JavaScript"> function calculate() { /* Retrieve the value of the field Miles and store in a variable v_miles */ var v_miles = parseInt(document.getElementById("InsertRecordMiles").value); /* Retrieve the value of the field usual_co2 and store in a variable v_usual_co2 */ var v_usual_co2 = parseInt(document.getElementById("InsertRecordusual_co2").value); /* Multiply the value Miles and usual_co2 to obtain v_calculated_co2 */ var v_calculated_co2=(v_miles*v_usual_co2); document.getElementById("InsertRecordcalculated_co2").value = v_calculated_co2); } document.getElementById("caspioform").onsubmit=calculate; </SCRIPT> Can someone see what is wrong here? Thanks. Rob
  2. "Why are you trying to have your report in an iframe?" Only because on a private Wikidot site (i.e only viewable with the appropriate username and password) the embedded option doesn't work but the iframe option does . As a result with the iframe map markers don't display but they do as soon as the site is made public. This is a Wikidot issue rather than a Caspio one I suspect and I'll investigate further (I provide first line support for Wikidot so should really know what the problem is!). For now it's not a problem as the site I am working on is public and so the embedded code works fine and I don't need to use iframes. I think this new map mashup tool is brilliant.
  3. Due to the platform I work on, Wikidot, datapages cannot be deployed using the default embedded option but are deployed using iframes which works very well. However I have hit a problem trying to get the map mashup v7 beta to work with iframe deployment. Does anyone know if this can be done or whether it only works with the embedded option? Edit: - don't worry, I've got the embedded option to work and now the map mashup works. It was a Wikidot problem: the site needs to be public, not private.
  4. You could iframe the link and put it inside a div with width and margin attributes that will center it on the page, for example: <div style="width:400px; margin:0 auto"> <iframe src="http://b4.caspio.com/dp.asp?AppKey=[i]yourkey[/i]" align="" frameborder="0" height="800px" scrolling="auto" width="400px"></iframe> </div>
  5. You've not said what the problem is. Your table has a Yes/No type. This is OK. The details form has a checkbox. This is also OK. But if you have a search form, make sure you use radio buttons with Yes/No/Any options with the any as the default. Otherwise your search form will use No (unchecked) as the default. and you won't be able to select all records because you will only be able to search on Yes or No on this field.
  6. Paul, the problem is that if the first worker has a datapage open and pulls a number, while they are doing so there is nothing to stop a second worker opening the datapage and also pulling the same number because at that point nothing has been saved. Unfortunately Caspio doesn't lock that first number while it is being used and it only becomes unavailable after the record is saved. I raised this a while back when I developed a database for survey bookings and, like you, discovered that two call centre workers had the same slot (record) open, the first one saved it only to have it over-written by the next when they saved "their" record. It was rare fortunately but very frustrating because there was nothing to indicate that a record had been over-written and the first data was lost. I still haven't come up with a satisfactory solution.
  7. Where we need both a blog and a database on the same site for an intranet, project team or business application we embed the Caspio database in a Wikidot site (http://www.wikidot.com) which also holds the blog. Caspio databases and Wikidot sites work very well together.
  8. I and my users download the resutls set as an XML file and open with Excel. That way it preserves the UK formatting of dates I need.
  9. That doesn't help if you don't know which record a user will need to work on. For an enterprise database it seems an astonishing lack of forethought by the developers that allows one user to open a record and start to enter data, then a second user opens the same record with no warning. The first user saves his data then the second user saves his data - and immediately overwrites the data entered by the first user which is then lost! It has happened to us today. There should be some way built in to prevent the record opening again or at least warn the user, not as a piece of custom programming we have to pay extra for.
×
×
  • Create New...