How to Typecaste a PChar to a longint?



How to Typecaste a PChar to a longint?..

Answer / Ravi Prakash Srivastava

To cast a `PChar` to a `longint` in Delphi, you can use the `PackedDec` function. Here's an example:nn```delphinlValue: PAnsiChar; // Assuming lValue points to a longint stringnlResult: longint;nBeginn PackedDec(lValue^, Result);nEnd;n```

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Delphi Interview Questions

How do I write a global error handler?

1 Answers  


How to Get a cool menu in your application?

1 Answers  


Where can I get a copy of Delphi?

1 Answers  


How to Use JPEGs from resource files ?

1 Answers  


How to Launch default browser on a URL?

1 Answers  


What is the function of dynamic arrays?

1 Answers  


How to Move a control at runtime with the mouse?

1 Answers  


How to Get the local internet machine name and IP address?

1 Answers  


What version of Delphi 5 does the Code Explorer come with?

1 Answers  


Does Kylix support ODBC?

1 Answers  


What is the target load order?

1 Answers  


What to do if getting missing or corrupted file messages?

1 Answers  


Categories