| CByte() | ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Byte |
|---|---|
| CInt() | ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Integer |
| CLng() | ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Long |
| CSng() | ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Single |
| CDbl() | ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Double |
| CCur() | ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Currency |
| CStr() | ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด String |
| Cbool() | ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Boolean |
| CDate() | ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Date |
| CVar() | ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Variant |
| IsNumeric() | ใช้ตรวจสอบว่า ตัวแปรนั้น เป็นข้อมูลชนิดตัวเลข หรือไม่ |
| IsDate() | ใช้ตรวจสอบว่า ตัวแปรนั้น เป็นข้อมูลชนิดวันที่หรือเวลา หรือไม่ |
| IsArray() | ใช้ตรวจสอบว่า ตัวแปรนั้น เป็นตัวแปรชนิดArray หรือไม่ |
| IsObject() | ใช้ตรวจสอบว่า ตัวแปรนั้น เป็นตัวแปรชนิด Object หรือไม่ |
function:CByte ( variable )
return type:Byte
content:ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Byte
example:vbtye = CByte ( "B" )
function:CInt ( variable )
return type:Integer
content:ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Integer
example:vint = CInt ( 1200000 )
function:CLng ( variable )
return type:Long
content:ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Long
example:vlong = CLng ( 200 )
function:CSng ( variable )
return type:Single
content:ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Single
example:vsng = CSng ( 200 )
function:CDbl ( variable )
return type:Double
content:ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Double
example:vdbl = CDbl ( 450 )
function:CCur ( variable )
return type:Currency
content:ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Currency
example:vcur = CCur ( "Bamboo" )
function:CStr ( variable )
return type:String
content:ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด String
example:vstr = CStr ( 500.00 )
function:Cbool ( variable )
return type:Boolean
content:ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Boolean
example:vbool = Cbool ( 1 )
function:CDate ( variable )
return type:Date
content:ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Date
example:vdate = CDate ( "8 มกราคม 2553" )
function:CVar ( variable )
return type:Variant
content:ใช้แปลง ชนิดตัวแปร ให้เป็น ตัวแปรชนิด Variant
example:vvar = CVar ( "Bamboo" )
function:IsNumeric ( variable )
return type:Boolean
content:ใช้ตรวจสอบว่า ตัวแปรนั้น เป็นข้อมูลชนิดตัวเลข หรือไม่
example:If IsNumeric ( 500.00 ) Then MsgBox “This is numeric”
function:IsDate ( variable )
return type:Boolean
content:ใช้ตรวจสอบว่า ตัวแปรนั้น เป็นข้อมูลชนิดวันที่หรือเวลา หรือไม่
example:If IsDate ( "8 มกราคม 2553" ) Then MsgBox “This is date"
function:IsArray ( variable )
return type:Boolean
content:ใช้ตรวจสอบว่า ตัวแปรนั้น เป็นตัวแปรชนิดArray หรือไม่
example:If IsArray ( "Bamboo" ) Then MsgBox “This is array"
function:IsObject ( variable )
return type:Boolean
content:ใช้ตรวจสอบว่า ตัวแปรนั้น เป็นตัวแปรชนิด Object หรือไม่
example:If IsObject ( "BambooLabCode" ) Then MsgBox “This is object"