Create Login Window in C# Using Sql Server

Поділитися
Вставка
  • Опубліковано 28 січ 2025

КОМЕНТАРІ • 336

  • @CodAffection
    @CodAffection  8 років тому +3

    goo.gl/RFY5C2 : Subscribe to CodAffection
    goo.gl/Z6SkSC : C# CRUD Operations With DB
    goo.gl/WsgPbp : C# User Registration With DB
    goo.gl/Gu5q37 : Export PDF in C#

  • @rjcreations6727
    @rjcreations6727 4 роки тому +1

    I am beginner to C#. Search many places. But your explained the working method step by step. Thanks a lot.

  • @SMart-iy7zx
    @SMart-iy7zx 4 роки тому

    even after 4 years it`s a best video. thx man

  • @connief2679
    @connief2679 3 роки тому +6

    OMG! You saved me! Thought I was going to be up all night again trying to finish my project, but this video was SOOO helpful! Thank you, thank you, thank you.

  • @madmac558
    @madmac558 4 роки тому +4

    Tried this for a project i am building, very helpful Thank you. You should upload some recent videos like this of Visual Studio 2019

  • @TarunKumar-ry7bc
    @TarunKumar-ry7bc 2 роки тому

    Thanks man i have windows app interview today thanks a lot

  • @warzhydra990
    @warzhydra990 6 років тому +6

    This helped me a lot😊thank youw❤

  • @earnafterlearn9765
    @earnafterlearn9765 7 років тому

    Best tutorial so far for login authentication..

    • @CodAffection
      @CodAffection  7 років тому

      I am glad you found the video helpful.

  • @ronaldjohnson4470
    @ronaldjohnson4470 6 років тому +12

    Great tutorial, Thank you.

  • @vega7836
    @vega7836 5 років тому

    Thank you very much! My software buyers can now safely use their purchased program!

    • @CodAffection
      @CodAffection  5 років тому

      glad you found the video helpful in your live projects.

    • @digitplays4008
      @digitplays4008 5 років тому +2

      What a load lol, if anyone was buying software it wouldnt be from someone who couldnt make a login form.

  • @Error-vd1yo
    @Error-vd1yo 4 роки тому +3

    please help I am at 17:50, and I get this error no matter what
    System.Data.SqlClient.SqlException: 'Incorrect syntax near the keyword 'Table'.'

  • @ПавелК-й1ж
    @ПавелК-й1ж 5 років тому +2

    Crystal clear! Thanks a lot.

  • @zafersogutcu
    @zafersogutcu 8 років тому

    Thank you very much, it worked perfectly!

  • @yasmine2176
    @yasmine2176 2 роки тому

    thankyou you just saved my life

  • @justjase10
    @justjase10 2 роки тому

    Thanks for the help, it worked🎉

  • @sameeraprasantha4586
    @sameeraprasantha4586 2 роки тому +1

    Thank you.!

  • @georgevetolavman
    @georgevetolavman 7 років тому +2

    Thank you sir! Very good tutorial.

  • @kasyfredy
    @kasyfredy 8 років тому +1

    Your are the Best mate! straightforward and easy to follow the steps, Thanks...

    • @CodAffection
      @CodAffection  8 років тому

      you are welcome, by the way thanks for watching my video

  • @helengargantiel4065
    @helengargantiel4065 2 роки тому +1

    thank you so much! ❤

  • @Cossack3000
    @Cossack3000 6 років тому +7

    Crystal clear. Thanks for the explanation, it really helped!

  • @g3nito409
    @g3nito409 5 років тому +1

    Bro much love for you you helped me a lot i loveyou so much have a great life

    • @CodAffection
      @CodAffection  5 років тому +1

      thanks for the wonderful comment.

  • @YamiKeizerLeon
    @YamiKeizerLeon 7 років тому

    Thanks! Its working :D

  • @WayEngineer
    @WayEngineer 5 років тому +1

    Super gooooood!!! Thank you!)))

  • @Scaramouche122
    @Scaramouche122 4 роки тому

    *YOU ARE THE BEST!!!*

  • @ichbindummwaasduauch6358
    @ichbindummwaasduauch6358 7 років тому +3

    Can you help me? At the saving 8:45 if I click OK at save in into DB it doesnt show in server explorer at tables

    • @nottokyo1401
      @nottokyo1401 3 роки тому +2

      In stead of saving the file, click the UPDATE button in the top left cornor of the window, then you'll get a window where you can click execute query, your table will be added to your database ;)

  • @OwlYaRlyRUS
    @OwlYaRlyRUS 6 років тому +1

    Hi, I have a question. In video, you have one main form. But if I have two, and for each form I have login and password, how I can realize this?
    9:10 - I see, you create here 2 users, but you didn't use 2nd user in code. I try did it - I remade part of code "if(dtbl.Rows.Count == 1)", where I changed 1 to 2 and changed text in braces for my 2nd form and this reworked part I inserted after "else {...}". But when I run the application and enter the data for the second user, Visual Studio opens for some reason the first form. What should I do?

  • @KiKus121
    @KiKus121 Рік тому

    I love u man, thank u :)

  • @simobl8277
    @simobl8277 4 роки тому +1

    this helped me thank you bro

  • @lehlohonolomotloung1167
    @lehlohonolomotloung1167 5 років тому

    This was pretty helpful. Thanks a mill

  • @devmanav6808
    @devmanav6808 7 років тому +1

    Thanks Lot very helpful keep it up !!!

  • @Oom_Sakkie
    @Oom_Sakkie 3 роки тому

    god bless you and your voice

  • @IamRamishka
    @IamRamishka 4 роки тому +1

    Thank You Sir....!!!!

  • @MajidAliRN
    @MajidAliRN 5 років тому +1

    Those having issue with sda.Fill(dt);
    please, check your sda query, the username and password we are using from input in the query should have apostrophes " ' " enclosing them. please, check the code carefully and make sure you add those, and your problem will be solved.

    • @CodAffection
      @CodAffection  5 років тому +1

      thanks for the info . hope you found this C# tutorial helpful.

    • @MajidAliRN
      @MajidAliRN 5 років тому

      @@CodAffection yes sir, your turorial has helped me a lot. Thank you so much !

  • @mpumelelosicelomthethwa4635
    @mpumelelosicelomthethwa4635 6 років тому

    Thanks alot man, very useful!!

  • @bomb4ik
    @bomb4ik 3 роки тому +1

    Thank you

  • @gaborkosa263
    @gaborkosa263 3 роки тому

    sir! thank you!its works fine!

  • @lucasbraga8569
    @lucasbraga8569 6 років тому

    You helped me a lot. Thank you!

  • @leedenbigh
    @leedenbigh 6 років тому +2

    Thank you very much for this.

  • @JulianPrithiviraj
    @JulianPrithiviraj Рік тому

    very useful thanks a lot

  • @sheivongamboa
    @sheivongamboa 4 роки тому +1

    Use secure procedure is better than leaving open SQL query string

  • @JStream
    @JStream 6 років тому

    this still works until now :D

  • @chaitu_ash7600
    @chaitu_ash7600 5 років тому +1

    Thank you for good subject guven for me....i have an doubt I. E., u r creating one table that is login table in database right, in that table first username value is 1 only....y u giving user1 as in username value in login form? 1 and user1 both r same in this situation? Please clarify my doubt as soon as possible. I'm waiting for ur response. Tq

  • @rohithiwale3750
    @rohithiwale3750 8 років тому

    Thank you For helping Others!!!!!!

  • @gizachewadane6262
    @gizachewadane6262 6 років тому +1

    Thank you it has Great tutorial

  • @Rebelvlog07
    @Rebelvlog07 6 років тому +1

    nice uploade more video related windows form

  • @gandhidhamcomputers9664
    @gandhidhamcomputers9664 6 років тому

    Thank you so much for the Code it will help me for life time

    • @CodAffection
      @CodAffection  6 років тому

      Glad you found the video helpful.

    • @ksktamiltech4130
      @ksktamiltech4130 5 років тому

      @@CodAffectionua-cam.com/video/VuAblmhisxc/v-deo.html

  • @mohinisonawane991
    @mohinisonawane991 8 років тому +1

    Thank you so much very helpful :-)

  • @a1994s
    @a1994s 3 роки тому

    thanks a million bro.

  • @techsics5456
    @techsics5456 3 роки тому

    Thanks a lot❤️❤️❤️❤️

  • @akshaygadilkar8994
    @akshaygadilkar8994 7 років тому

    Sir you are the best

  • @blacksmith9259
    @blacksmith9259 4 роки тому

    thank you very very mutch
    God Bless You

  • @bagup_alpharetards
    @bagup_alpharetards 5 років тому

    At 8:40 when i press ctl+s instead of showing a dialoge box that shows in the video like choose name,
    my PC asks to saves the file in my documents or in local disk drive instead of saving it in visual studio like a dialoge box has appeared for the name of the table. Please can someone help. Please.

    • @CyberKittenlol
      @CyberKittenlol 5 років тому

      I think i have the same problem too. I first save a place where in your drive then in the upper-left corner of the Table Designer, select the Update button.
      Then you save it I think(because im trying

  • @RadhaKrishna_777
    @RadhaKrishna_777 4 роки тому

    😍😇 thnk U sO mUch sir !!

  • @atluong6236
    @atluong6236 7 років тому

    Great. Thanks so much :D

  • @PatrosAnime
    @PatrosAnime 2 місяці тому

    7:58 when i clicked new table an error occured called : "An incompatible SQL server version was detected "
    What should i do man?

    • @CodAffection
      @CodAffection  2 місяці тому

      Have you tried this : stackoverflow.com/a/27881800/4133590

  • @farahsghaier9891
    @farahsghaier9891 4 роки тому +2

    Thanks for this tutorial , but I have a problem with the sda.Fill(dtbl).
    ==> System.Data.SqlClient.SqlException: 'An expression of non-boolean type specified in a context where a condition is expected, near 'de'.'
    I have already read the comments and i didn't find the right answer .
    Please answer me as soon as possible.

    • @Killermonktr
      @Killermonktr 2 роки тому

      im stuck there aswell, hope u found an answer after a year xD

  • @bandaraharan9018
    @bandaraharan9018 5 років тому

    It works, Thank you

  • @rw12player39
    @rw12player39 4 роки тому

    nice tutorial

  • @jmdeluxe
    @jmdeluxe 5 років тому +2

    System.Data.SqlClient.SqlException (0x80131904): An attempt to attach an auto-named database for file C: \Users\jmpla\source
    epos\Aqua Lab\DataBase\LoginDB.mdf failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share. HELPPP

  • @kotoriitsuka1097
    @kotoriitsuka1097 7 років тому +1

    8:36 could you explain what do you say there?

    • @CodAffection
      @CodAffection  7 років тому

      Showing how to save the table
      Press Ctrl + S to Save the Table. it will open a dialog box, Name your table inside the dialog box, then click OK.
      Then added sample record into the table.

    • @kotoriitsuka1097
      @kotoriitsuka1097 7 років тому +1

      Thank you for fast answer. I appreciate all work that you put into your videos. It is very helpful. Thank you! :)

  • @truebittech
    @truebittech 4 роки тому +1

    I cant debug it shows 1)The name 'txtusername' does not exist in the current context
    2)The name 'txtpassword' does not exist in the current context
    Plz help what I do

  • @manpreetjohal9033
    @manpreetjohal9033 7 років тому

    You are awesome. This is so helpful.
    How can i get a report that what user at what time/date logged in and logged out?
    Thank you :)

    • @CodAffection
      @CodAffection  7 років тому +2

      I am glad you found the video useful.
      Get Logged In and Out Time
      - Add two additional column of the type date time one for logintime and logouttime
      - During Login Insert DateTime.Now to logintime
      - During Logout Update Current User Last Row - logouttime with DateTime.Now

    • @manpreetjohal9033
      @manpreetjohal9033 7 років тому

      Dotnet Mob Thanks for you reply.
      Where would that log file go once i completed compiling the program.
      Thank you

    • @CodAffection
      @CodAffection  7 років тому +1

      Not a separate file. I mean add two columns in tblUser table. for logintime and logout.
      Or You can keep a separate table - tblUserAudit to store login time and logout time.

    • @manpreetjohal9033
      @manpreetjohal9033 7 років тому

      Dotnet Mob Thank you :)

    • @CodAffection
      @CodAffection  7 років тому

      You are welcome

  • @Hearte12356
    @Hearte12356 8 років тому

    Thank you very much !!!!

  • @rehanfarooq1122
    @rehanfarooq1122 5 років тому

    thanks for this video bro

  • @HANIFASATTAR
    @HANIFASATTAR 3 роки тому

    Very nice person

  • @harikrishnants8545
    @harikrishnants8545 4 роки тому +1

    I"m using Visual studio 2019. I cannot create tables with the steps provided by you. In the Server Explorer under the table it shows nothing.

    • @hackslash834
      @hackslash834 4 роки тому +2

      Don't know if you figured it out or not but I will leave this here for anyone with the same problem. There is an update button at the top of the table you can click on. It will then save it on the existing mdf file. Under the table there is a sql query on that you can edit your table. Make changes here. To see the change or whether your table is created or not you have to rightclick the table folder on the database connection and refresh.

    • @karthiknayak5632
      @karthiknayak5632 4 роки тому +1

      @@hackslash834 ya i fixed the issue thanks for the comment.

    • @CodAffection
      @CodAffection  4 роки тому +1

      thanks for sharing your thoughts.

  • @teach2088
    @teach2088 5 років тому

    thanks bruda

  • @deepikakbify
    @deepikakbify 5 років тому

    Thanks!

  • @spikeisback
    @spikeisback 7 років тому

    System.Data.SqlClient.SqlException: 'An attempt to attach an auto-named database for file C: \Users\sam\Desktop\Passwords And user.mdf failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share.'

    • @CodAffection
      @CodAffection  7 років тому

      try this stackoverflow.com/a/14779107/4133590

  • @SamMeiki
    @SamMeiki 3 роки тому

    Thank you!!!!!

  • @abdelkiki
    @abdelkiki 4 роки тому

    Thank you si much

  • @feeqqaa
    @feeqqaa 6 років тому

    Hi, I'm using VS 2017. Thank you for this video, it is great and so helpful! But I followed exactly as what you have shown but when I entered the right credentials, it will run the else statement still. Do you know how I can fix this? Thank you in advance~!

    • @CodAffection
      @CodAffection  6 років тому

      did you check with break points?

    • @feeqqaa
      @feeqqaa 6 років тому

      CodAffection sorry, but how do I do that?

    • @CodAffection
      @CodAffection  6 років тому

      ua-cam.com/video/FKAOHtxiloA/v-deo.html

  • @sahejnarang8911
    @sahejnarang8911 3 роки тому

    thanks bro

  • @ВалентинаВеремчук-и6у

    thanks a lot :)

  • @Sajidhussain302
    @Sajidhussain302 5 років тому +1

    so sweet

  • @salikomarpatug7024
    @salikomarpatug7024 Рік тому

    Life saver

  • @乔治高老庄
    @乔治高老庄 3 роки тому

    query one record then direct to main form to open but not to match successfully with bool true.

  • @jesvirsubang6725
    @jesvirsubang6725 6 років тому +3

    how can i display the name of the user who logged in to the next form?

    • @jeremychu8922
      @jeremychu8922 5 років тому

      you need the database varible and in textlabel script
      label.text = "varible"

  • @mihaelborak78
    @mihaelborak78 6 років тому

    @Dotnet Mob Hello i need help ! Every time i press login this shows up : Unhandled exception has occurred in your application...... Incorrect syntax near the keyword 'Table' pls help fast cuz i need 2 finish this project in 3 weaks and your tutorials helped me so far

    • @CodAffection
      @CodAffection  6 років тому

      Let me see your query for login operation.

    • @Unreality_3D
      @Unreality_3D 5 років тому +1

      @@CodAffection Hi i have the same problem, my login table is just called Table, also im using VS 2017,
      The Error...
      System.Data.SqlClient.SqlException
      HResult=0x80131904
      Message=Incorrect syntax near the keyword 'Table'.
      Source=.Net SqlClient Data Provider
      StackTrace:
      at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
      at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
      at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
      at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)
      at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData()
      at System.Data.SqlClient.SqlDataReader.get_MetaData()
      at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption, Boolean shouldCacheForAlwaysEncrypted)
      at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest)
      at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry)
      at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)
      at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)
      at System.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior)
      at System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior behavior)
      at System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior)
      at System.Data.Common.DbDataAdapter.Fill(DataTable[] dataTables, Int32 startRecord, Int32 maxRecords, IDbCommand command, CommandBehavior behavior)
      at System.Data.Common.DbDataAdapter.Fill(DataTable dataTable)
      at WindowsFormsApp6.loginFrm.loginBtn_Click(Object sender, EventArgs e) in C:\Users\Gary\source
      epos\WindowsFormsApp6\WindowsFormsApp6\Form1.cs:line 28
      at System.Windows.Forms.Control.OnClick(EventArgs e)
      at System.Windows.Forms.Button.OnClick(EventArgs e)
      at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
      at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
      at System.Windows.Forms.Control.WndProc(Message& m)
      at System.Windows.Forms.ButtonBase.WndProc(Message& m)
      at System.Windows.Forms.Button.WndProc(Message& m)
      at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
      at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
      at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
      at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
      at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr dwComponentID, Int32 reason, Int32 pvLoopData)
      at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
      at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
      at System.Windows.Forms.Application.Run(Form mainForm)
      at WindowsFormsApp6.Program.Main() in C:\Users\User\source
      epos\WindowsFormsApp6\WindowsFormsApp6\Program.cs:line 19
      My Code...
      SqlConnection sqlcon = new SqlConnection(@"Data Source=(LocalDB)\MSSQLLocalDB;AttachDbFilename=C:\Users\User\source
      epos\WindowsFormsApp6\WindowsFormsApp6\Database\LoginData.mdf;Integrated Security=True;Connect Timeout=30");
      string query = "Select * From Table where username ='" + usernameTxt.Text.Trim() + "' and password = '" + passwordTxt.Text.Trim() + "'";
      SqlDataAdapter sda = new SqlDataAdapter(query, sqlcon);
      DataTable dtbl = new DataTable();
      sda.Fill(dtbl);
      if (dtbl.Rows.Count > 0 && dtbl.Rows[0][0].ToString().Equals("1"));
      {
      mainFrm objMainFrm = new mainFrm();
      this.Hide();
      objMainFrm.Show();
      }
      Thanks for the video i really needed this.

  • @nguyenhoanghuy8456
    @nguyenhoanghuy8456 4 роки тому +1

    Good

  • @jaydipgadhiya2265
    @jaydipgadhiya2265 4 роки тому +1

    Server Explore in Data Connections in LoginDB in Table in File do not show.
    Please sir Help me

  • @MuhammadHammad-jj8pe
    @MuhammadHammad-jj8pe 5 років тому

    Iam using vs 2017 but when i ctrl + s to name the table it doesnt open any dialog box and takes me to save it and not showing it in tables ?
    Can you help me out

    • @bunyipimaboy5715
      @bunyipimaboy5715 4 роки тому

      same thing happens to me

    • @lovehunter8278
      @lovehunter8278 4 роки тому

      You may try to save it under the db location and refresh table

  • @kshitijbali6915
    @kshitijbali6915 4 роки тому

    I wrote my code exactly like this, only my table name is /*Signup*/. Upon running the application even after entering correct username and password it is saying check username and password. Please help

  • @HichamBLM
    @HichamBLM 3 роки тому

    Merci 🙂

  • @daniealasyraf9129
    @daniealasyraf9129 7 років тому

    Why this error occur at 'sda.Fill(dtbl)'?
    Exception unhandled
    System.Data.SqlClient.SqlException: 'An attempt to attach an auto-named database for file C: \Users\User\Documents\Visual Studio 2017\Projects\LoginApp\DB\LoginDB.mdf failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share.'

    • @CodAffection
      @CodAffection  7 років тому

      did you download the source code ?

    • @daniealasyraf9129
      @daniealasyraf9129 7 років тому

      Yes... can you teach me how to enter RC4 encryption for the password?

  • @programmer313
    @programmer313 2 роки тому

    Hi sir I have some problem when I write the correct username and password its show not correct I don't know why
    can you help me please?

  • @Vapsiz
    @Vapsiz 7 років тому +4

    this li- HMHHM
    16:06

    • @trok1
      @trok1 4 роки тому

      Lol that load

  • @user-tf7te5fs2n
    @user-tf7te5fs2n 4 роки тому

    How to create it for multi user so every one has different form apperead after logging in??

  • @justinromaine3493
    @justinromaine3493 7 років тому

    How to make it to connect to a website Sql data have I replaced the like url for the database with the remote database but when I hit start it will stop saying like it can't connect but it's connected in visual studio.

    • @CodAffection
      @CodAffection  7 років тому

      you want to connect Live SQL Server Database ?

  • @Ivan-tb1cw
    @Ivan-tb1cw 8 років тому +3

    bakit kapag pinipindot ko yung login ganto nalabas?
    An unhandled exception of type 'System.Data.SqlClient.SqlException' occurred in System.Data.dll
    Additional information: An attempt to attach an auto-named database for file C: \Users\Mercado\Documents\Visual Studio 2015\Projects\GenericoCashieringSystem\GenericoCashieringSystem\LoginDB.mdf failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share.

  • @Ethan-rv1jr
    @Ethan-rv1jr 5 років тому +3

    When he cleared his throat my ears were gone
    zooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooom

  • @algorithms2289
    @algorithms2289 7 років тому

    You must write "tblLogin" between [ ] otherwise it cause error sometimes

    • @CodAffection
      @CodAffection  7 років тому +1

      I don't think so. you have to enclose sql object inside '[ ]' if it contains a space or reserved terms like 'User'. Otherwise it is not necessary. thanks for the comment.

    • @algorithms2289
      @algorithms2289 7 років тому

      Dotnet Mob
      welcome,
      but I try this code without [ ] this caused an error, then I fixed it by write this brackets.

  • @mryan5522
    @mryan5522 4 роки тому

    but the password string anyone can see if they open sql server database. How can convert the password string into some unique symbol in sql server that is not the password we type in the text box?

  • @abigailpartis392
    @abigailpartis392 6 років тому

    I know others have asked, but i cant see the replies. I have an error on the sda.Fill(dtbl), I'm told "A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)" Any tips on how to fix this?

    • @CodAffection
      @CodAffection  6 років тому +1

      ping me at askdotnetmob@gmail.com with possible screen shots.

    • @abigailpartis392
      @abigailpartis392 6 років тому

      Dotnet Mob thank you but I figured it out. Daft mistake on my part 😂😂 thanks for the tutorial. Subbed.

    • @azizkarami5067
      @azizkarami5067 6 років тому

      @Abigail Partis i got the same error can u help me ??

    • @CodAffection
      @CodAffection  6 років тому

      please check your connection string.

  • @yvonne981228ahvon
    @yvonne981228ahvon 7 років тому +2

    i have the problem on sda.Fill(dtbl); , how to solve this problem

    • @imabik2378
      @imabik2378 6 років тому

      Has anyone found the solution to this problem if so please reply asap

    • @kelvinescitnal6223
      @kelvinescitnal6223 6 років тому

      you dont have a conection in your form 2

    • @scrub2657
      @scrub2657 6 років тому

      and how do you fix this?????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????? ty :)

    • @CodAffection
      @CodAffection  6 років тому

      @@scrub2657 Please check db connection string and query string.
      If nothing works leave a message in fb page. let me check what I can do.

    • @singhpranshu3
      @singhpranshu3 6 років тому

      @@CodAffection everything is fine. Just,
      sda.Fill(dtb1);
      is error

  • @n3odemencial30
    @n3odemencial30 3 роки тому

    The name 'ObjFrmMain' not exist at the current context. could you help me please?

  • @renzguinto125
    @renzguinto125 7 років тому

    A network related or instance specific error occured while establishing a connection to sql server. the server was no found or was not accessible. verify that the instance name is correct and that sql server is configured to allow remote connections. proivder sql network interfaces, error 26 error locating server/. instance specified
    I'm getting this problem in adding connection can you help me?

    • @CodAffection
      @CodAffection  7 років тому

      please SQL server connection string.

    • @renzguinto125
      @renzguinto125 7 років тому

      Already fix this thank you i just downloaded the sql server

    • @renzguinto125
      @renzguinto125 7 років тому

      can you help me i want to make my button to add number on text box example if i click the button there will be value in text box
      EXAMPLE: clicked the button textbox value = 1
      clicked the button for the second time the value of textbox 1 will be 2 and so on

    • @CodAffection
      @CodAffection  7 років тому

      If Textbox = txt , Button = btn, (Control Naming)
      txt.Text =(Convert.ToInt32(txt .Text)+ 1).ToString();

  • @fadestutorials106
    @fadestutorials106 6 років тому

    can you do a video on how to do a multi user login

  • @averageanon007
    @averageanon007 5 років тому

    do you still have the "Do not delete" folder in C:/ drive? :p

  • @knowsome3424
    @knowsome3424 6 років тому

    Thanks