Home > dev > api > name > gb.error 
 en fr de es it pl pt pt_BR mk sq ca hu cs tr ar fa id vi ko ja ru zh zh_TW eo
Voorgaande  Volgende  Bewerken  Hernoemen  Undo  Search  Administratie  
Handleiding  
Waarschuwing Deze pagina is niet vertaald.  Zie Engelse versie 
GB.Error
void * GB.Error ( const char * error , ... )

Tells the interpreter that the current method or property must raise an error.

This functions does not send any exception. You must return explicitely after calling GB.Error if you want to abort the method or property.

Voorbeeld

/* This comes from the implementation of Table.Fields.Find in the database component */

BEGIN_METHOD(CFIELD_find, GB_STRING name)

  ...

  if (THIS->create
      || !THIS->driver->Field.Exist(THIS->db->handle, THIS->table, field))
  {
    GB.Error("Unknown field: &1.&2", THIS->table, field);
    return;
  }

  ...

END_METHOD