Quick Search for:  in language:    
Purpose,code,togive,alternative,TOLOWER,TOUPP
   Code/Articles » |  Newest/Best » |  Community » |  Jobs » |  Other » |  Goto » | 
CategoriesSearch Newest CodeCoding ContestCode of the DayAsk A ProJobsUpload
.Net Stats

 Code: 157,764. lines
 Jobs: 478. postings

 How to support the site

 
Sponsored by:

 
You are in:
 
Login





Latest Code Ticker for .Net.
Click here to see a screenshot of this code!Weather Buddy
By Roger Martin on 1/28

(Screen Shot)

On The Fly Image Resizing, And Saveing
By Chris Hood on 1/27


Click here to see a screenshot of this code!Zip/View Project
By Mähr Stefan on 1/27

(Screen Shot)

Quick Audit
By Thomas Michael McGeown on 1/27


Click here to see a screenshot of this code!Kill Timer
By Adam( ) on 1/26

(Screen Shot)

Fibonacci Function
By Paddy Pasqualmie on 1/25


ID3v1.1 Reader
By Lewis Moten on 1/25


Click here to see a screenshot of this code!Lotto Picker
By Mick Doherty on 1/24

(Screen Shot)

Load a PopUnder using InternetExplore r
By Norberto Olazabal on 1/23


Click here to put this ticker on your site!


Add this ticker to your desktop!


Daily Code Email
To join the 'Code of the Day' Mailing List click here!

Affiliate Sites



 
 
   

ALTERNATIVE TOUPPER AND TOLOWER FUNCTIONS

Print
Email
 

Submitted on: 12/15/2003 3:20:55 AM
By: barkın ünüulu  
Level: Beginner
User Rating: By 2 Users
Compatibility:VB.NET

Users have accessed this code 608 times.
 

 
     Purpose of this code is togive an alternative to the TOLOWER and TOUPPER methods vb.net uses...
 
code:
Can't Copy and Paste this?
Click here for a copy-and-paste friendly version of this code!
 
Terms of Agreement:   
By using this code, you agree to the following terms...   
1) You may use this code in your own programs (and may compile it into a program and distribute it in compiled format for languages that allow it) freely and with no charge.   
2) You MAY NOT redistribute this code (for example to a web site) without written permission from the original author. Failure to do so is a violation of copyright laws.   
3) You may link to this code from another website, but ONLY if it is not wrapped in a frame. 
4) You will abide by any additional copyright restrictions which the author may have placed in the code or code's description.

    //**************************************
    //     
    // Name: ALTERNATIVE TOUPPER AND TOLOWER
    //     FUNCTIONS
    // Description:Purpose of this code is t
    //     ogive an alternative to the TOLOWER and 
    //     TOUPPER methods vb.net uses...
    // By: barkın ünüulu
    //
    //This code is copyrighted and has    // limited warranties.Please see http://
    //     www.Planet-Source-Code.com/vb/scripts/Sh
    //     owCode.asp?txtCodeId=1890&lngWId;=10    //for details.    //**************************************
    //     
    
    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
    Dim a As String
    Dim h As String
    Dim f As String
    Dim b As String
    Dim c As Long
    Dim i As Long = 1
    Dim m As New MakeBigOrLittle()
    Dim k As String
    Dim z As String
    b = TextBox1.Text
    c = Len(b)
    Do
    a = Microsoft.VisualBasic.Left(b, 1)
    h = Microsoft.VisualBasic.Right(b, c - i)
    'b = ""
    b = h
    f = m.ToBig(a)
    ListBox1.Items.Add(f)
    i = i + 1
    Loop While i < c
    'Console.ReadLine()
    'Console.ReadLine()
    k = Microsoft.VisualBasic.Right(b, 1)
    z = m.ToBig(k)
    ListBox1.Items.Insert(c - 1, z)
    End Sub
    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
    Dim a As String
    Dim h As String
    Dim f As String
    Dim b As String
    Dim c As Long
    Dim i As Long = 1
    Dim m As New MakeBigOrLittle()
    Dim k As String
    Dim z As String
    b = TextBox1.Text
    c = Len(b)
    Do
    a = Microsoft.VisualBasic.Left(b, 1)
    h = Microsoft.VisualBasic.Right(b, c - i)
    'b = ""
    b = h
    f = m.ToLittle(a)
    ListBox1.Items.Add(f)
    i = i + 1
    Loop While i < c
    'Console.ReadLine()
    'Console.ReadLine()
    k = Microsoft.VisualBasic.Right(b, 1)
    z = m.ToLittle(k)
    ListBox1.Items.Insert(c - 1, z)
    End Sub
    End Class
    Public Class MakeBigOrLittle
    Dim character As String
    Public Function ToBig(ByVal Str As String)
    Select Case Str
    Case "a"
    character = "A"
    Case "b"
    character = "B"
    Case "c"
    character = "C"
    Case "d"
    character = "D"
    Case "e"
    character = "E"
    Case "f"
    character = "F"
    Case "g"
    character = "G"
    Case "h"
    character = "H"
    Case "i"
    character = "I"
    Case "j"
    character = "J"
    Case "k"
    character = "K"
    Case "l"
    character = "L"
    Case "m"
    character = "M"
    Case "n"
    character = "N"
    Case "o"
    character = "O"
    Case "p"
    character = "P"
    Case "r"
    character = "R"
    Case "s"
    character = "S"
    Case "t"
    character = "T"
    Case "u"
    character = "U"
    Case "v"
    character = "V"
    Case "w"
    character = "W"
    Case "x"
    character = "X"
    Case "y"
    character = "Y"
    Case "z"
    character = "Z"
    End Select
    Return character
    End Function
    Public Function ToLittle(ByVal str As String)
    Select Case str
    Case "A"
    character = "a"
    Case "B"
    character = "b"
    Case "C"
    character = "c"
    Case "D"
    character = "d"
    Case "E"
    character = "e"
    Case "F"
    character = "f"
    Case "G"
    character = "g"
    Case "H"
    character = "h"
    Case "I"
    character = "i"
    Case "J"
    character = "j"
    Case "K"
    character = "k"
    Case "L"
    character = "l"
    Case "M"
    character = "m"
    Case "N"
    character = "n"
    Case "O"
    character = "o"
    Case "P"
    character = "p"
    Case "R"
    character = "r"
    Case "S"
    character = "s"
    Case "T"
    character = "t"
    Case "U"
    character = "u"
    Case "V"
    character = "v"
    Case "W"
    character = "w"
    Case "X"
    character = "x"
    Case "Y"
    character = "y"
    Case "Z"
    character = "z"
    End Select
    Return character
    End Function
    End Class


