Show/Hide Toolbars

PerfectApps™ Help Guide

The View method retrieves data for the app instance specified by instanceId.

 

int View(string tokenIn, int instanceId, out tokenOut, out FirstTest instance);

 

Send Params

Return Params

instanceId - This is the unique app instance ID for which data will be returned.

tokenIn - This is the security token that is obtained by the previous API call. See the API Security topic for more details.

instance - This is an instance of the actual data instance object. Each property of this corresponds to an app field. You can set these individual fields from your code and then pass the entire object to the Add method so the newly created app instance is properly populated with your field data. The actual type is different for each app as it represents the objects on the app.

tokenOut - This is the new security token that should be used for the next Web Service call after this one. See the API Security topic for more details.

 

 

Sample Code

 

private void ButtonView_Click(object sender, EventArgs e)

{

 PerfectApps.FirstTestService service;//declare

 service = new SDKTest1.PerfectApps.FirstTestService();//instantiate

 string tokenIn = "jAgAgEgAggAAAgwA";

 PerfectApps.FirstTestinstance;

 int instanceId=1;

 string tokenOut;

 int errorCode;

 errorCode = service.View(tokenIn, instanceId, out tokenOut, out instance);

 if (errorCode == 0)

 {

         MessageBox.Show("First name:" +instance.Page_1_First_Name);

 }

 else

 

         MessageBox.Show("Error " + errorCode.ToString() + " encountered!");

 }

}

 

 

Return to: App API Methods, Integration