Passing parameter in method and return values in Java for Selenium Webdriver

แชร์
ฝัง
  • เผยแพร่เมื่อ 9 พ.ย. 2024

ความคิดเห็น • 91

  • @monicagoyal8225
    @monicagoyal8225 3 ปีที่แล้ว +2

    Thanks alot Mukesh. It cleared almost all my doubts.Now I can practice POM videos also created of you.

    • @Mukeshotwani
      @Mukeshotwani  3 ปีที่แล้ว +1

      Thank u Monica I am glad it helped you. I really appreciate that you are spending your weekend time on learning and it will always pay off in long run.

    • @monicagoyal8225
      @monicagoyal8225 3 ปีที่แล้ว +1

      @@Mukeshotwani thanks.Seriously want to learn it and passionately referring all the content shared by you.

    • @Mukeshotwani
      @Mukeshotwani  3 ปีที่แล้ว

      @@monicagoyal8225 I will try my best to assist you. Best of luck Monica 👍

    • @monicagoyal8225
      @monicagoyal8225 3 ปีที่แล้ว +1

      @@Mukeshotwani So nice of you. Actully need your help as I am laid off followed by Covid downsizing and just want to persue something in technical field only now.
      Glad to see your profile somewhere as we too have been in Bhopal and relocated to indore last year.

    • @Mukeshotwani
      @Mukeshotwani  3 ปีที่แล้ว

      Let’s connect mukeshotwani@learn-automation.com

  • @kaushikmishra2167
    @kaushikmishra2167 4 ปีที่แล้ว +1

    थैंक यू मुकेश। काफ़ी अच्छा और महत्वपूर्ण सेशन था ये।

    • @Mukeshotwani
      @Mukeshotwani  4 ปีที่แล้ว

      Thank you so much Mishra ji...

  • @anjalirawat5599
    @anjalirawat5599 5 ปีที่แล้ว +1

    Thanks...again :) for sharing these minute informations as well which make us stuck in coding for hours

  • @remyaabraham8403
    @remyaabraham8403 7 ปีที่แล้ว +1

    Thank You So Much Mukesh for creating such awesome videos! Appreciate your hardwork behind this

  • @narentalluri
    @narentalluri 7 ปีที่แล้ว

    Thank you Mukesh.. your explanation is very good..i follows your selenium videos..good job.

  • @vasantalkieschannel
    @vasantalkieschannel 7 ปีที่แล้ว +1

    Such an awesome crisp and crystal clear explanation sir!!! Hats off!!! To be frank, i have seen multiple tutorials, but none explain with such clarity. You know how to make people understand. Keep rocking :)

    • @Mukeshotwani
      @Mukeshotwani  7 ปีที่แล้ว

      Thanks a ton Krirhivasan Krithivasan :) Keep learning and let me know if any help from my side.

    • @vasantalkieschannel
      @vasantalkieschannel 7 ปีที่แล้ว

      Just sharing your knowledge is the biggest help :) keep rocking!!!

  • @mangeshagwan1875
    @mangeshagwan1875 2 ปีที่แล้ว +1

    Wonderful explanation 👌👌👌thank you sir

    • @Mukeshotwani
      @Mukeshotwani  2 ปีที่แล้ว

      You're most welcome Mangesh

  • @suriyaprabhasathishkumar8420
    @suriyaprabhasathishkumar8420 4 ปีที่แล้ว

    How to get dynamic input? or read from file and perform operations. you are so good, to the point teacher

  • @yogeshsangle6333
    @yogeshsangle6333 6 ปีที่แล้ว

    Mukesh Buddy... You have good skill that how to make things easy for others !!!!

  • @AksharaMartur
    @AksharaMartur 7 ปีที่แล้ว +1

    really great videos of you mukesh..great way of explanation..including your all selenium classes excellent.

  • @kabirahmed8552
    @kabirahmed8552 7 ปีที่แล้ว +1

    Awesome explanation. I love your teaching style....thumbs up.

    • @Mukeshotwani
      @Mukeshotwani  7 ปีที่แล้ว

      Thanks kabir Keep learning.

  • @adityashastri9864
    @adityashastri9864 3 ปีที่แล้ว

    Hi Mukesh , can you please also add how pass value to the parameters runtime (from users). Thanks helpful content and examples

  • @theRandom_Guy151
    @theRandom_Guy151 3 ปีที่แล้ว +1

    Thank you so much for clearing the concept. I have a doubt about how can we pass an array as a parameter in java and also return it. Can you please help in this?

    • @Mukeshotwani
      @Mukeshotwani  3 ปีที่แล้ว

      Hi Dipankar, try below sample code.
      Return type is Object[] and accept parameter is String []
      public Object[] getName(String []arg)
      {
      Object[] arr=new Object[5];
      return arr;
      }

  • @AwanishSinghSengar
    @AwanishSinghSengar 7 ปีที่แล้ว +1

    Its really very helpful Mukesh..Thanks a lot for clearing doubts :)

    • @Mukeshotwani
      @Mukeshotwani  7 ปีที่แล้ว

      Thanks Awanish
      I am glad you liked my videos. Keep visiting and let me know if any help required from my side.

  • @mayuriingale8245
    @mayuriingale8245 7 ปีที่แล้ว +1

    Mukesh Great going ...all the videos are really awesome..thank you so much :)

    • @Mukeshotwani
      @Mukeshotwani  7 ปีที่แล้ว

      I am glad it is helping you. You can also join our fb group for any query.
      facebook.com/groups/256655817858291/

  • @sanahpatel9460
    @sanahpatel9460 7 ปีที่แล้ว

    mukesh how to make preparation for selenium? i like ur videos .i like ur way of teaching .can u suggest me ?

  • @rajreddy813
    @rajreddy813 7 ปีที่แล้ว

    hi sir your teaching excellent but one small suggestion please can uwrite methods before main method and call object after main method this will make people easy to understand and also code looks good.thx

  • @reshmanbanu3711
    @reshmanbanu3711 3 ปีที่แล้ว +1

    Thanks 😊

  • @sanjivp999
    @sanjivp999 6 ปีที่แล้ว

    Thank you very much for your detailed explanation

  • @balajikrishnamurthy4995
    @balajikrishnamurthy4995 6 ปีที่แล้ว

    Great way of explanation

  • @prashantmenon6431
    @prashantmenon6431 7 ปีที่แล้ว

    Hi Mukesh,
    Please explain me when can we use static and non-static methods in selenium webdriver?
    Regards,
    Prashant

  • @mozzamelrupon1964
    @mozzamelrupon1964 7 ปีที่แล้ว +1

    your are pretty awesome virtual instructor .

    • @Mukeshotwani
      @Mukeshotwani  7 ปีที่แล้ว

      Thank you Rupon

    • @mozzamelrupon1964
      @mozzamelrupon1964 7 ปีที่แล้ว

      I'm very new this environment, I'm taking selenium course without prior programming knowledge, in Nyc .your video helping us a lot , if you any suggestions will appreciate.thx again

  • @sakshiraina2938
    @sakshiraina2938 5 ปีที่แล้ว +1

    nice one

  • @eshan9217
    @eshan9217 4 ปีที่แล้ว +1

    Hi Mukesh, Can you pls explain what is the importance of static methods in Java. Also why don’t we create all the methods as static, so that there is no need of creating objects to call the variables and methods of a Class?

    • @Mukeshotwani
      @Mukeshotwani  4 ปีที่แล้ว

      Hi Esha,
      Let me explain with an example because it is very interesting and important.
      Let's assume you have static variable WebDriver driver and you want to run test in parallel then it wont execute and it will run test one by one.
      If you do not make variable as static then you can run test in parallel because each time new instance will be created.
      Now lets talk about method- Static methods can access only static variable and non static method can access both the variables.
      I hope it is clear now. If you still have doubt then let me know, I can record video on this.

  • @anilanand100
    @anilanand100 5 ปีที่แล้ว +1

    plzz make video in detail about how to pass parameter using @Parameter in Testng

    • @Mukeshotwani
      @Mukeshotwani  5 ปีที่แล้ว

      Hi Anil, I have explained the same here th-cam.com/video/z3Ruc2bKnqI/w-d-xo.html

  • @praveenkumarr4529
    @praveenkumarr4529 3 ปีที่แล้ว +1

    Thank you

  • @rajasekharmaddigalla1463
    @rajasekharmaddigalla1463 4 ปีที่แล้ว +2

    Hello Mukesh, do we have any way that we can use customized method instead of '.sendkeys( )' (i mean Extension methods in selenium JAVA)

    • @Mukeshotwani
      @Mukeshotwani  4 ปีที่แล้ว

      u can use JavascriptExecutor

  • @chiranjibisahu8092
    @chiranjibisahu8092 7 ปีที่แล้ว

    Hi Mukesh first of all a big thank you for creating such a wonderful video... I just want to know can we use global variables instead of declaring a return type and which is a better approach out of the two ?

    • @RajChahalNsit
      @RajChahalNsit 5 ปีที่แล้ว

      Hi Chiranjibi,
      using global variables is not a good approach as it is against data hiding concepts of OOPs.
      so using return types is a better approach.

  • @dharapatel6774
    @dharapatel6774 8 ปีที่แล้ว +1

    Hi Mukesh,
    you are awesome, Thank you very much.
    public class ThankYouMukesh{
    public static void main(string [ ] args) {
    system.out.println("Thank" "You" "Mukesh" )
    }
    }

    • @Mukeshotwani
      @Mukeshotwani  8 ปีที่แล้ว

      New way for comment. Appreciated :)

  • @akulabhaskar3797
    @akulabhaskar3797 7 ปีที่แล้ว

    Hai Mukesh ,Still some confusion over calling Non static Methods and static methods ,,If we declare variable as static in Non static methods can dos variables can be access all over the class ?

  • @nagagsalka5371
    @nagagsalka5371 8 ปีที่แล้ว

    Thanks, Mukesh

  • @RahulSingh-fo4gx
    @RahulSingh-fo4gx 6 ปีที่แล้ว +1

    Hi Mukesh I am from development background and new to Selenium how can I get Job in Selenium
    What are the things I have to cover?
    I have learned java from your channel is it enough?
    What are the topics I have to cover to clear interview
    I really appreciate your suggestions
    You are doing good Job keep doing

    • @RajChahalNsit
      @RajChahalNsit 5 ปีที่แล้ว

      Hi Rahul,
      I understand that my reply to you must be very late by now, but still i want to share my view on this question as I had the similar queries/doubts some time ago.
      Let me answer each of your questions one by one :
      1. What are the things I have to cover?

      2. What are the topics I have to cover to clear interview
      ?
      Do you mean in Java or in Selenium ?
      3. I have learned java from your channel is it enough?
      Yes, Mukesh's videos should be enough for selenium learning , selenium does not require you to be a Java Master, if you have the basic understanding you can learn.
      I hope this helps.

  • @akulabhaskar3797
    @akulabhaskar3797 7 ปีที่แล้ว

    Hello Mukesh, What if i want to return boolean ,is it poosible ?

  • @tropangdrin
    @tropangdrin 8 ปีที่แล้ว

    Thank you so much Mukesh!!

    • @Mukeshotwani
      @Mukeshotwani  8 ปีที่แล้ว

      Welcome mate.. How u doing?

  • @TheNishi42
    @TheNishi42 6 ปีที่แล้ว +1

    Is there any video available for call by reference and call by value ?

  • @Stories99
    @Stories99 ปีที่แล้ว

    Hello please explain what is return value .im from a completely different stream so i didnt get it

  • @jassimathew9518
    @jassimathew9518 8 ปีที่แล้ว

    Super

  • @vikasvikky3670
    @vikasvikky3670 8 ปีที่แล้ว

    Hi mukesh this may be a silly doubt...but how can we use methods of other class in some other class without using EXTENDS keyword,as you did in dynamic calculator method.........
    thanks in advance

    • @Mukeshotwani
      @Mukeshotwani  8 ปีที่แล้ว

      Yes we can. Either create object of that class and then call or you can create that method as static and then call using dot operator.

    • @user-lc3te3mo1p
      @user-lc3te3mo1p 7 ปีที่แล้ว

      Bro I am getting error without using inheritance.......

  • @akulabhaskar3797
    @akulabhaskar3797 7 ปีที่แล้ว +1

    Hello Mukesh , I am not able to access Methods from other class Though I have created a respective obj to access the methods.

    • @Mukeshotwani
      @Mukeshotwani  7 ปีที่แล้ว +1

      +Akula Bhaskar Hi Akula make sure class and methods are public

    • @akulabhaskar3797
      @akulabhaskar3797 7 ปีที่แล้ว

      public class Paramdemo {
      public static void main(String[] args) {
      Paramdemo obj1=new Paramdemo();
      obj1.sub();
      obj2.sum();
      }
      }
      }
      public class Paramdemo2 {
      public int sum (int a, int b) {
      int c = a + b;
      return c;
      }
      public double sum(double d, double f) {
      double a = d + f;
      System.out.println("Print " + z);
      return a;
      }
      public int sub(int c, int d) {
      int z = c + d;
      return z;
      }
      }

    • @sudhku5218
      @sudhku5218 7 ปีที่แล้ว

      This is the correct code :
      public class methodDemo {
      public static void main(String[] args) {
      methodDemo obj1=new methodDemo();
      int x = obj1.sub(15, 10);
      System.out.println("Subtraction "+x);
      int y = obj1.sum(100, 15);
      System.out.println("Addition "+y);
      }
      public int sum (int a, int b) {
      int c = a + b;
      return c;
      }
      public double sum(double d, double e) {
      double f = d + e;
      return f;
      }
      public int sub(int g, int h) {
      int i = g - h;
      return i;
      }
      }

    • @soujanyaambati4251
      @soujanyaambati4251 5 ปีที่แล้ว

      @@akulabhaskar3797 u have to create the object for the class in which all the methods are existing not for the main method class

  • @MustafizurRahamanMustak
    @MustafizurRahamanMustak 4 ปีที่แล้ว +1

    Hi Mukesh .sendkeys is not working as my Eclipse is 1.7 windows 32 bit system What should i do ?

    • @Mukeshotwani
      @Mukeshotwani  4 ปีที่แล้ว

      which Selenium version u are using ? please share your program with exception

  • @chandanghosh7043
    @chandanghosh7043 6 ปีที่แล้ว +1

    Can a method have more than return statement?

    • @Mukeshotwani
      @Mukeshotwani  6 ปีที่แล้ว

      One method can have only one return statement and that too will be last statement of the method

    • @durjan100
      @durjan100 5 ปีที่แล้ว

      @@Mukeshotwani Hi Mukesh,
      I wants to access of your framework and interview questions .let me know how i can do this .
      Thanks
      Durjan (durjansingh10@gmail.com)

  • @soniasadeque4248
    @soniasadeque4248 8 ปีที่แล้ว

    why did you call dynamic calculator.getmyfullname instead of obji.getmyfullname?? please answer

    • @Mukeshotwani
      @Mukeshotwani  8 ปีที่แล้ว

      Hi Sonia, There are 4 scenarios so to explain diff i called calculator.getmyfullname

  • @srikanthsarmavemu1463
    @srikanthsarmavemu1463 8 ปีที่แล้ว

    Hi Mukesh,
    Thank you bro for ur wonderful videos.
    I am new to java ur videos are helping me a lot.
    A quick question, Why do u get a large number when u do subtraction using double.
    Eg: 7488.2345896
    Any theory or logic behind this.
    Regards,
    Srikanth