Code: 
  
  $bitstring=unpack(b16,$flags);
  print "Bitstring is $bitstring\n";  #  1000110000101100  for 1414

HTH :)

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Jim
Hill
Sent: Tuesday, January 27, 2004 1:42 PM
To: [EMAIL PROTECTED]
Subject: Checkboxes


Hi all

The [subscribers] section in the .cfg file of my mailing list
manager gives a flag value for each subscriber ...

Flags=1414

... which is linked to a set of gui checkboxes - some, but not
all, of which are mutually exclusive. Checking each option in
turn and monitoring the .cfg file results in this table ...

   0   no flags set
   1   subscriber is suspended
   2   receives list messages
   4   posts lists messages
   8   subscriber is list administrator
  16   subscriber is moderated
  32   subscriber is barred
  64   receives multipart/mixed digests
 128   receives binaries
 256   posts binaries
 512   receives multipart/digest digests
1024   receives text/plain digests
2048   public membership
4096   concealed subscription address
8192   force text/plain posts

Is there a module or a perl algorithm for determining which of
the 14 checkboxes are enabled from a "Flags=" value?

_______________________________________________
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

_______________________________________________
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to