troubleshooting Question

How to draw...

Avatar of Mike Eghtebas
Mike EghtebasFlag for United States of America asked on
Visual Basic.NET
3 Comments1 Solution254 ViewsLast Modified:
This is the code I have:

Public Class Scale
    Public dteStart As Date
    Public dteEnd As Date

    Private Sub Scale_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        dteStart = #1/1/2006#
        dteEnd = #12/1/2006#
    End Sub

    Private Sub cmdOk_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cmdOK.Click
        ' testing to make sure Month(dteStart) & Month(dteEnd) are read correctly
        MessageBox.Show(Month(dteStart).ToString & "-" & Month(dteEnd).ToString)
        Call DrawScale
    End Sub
End Class

Question: How to code DrawScale to draw a box using four lines TopLine, BottomLine, LeftLine, and RightLine.

LeftLine: height .25 with its x property .5 from the left edge of the form "Sacle".
RightLine: height .25 with its x property .5 from the right edge of the form "Sacle".
both of the above lines with y property 1.5 from the top edge of the form "Scale"

TopLine: Connection the upper end of the left and right lines.
BottomLine: Connection the lower end of the left and right lines.

        1 ______2_______3________________.__.__.___11_______12
        [___________________________________________________]

With lables 1, 2,... 11, 12 on the top.  User may resize the form's width manulally. It is expected this sacale to redraw accordingly (as specified above).

I am using 2005 .Net Express Edition.

Thank you.

ASKER CERTIFIED SOLUTION
Mike Tomlinson
High School Computer Science, Computer Applications, Digital Design, and Mathematics Teacher
Join our community to see this answer!
Unlock 1 Answer and 3 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 3 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros