The world is currently online!


Welcome to Emps-World!

Register now to gain access to all of our forum features. Once registered and logged in, you will be able to create topics, post replies, send private messages, manage your profile, chat with other players in the shoutbox and much more. Once you sign in, this message will disappear.



Pages: 1
0 Members and 1 Guest are viewing this topic.

Offline Knight Night

  • *
  • 198
  • Liked: 18 times
  • +0/-0
  • What are you looking at?
    • View Profile
Writing e-mail with #C
« on: March 21, 2016, 04:39:51 pm »
Hello,

So if anyone can help me with this it would be really appreciated, so basically a user will be asked to write his e-mail address, and if there's a mistake by the e-mail form, it should ask him back to re-type it
example for a complier:
Type your e-mail address:
naseem1@hotmailcom
invalid input, please try again.
naseem1@hotmail.com
press any key to....

Thanks.

Offline Kaarel 123

  • *
  • 661
  • Liked: 377 times
  • +0/-0
  • mak merica grate agen Ȃ̴̍͐͆̓̌̀̓̈̋̈̌̇̀͛̈́̉̈̒͒͘̕̚͝͝͠
    • View Profile
Re: Writing e-mail with #C
« Reply #1 on: March 24, 2016, 08:55:39 pm »
I think the easiest way would be to check if the email is containing an at sign (@) and a dot (.). Do you need specific code or is the logic enough for you?

Ȃ̴̛̛̰̤̘͉̍͐͆̓̌̀̓̈̋̈̌̇̀͛̈́̉̈̒͒̋̂́̍̽̈̔̉̑̐͋̐̾͛̎̄͛́̈́̅͐͋̃͋̿͂͂͛̋͛̆͊̐̋͗͒͊͋̈́͛͑͑̉̉͒͌͆̾̂̈́̋̆̍̓̊̄̑̈͒̒͆͑̋̿̄͌͒͛́̑̿̑͗̇͋̈́̅̎̍͘̕̚̚͘͘͘̚̚̚̕͝͝͠͝͝͝͝͝
̶̡̡̨̢̨̨̨̢̢̡̢̛̛̛̙̟̗͎͍̞̪̖͙͓͖̥̗̲̬̫̬̝͉͔͍̻̹̙͕̱̮̲̺̭͉͔̹̖̮̖͖̳͉̩͙̲͚̝̲̺̥̬̰̝͙̤̭͕̝̯̺͔͎̜̳͙̖̫͉͉̗͉̱̭̗̱̦̭̹̗͓̤̟̻̞͂͌̌́̀̌̾͊̅̾̊̅̈́̈́͂̆̔̊̑̂̽̔̌̀͗̈́̃͆͗̌́̀͋̈̌͗̐͌̃̌͒̏̆̊͆̓̊̀͒̑̈̀̈́͑̏̋͆̇̈́̽̍̽̃̾̔̈́̀̾̈́͂̌̈́̐̃̊̀̌̇̾͛̽̽́̌̓̅̉̓̎̊̄̇̓̈́̎́̿̍͂̑̌̂̀̔̏͛̆͒͛̃̌̋͘̕̚̚͘͘͜͜͝͝͝͝ͅͅ
The following users liked this post: Knight Night

Offline Knight Night

  • *
  • 198
  • Liked: 18 times
  • +0/-0
  • What are you looking at?
    • View Profile
Re: Writing e-mail with #C
« Reply #2 on: March 25, 2016, 06:26:00 pm »
I think the easiest way would be to check if the email is containing an at sign (@) and a dot (.). Do you need specific code or is the logic enough for you?

I'd understand what you referring for but could you show me a specific code if you can, and thanks.

Offline Kaarel 123

  • *
  • 661
  • Liked: 377 times
  • +0/-0
  • mak merica grate agen Ȃ̴̍͐͆̓̌̀̓̈̋̈̌̇̀͛̈́̉̈̒͒͘̕̚͝͝͠
    • View Profile
Re: Writing e-mail with #C
« Reply #3 on: March 27, 2016, 08:43:30 am »
Put this under a button click code

Code: [Select]
if(textbox.Text.Contains(.) && textbox.Text.Contains(@) && textbox.Text.Length > 0){
Correct email}
else{Incorrect email}

You'll have to change 'textbox' to the textbox that the email will be written in.

Ȃ̴̛̛̰̤̘͉̍͐͆̓̌̀̓̈̋̈̌̇̀͛̈́̉̈̒͒̋̂́̍̽̈̔̉̑̐͋̐̾͛̎̄͛́̈́̅͐͋̃͋̿͂͂͛̋͛̆͊̐̋͗͒͊͋̈́͛͑͑̉̉͒͌͆̾̂̈́̋̆̍̓̊̄̑̈͒̒͆͑̋̿̄͌͒͛́̑̿̑͗̇͋̈́̅̎̍͘̕̚̚͘͘͘̚̚̚̕͝͝͠͝͝͝͝͝
̶̡̡̨̢̨̨̨̢̢̡̢̛̛̛̙̟̗͎͍̞̪̖͙͓͖̥̗̲̬̫̬̝͉͔͍̻̹̙͕̱̮̲̺̭͉͔̹̖̮̖͖̳͉̩͙̲͚̝̲̺̥̬̰̝͙̤̭͕̝̯̺͔͎̜̳͙̖̫͉͉̗͉̱̭̗̱̦̭̹̗͓̤̟̻̞͂͌̌́̀̌̾͊̅̾̊̅̈́̈́͂̆̔̊̑̂̽̔̌̀͗̈́̃͆͗̌́̀͋̈̌͗̐͌̃̌͒̏̆̊͆̓̊̀͒̑̈̀̈́͑̏̋͆̇̈́̽̍̽̃̾̔̈́̀̾̈́͂̌̈́̐̃̊̀̌̇̾͛̽̽́̌̓̅̉̓̎̊̄̇̓̈́̎́̿̍͂̑̌̂̀̔̏͛̆͒͛̃̌̋͘̕̚̚͘͘͜͜͝͝͝͝ͅͅ
Pages: 1