Solved

Date entered in userform used for looking up date range

Posted on 2014-10-03
8
129 Views
Last Modified: 2014-10-06
I am using an Excel userform with various entry fields and listboxes for spreadsheet data entry.  One of the entry fields is a date.  I want to use the date entered to search a worksheet with date ranges to obtain the Academic Year and Academic Term that the entry date belongs.  I have a formula in the attached file to do the lookup, but want to use VBA to obtain the information.
DateLookupExample.xlsm
0
Comment
Question by:deedeheard
  • 4
  • 4
8 Comments
 
LVL 29

Expert Comment

by:gowflow
ID: 40361472
You mean in the Form you want to select the student on the list then put a date and you want to get Academic Year and Academic term show up ? if yes you want this in a mesagebox or ?
and are you referring to the information you have in the sheet Adjustments ?

Like you want to eliminate this sheet completely and simply have the form to querry this info ? is this what your looking for ?
gowflow
0
 

Author Comment

by:deedeheard
ID: 40361605
The student is selected in the user form and a date is entered. When the dad button is clicked, I want to use the entered date to lookup the corresponding academic year and academic term and write a record (with student name , student number, date, academic year and academic term) in the worksheet. I hope this makes sense.
0
 

Author Comment

by:deedeheard
ID: 40361619
I have two academic year and academic terms in the adjustments worksheet, but don't want to use the columns with the formulas - I want to determine and populate the Academic Year Value and Academic Term Value from vba..
0
 
LVL 29

Expert Comment

by:gowflow
ID: 40361845
ok then you want to update the Sheet 'adjustments' with the values from the form (for sure adding year and term) right ?? In other words we will be overriding the formulas ??

gowflow
0
Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

 

Author Comment

by:deedeheard
ID: 40362147
Yes
0
 
LVL 29

Accepted Solution

by:
gowflow earned 500 total points
ID: 40362305
ok here it is.
I added a button on the sheet Adjustments to display the form anytime you want.

Just choose several combinations of dates
System will check for dates outside the listed ones and advise you
also system will check if the combination already exist and will advise you.

Let me know.
gowflow
DateLookupExample-V01.xlsm
0
 

Author Closing Comment

by:deedeheard
ID: 40362665
This is awesome!  Thank you so much!
0
 
LVL 29

Expert Comment

by:gowflow
ID: 40363153
Your welcome glad I could assist.
gowflow
0

Featured Post

Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The canonical version of this article is on my web site here: http://iconoun.com/articles/collisions/ A companion presentation is available here: http://iconoun.com/articles/collisions/Unicode_Presentation.pdf
The new Microsoft OS looks great, is easier than ever to upgrade to, it is even free.  So what's the catch?  If you don't change the privacy settings, Microsoft will, in accordance with the (EULA) you clicked okay to without reading, collect all the…
Viewers will learn how to maximize accessibility options in an Excel workbook for users with accessibility issues.
The viewer will learn how to simulate a series of sales calls dependent on a single skill level and learn how to simulate a series of sales calls dependent on two skill levels. Simulating Independent Sales Calls: Enter .75 into cell C2 – “skill leve…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

26 Experts available now in Live!

Get 1:1 Help Now