I'm going from memory here (since I'm not at my DEV PC), but does not HOST ADDR do this is you give it a string as a dotted IP address?
------------------
Lance
PowerBASIC Support
mailto:[email protected][email protected]</A>
Announcement
Collapse
No announcement yet.
Convert String IP Address (###.###.###.###) into a Long, for use with UDP functions.
Collapse
X
-
Guest repliedInclude wsock32.inc in your app
Code:Function StringToIp( ip As Asciiz ) As Long Function = inet_addr( ip ) End Function
Leave a comment:
-
Guest started a topic Convert String IP Address (###.###.###.###) into a Long, for use with UDP functions.Convert String IP Address (###.###.###.###) into a Long, for use with UDP functions.
Well the subject basically states my question, how do I convert a string IP address (eg: 127.0.0.1) into a Long, since the PowerBasic UDP commands require the IP address to be in the long variable format. Help!
------------------
Tags: None
Leave a comment: