Copia del wikiespejo

Este es un espejo del wiki de pascal.chat. La edición, el historial y el inicio de sesión están allí.

PChar/es

Deutsch · English · Español · Français · Русский

Un PChar es un Data type y un Pointer a una cadena terminada en null. La aplicación más importante de PChar es para su interacción con librerías de sistema tales como dll's.

Messagebox:

pascal
var 
  s: String;
begin
  s := 'Test';
  Application.MessageBox( PChar(s)),'Título', MB_OK );
end;

Declaration:

pascal
var 
  p: PChar;

Valid assignments:

pascal
   p := 'Esto es una cadena terminada en null.';
   p := IntToStr(45);

Argumentos no válidos:

pascal
   p := 45;

El valor integer no se ha caracterizado como PChar que es lo que se esperaba.

Ver también


From the Free Pascal wiki, page "PChar/es", as it stood on 2021-09-03 after a change by Kai Burghardt, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's Licensing page. If you have concerns about this material, message the admin.

Revisión 1, último cambio por WikiArchive .