+ Reply to Thread
Results 1 to 3 of 3

Please help a beginner....

  1. #1
    Registered User
    Join Date
    11-25-2005
    Posts
    5

    Please help a beginner....

    Now, I'm very new too all of this so please be gentle with me!

    I am trying to create a User Form for people to book equipment through and I'm getting there but I'm finding a couple of things problematic:

    The information my colleagues fill out on the User Form load into a spreadsheet when the order is submitted. This spreadsheet has separate columns for Equipment, Location, Shipping Date and Return Date.

    I have the following code:

    If chkItemX.Value = True And Range("D10").Value = "Company Name" Then
    Range("F10").Value = txtEvent.Text
    Range("G10").Value = txtShipping.Text
    Range("H10").Value = txtReturn.Text
    ElseIf chkItemX.Value = True And Range("D10").Value = "USA" Then
    MsgBox "Item X Is Unavailable"
    ElseIf chkItemX.Value = False Then
    End If

    Which is all very well and good if the equipment is either with us or in the USA however, what I really want to be able to say something like:

    If chkItemX.Value = True And Range("D10").Value = "Company Name" Then
    Range("F10").Value = txtEvent.Text
    Range("G10").Value = txtShipping.Text
    Range("H10").Value = txtReturn.Text
    ElseIf chkItemX.Value = True And Range("D10").Value = "Anything Other Than Company Name" Then
    MsgBox "Item X Is Unavailable"
    ElseIf chkItemX.Value = False Then
    End If

    But I have no idea how to write the code for the bit 'Range("D10).Value = "Anything Other Than Company Name".....any ideas.....am I making any sense....?

    Thank you for bearing with me,

    L.

  2. #2
    Bob Phillips
    Guest

    Re: Please help a beginner....

    If chkItemX.Value = True And Range("D10").Value = "Company Name" Then
    Range("F10").Value = txtEvent.Text
    Range("G10").Value = txtShipping.Text
    Range("H10").Value = txtReturn.Text
    ElseIf chkItemX.Value = True And Range("D10").Value <> "Company Name" Then
    MsgBox "Item X Is Unavailable"
    ElseIf chkItemX.Value = False Then
    End If


    --

    HTH

    RP
    (remove nothere from the email address if mailing direct)


    "Lindsey" <[email protected]> wrote in
    message news:[email protected]...
    >
    > Now, I'm very new too all of this so please be gentle with me!
    >
    > I am trying to create a User Form for people to book equipment through
    > and I'm getting there but I'm finding a couple of things problematic:
    >
    > The information my colleagues fill out on the User Form load into a
    > spreadsheet when the order is submitted. This spreadsheet has separate
    > columns for Equipment, Location, Shipping Date and Return Date.
    >
    > I have the following code:
    >
    > If chkItemX.Value = True And Range("D10").Value = "Company Name" Then
    > Range("F10").Value = txtEvent.Text
    > Range("G10").Value = txtShipping.Text
    > Range("H10").Value = txtReturn.Text
    > ElseIf chkItemX.Value = True And Range("D10").Value = "USA" Then
    > MsgBox "Item X Is Unavailable"
    > ElseIf chkItemX.Value = False Then
    > End If
    >
    > Which is all very well and good if the equipment is either with us or
    > in the USA however, what I really want to be able to say something
    > like:
    >
    > If chkItemX.Value = True And Range("D10").Value = "Company Name" Then
    > Range("F10").Value = txtEvent.Text
    > Range("G10").Value = txtShipping.Text
    > Range("H10").Value = txtReturn.Text
    > ElseIf chkItemX.Value = True And Range("D10").Value = "Anything Other
    > Than Company Name" Then
    > MsgBox "Item X Is Unavailable"
    > ElseIf chkItemX.Value = False Then
    > End If
    >
    > But I have no idea how to write the code for the bit 'Range("D10).Value
    > = "Anything Other Than Company Name".....any ideas.....am I making any
    > sense....?
    >
    > Thank you for bearing with me,
    >
    > L.
    >
    >
    > --
    > Lindsey
    > ------------------------------------------------------------------------
    > Lindsey's Profile:

    http://www.excelforum.com/member.php...o&userid=29095
    > View this thread: http://www.excelforum.com/showthread...hreadid=488181
    >




  3. #3
    Registered User
    Join Date
    11-25-2005
    Posts
    5
    Thank you, that works perfectly.

    L.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1