Jump to content

Large Case Statment?


Recommended Posts

I need to make a script that checks for a number and then returns information based on that number.

I have a couple hundred numbers and text to go with each number.. ie:

212   bob
213   bill

I need it to search for the number then display the text that is part of that number with _filewritelog

Is there anyway to do this without using lame ini files or a giant Select statement.

Select
   Case $num = 1 
        _FileWriteLog(..)
   Case $num = 2 
        _FileWriteLog(..)
   Case $num = 3 
        _FileWriteLog(..)
EndSelect

making a giant case statement would be horrific since I am looking at hundreds of numbers.

Link to comment
Share on other sites

I need to make a script that checks for a number and then returns information based on that number.

search the forum (v3 Scripts and Scraps) for "+Hash +Table +UDF". mrider has written some hash functions that might help you.

Cheers

Kurt

__________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...