ISOM
lecture11-methods-ex-solution.pdf

lecture11-methods-ex-solution.pdf - Lecture 11...

Info icon This preview shows pages 1–5. Sign up to view the full content.

Page 1 of 5 Lecture 11 Exercise (Solution) Assume Option Explicit is applied to all questions, unless stated otherwise. In an Excel workbook, there are two modules: Module1: Module2: Q1. If we execute Main() inside Module 1, what will be the output? Or will there be any error? Compile error.
Image of page 1

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

Page 2 of 5 Q2. After we fix the error, what will be the output when we execute the Main() inside Module 1? M 33.5 My name is Michael Q3. If we uncomment the below comment (i.e., we remove the comment symbol ), will there be any problem when we execute Main() or Alternative() inside Module 1? Yes. Compile error. Q4. After we fix the error in Q3, what will be the output when we execute Main() inside Module 2?
Image of page 2
Page 3 of 5 Q5. Given: What will be the output when execute Testing_Sub()? Any error? No error. 20 Q6. Given: What will be the output when execute Testing_Sub()? Any error?
Image of page 3

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

Page 4 of 5 Q7. Complete the below VBA program such it can swap the values of two string Sub Main_Q7() Dim a As String Dim b As String a = "Hello" b = "Bye" Debug.Print a & " " & b
Image of page 4
Image of page 5
This is the end of the preview. Sign up to access the rest of the document.
  • Fall '16
  • Ring, compile error

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern