[AccessD] Is there a simpler way?

Rocky Smolin rockysmolin2 at gmail.com
Tue Jul 12 21:33:02 CDT 2022


Yeah, I effed that one up.

r

On Tue, Jul 12, 2022 at 5:50 PM Arthur Fuller <fuller.artful at gmail.com>
wrote:

> >> Clarity is it's own reward.
> Reverting to another thread, this is an example of the incorrect use of
> "it's". In this context, it ought to have been "its". The rule is simple:
> expand any occurrence of "it's" to "it is" and see if the sentence still
> makes sense. If not, you're using the wrong one.
>
> On Tue, Jul 12, 2022 at 8:36 PM Rocky Smolin <rockysmolin2 at gmail.com>
> wrote:
>
> > Yes.  Ugly.  But in compensation it is perfectly understandable,
> readable,
> > maintainable. By any programmer. And five years from now you won't be
> > trying to figure out what this code does as opposed to 'clever' code.
> > Clarity is it's own reward.
> >
> > r
> >
> > On Tue, Jul 12, 2022 at 3:46 PM John Colby <jwcolby at gmail.com> wrote:
> >
> > > I need a text enum (colors to be specific).  Enums are longs.  Sigh
> > >
> > > Public Enum enumVBColors
> > >     Black = vbBlack
> > >     Red = vbRed
> > >     Green = vbGreen
> > >     Yellow = vbYellow
> > >     Blue = vbBlue
> > >     Magenta = vbMagenta
> > >     Cyan = vbCyan
> > >     White = vbWhite
> > > End Enum
> > >
> > > Function fColor(intColor As enumVBColors) As String
> > >     Select Case intColor
> > >     Case enumVBColors.Black
> > >         fColor = "Black"
> > >     Case enumVBColors.Blue
> > >         fColor = "Blue"
> > >     Case enumVBColors.Cyan
> > >         fColor = "Cyan"
> > >     Case enumVBColors.Green
> > >         fColor = "Green"
> > >     Case enumVBColors.Magenta
> > >         fColor = "Magenta"
> > >     Case enumVBColors.Red
> > >         fColor = "Red"
> > >     Case enumVBColors.White
> > >         fColor = "White"
> > >     Case enumVBColors.Yellow
> > >         fColor = "Yellow"
> > >     End Select
> > > End Function
> > >
> > > Does the trick but DAMN!  I can use these text strings as colors in the
> > > HTML tags.  But DAMN!  I hate ugly and this is just ugly.
> > >
> > > Let the slappin' commence.
> > >
> > > --
> > > John W. Colby
> > > Colby Consulting
> > > --
> > > AccessD mailing list
> > > AccessD at databaseadvisors.com
> > > https://databaseadvisors.com/mailman/listinfo/accessd
> > > Website: http://www.databaseadvisors.com
> > >
> > --
> > AccessD mailing list
> > AccessD at databaseadvisors.com
> > https://databaseadvisors.com/mailman/listinfo/accessd
> > Website: http://www.databaseadvisors.com
> >
>
>
> --
> Arthur
> --
> AccessD mailing list
> AccessD at databaseadvisors.com
> https://databaseadvisors.com/mailman/listinfo/accessd
> Website: http://www.databaseadvisors.com
>


More information about the AccessD mailing list