T
Tariq Ahmad
i have an enum, which is defined like this:
enum MyColour
Blue=0
Green
Red
end enum
i have a function declared like this:
function ProcessColours(col as MyColour)
....
end function
i want to able to call my function like this: ProcessColours("Blue")
instead of ProcessColours(MyColour.Blue)
how can i do this???
if u are wondering why then here it is:
ProcessColours is actually a webmethod, when i go to test this method
i see:
<Colour>BLUE or GREEN or REDCode>
i like this cause it tells the consumer what the methos expects as input.
but when i call the method like this: ProcessColours("BLUE") it complains
that
it cannot convert string to integer .....
thnx for ur help.
t.
enum MyColour
Blue=0
Green
Red
end enum
i have a function declared like this:
function ProcessColours(col as MyColour)
....
end function
i want to able to call my function like this: ProcessColours("Blue")
instead of ProcessColours(MyColour.Blue)
how can i do this???
if u are wondering why then here it is:
ProcessColours is actually a webmethod, when i go to test this method
i see:
<Colour>BLUE or GREEN or REDCode>
i like this cause it tells the consumer what the methos expects as input.
but when i call the method like this: ProcessColours("BLUE") it complains
that
it cannot convert string to integer .....
thnx for ur help.
t.