SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 3 of 3
  1. #1
    Points for Confirmed Friends
    Guest

    STRING to INTEGER (SILKTEST)

    How can we Cast String to Integer;

    i am retriving value from excel sheet, (M1=22000);

    Ex:
    [ ] hstmnt = DB_ExecuteSql (hdbc, "SELECT M1 FROM `Sheet1$` WHERE CALM='CONSTANT 78'")
    [-] while (DB_FetchNext (hstmnt, M1 ))
    [ ] INTEGER iCON=M1


    [ ] INTEGER iCON=M1-----Type Mismatch Error"


    Here M1 returns "STRING"..... But for my process i need to convert into INTEGER.




    ------------------

  2. #2
    Senior Member
    Join Date
    Jul 2001
    Location
    Elizabeth, CO, USA
    Posts
    653
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: STRING to INTEGER (SILKTEST)

    Val is the function that converts a STRING into an INTEGER or a REAL.

    If you try typecasting (e.g.- i = [INTEGER]"foo") you'll get the ASCII value of the first character of the string. (In the example above, you'll get 102.)

    - Dave


    ------------------
    Amelior Technology
    dreed@ameliortech.com
    WaltzingRhino.com
    A concerned Borland customer, a fly in the ointment, a wrench in the works.

  3. #3
    Points for Confirmed Friends
    Guest

    Re: STRING to INTEGER (SILKTEST)

    Thanks Mr.dcreed......


    ------------------

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Search Engine Optimisation provided by DragonByte SEO v2.0.40 (Pro) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
Resources saved on this page: MySQL 12.50%
vBulletin Optimisation provided by vB Optimise v2.7.1 (Pro) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.3.0 (Pro) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
vBNominate (Lite) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 05:36 PM.

Copyright BetaSoft Inc.