Other 4 submission(s) by this author

 

 
Report Bad Submission
Use this form to notify us if this entry should be deleted (i.e contains no code, is a virus, etc.).
Reason:
 
Your Vote!

What do you think of this code(in the Beginner category)?
(The code with your highest vote will win this month's coding contest!)
Excellent  Good  Average  Below Average  Poor See Voting Log
 
Other User Comments
12/15/2003 10:35:12 AM:undercodex
Making ascii code shifting will be a 
faster solution instead of this case 
statements.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
12/16/2003 4:18:37 AM:Garfield_x
why should we use this if the vb.net 
function is much faster and easier to 
use??
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
12/16/2003 5:47:42 AM:Ken Harvey
you+have+to+be+joking%3F+learn+the+%2ENE
T+Framework+and+stick+to+the+String%2ETo
Upper%28%29+and+String%2EToLower%28%29+s
hared+methods%2E
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
12/16/2003 5:49:47 AM:Ken Harvey
you have to be joking. learn the .NET 
Framework and stick to the 
String.ToUpper() and String.ToLower() 
shared methods. -- saying that, well 
done on your beginner submission.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
Add Your Feedback!
Note:Not only will your feedback be posted, but an email will be sent to the code's author in your name.

NOTICE: The author of this code has been kind enough to share it with you.  If you have a criticism, please state it politely or it will be deleted.

For feedback not related to this particular code, please click here.
 
Name:
Comment:

 

Categories | Articles and Tutorials | Advanced Search | Recommended Reading | Upload | Newest Code | Code of the Month | Code of the Day | All Time Hall of Fame | Coding Contest | Search for a job | Post a Job | Ask a Pro Discussion Forum | Live Chat | Feedback | Customize | .Net Home | Site Home | Other Sites | About the Site | Feedback | Link to the Site | Awards | Advertising | Privacy

Copyright© 1997 by Exhedra Solutions, Inc. All Rights Reserved.  By using this site you agree to its Terms and Conditions.  Planet Source Code (tm) and the phrase "Dream It. Code It" (tm) are trademarks of Exhedra Solutions, Inc.