How To Input One Range Into Combobox On Format Controls

Mar 31, 2013

How to input more than one range into the combobox on format controls. Im using the combox to change charts. The ranges are

C2:C19
&
C23:C40

View 1 Replies


ADVERTISEMENT

Possible To Define Range For Combobox Input Based On Number Of Non-blank Cells?

Nov 25, 2013

Rather than having to give it a range, I'd like to have a generic range giving me room to add or subtract values in the column without changing this statement.

Code:

Worksheets("Sheet1").Shapes("Combobox2").ControlFormat.ListFillRange = _
"O2:O14"

View 3 Replies View Related

Linking ComboBox Controls

Nov 24, 2006

I have three combobox...if user click in the option 1 the combobox2 change the values to show and when the user click en one of the option of combobox2 change the options of the combobox 3

If combobox1.value = 0 Then
Set c = Sheets("Codigos de Area"). Cells(1, 2)

While c.Offset(x, 0).value <> ""
ComboBox2.AddItem c.Offset(x, 0).value
x = x +1
Wend

And I can change the code for one select case.

View 2 Replies View Related

Enable & Disable Worksheet Controls Based On ComboBox Value

Mar 5, 2008

I'm currently building an Excel database. This database has a few comboboxes and checkboxes that are tied to each other. If I select the combobox option of "Years", the "Quarters" combobox must be greyed out. In addition depending on which option is chosen, the relevant check boxes must be enabeled or disabled. I've written some code which runs fine, until I try and activate another macro button or if I add and rename a sheet(which is not linked to anything). What should I do? Here is a sample of my code. I have a feeling it's really obviouse but I cant see it..

Private Sub ComboBox2_Change()
If Sheets("InputSheet").ComboBox2 = "Years" Then
Sheets("InputSheet").ComboBox3.Value = ""
Sheets("InputSheet").ComboBox3.Enabled = False
Sheets("InputSheet").CheckBox6.Enabled = True
Sheets("InputSheet").CheckBox7.Enabled = True
Sheets("InputSheet").CheckBox8.Enabled = True
Sheets("InputSheet").CheckBox9.Enabled = True
Sheets("InputSheet").CheckBox10.Enabled = True
Sheets("InputSheet").CheckBox11.Enabled = True
Sheets("InputSheet").CheckBox12.Enabled = True
Sheets("InputSheet").CheckBox13.Enabled = True
Sheets("InputSheet").CheckBox14.Enabled = True
End If...................

View 3 Replies View Related

Format TextBox Controls The Same

Nov 6, 2006

textbox1 on a userform populates textbox2 on a different userform via a command button.

how can i make sure textbox2 keeps the format from textbox1?

eg: when i enter 0.010 in textbox1 and click a command button to populate textbox2 on the 2nd form it produces a value of .01 instead of 0.010

View 3 Replies View Related

Format Controls Source Cell

Jan 6, 2007

I have a combobox (Combobox6) that has a List based on Conditions met in other Comboboxes.

Code to populate Combobox6 is: ....

View 9 Replies View Related

Match Value From Row And Column In Combobox Then Input Value

Jul 25, 2013

I've got a small project to build a small cashflow report... Here is my sheet looks like...

A
B
C
D
E
F
G
H

1
Name
Jan
Feb
Mar
Apr
May
Jun
Jul

2
qwe
10000

20000

[Code] ...........

I've created a userform that looks like this :

I need the amount entered to be inserted based on the name combo box and month picked...

So in a simple words, after i pick "uio" in name combobox and pick "Jul" from month combobox, the amount that i pick from amount combobox will be entered in cell H4...

I've tried several ways to return value and using search function and match the data, but its only for row, not both row and column... Is there any way to achieve this?

View 8 Replies View Related

ComboBox Selection And Auto Userform Input Popup

Nov 22, 2011

I am new in Excel VBA and working on developing a form for Quarterly Reporting. My userform (Quarterly Report) contains controls such as combobox (one of them). I am trying to have another Userform (Risk and Mitigation) to pop-up when a specific item is selected.

Example:
With cboRiskScale
.AddItem "High"
.AddItem "Moderate"
.AddItem "Low"
End with
cboRiskScale.Value = ""

I am looking for the code where I will be able to have the "Risk and Mitigation" userform pop-up for user input when the "High" is selected.

View 7 Replies View Related

Disable TextBoxes And Input Correct Data Based On ComboBox Choice

Mar 24, 2014

when i choose material from my combobox Options (cboTM), i wanted, only the textboxes regarding to the sheet material unlocked, and the others locked with the color of the form, and the same for the other options like worklabor and equipments. i could blocked for material with this code :

[Code] .....

The prob is, worklabor and equipments will be blocked too, and i dont know how to put correct info on the textboxes.

Attached File : teste1.zip

View 5 Replies View Related

Find ComboBox Value On Sheet, Return Row Number & Use To Input TextBox Values

Apr 5, 2008

I've created a userform that has one ComboBox (ComboBox1) and two text fields. I am trying to get the userform to return information to my worksheet in the same row as the name that is displayed in the ComboBox. This is my VBA code.

Private Sub Cmdpayment_Click()
Dim iRow As Long
Dim ws As Worksheet
Set ws = Sheet4
iRow = Cells. Find(What:=Me.ComboBox1.Value, After:=C5, LookIn:=xlFormulas, LookAt _
:=xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext, MatchCase:= _
False, SearchFormat:=False).Activate
ws.Cells(iRow, 12).Value = Me.txtpdate.Value
ws.Cells(iRow, 13).Value = Me.txtpayment.Value
Me.txtpdate.Value = ""
Me.txtpayment.Value = ""
End Sub

View 8 Replies View Related

How To Format Display In Combobox

Jul 21, 2014

I have a range from a column in my Excel table that is formatted ##-##/##. A number like 1.125 would look like 1-1/8.

I also have some values that are text, such as: #6 (I'm working with threads). I use # because it is not the same thing as 6, which could be 6 millimeters or 6 inches.

In combo box on my userform it just shows the decimal values of the range. How can I format the combobox to match Excel?

View 6 Replies View Related

ComboBox Display Format

Jan 22, 2013

I have set up a UserForm containing a ComboBox, listing all suppliers. Upon invocation, the form becomes visible and the user enters a letter on the CB window, to which the CB displays the first entry starting with the user's input.

What I'd like to do is to have the CB expand its window, so that upon entering a letter the window shows something like, say, 5 entries, of which the top one is the first occurrence starting with that letter. Normally, clicking on the down arrow would do that, but I wonder if I can save them the keystroke.

View 3 Replies View Related

UK Date Format ComboBox

Jan 10, 2007

I'm having trouble getting a combo box to show UK format dates. It's meant to check the last date on the spreadsheet, find so many weeks before and after and fill the drop-down. It finds the weeks fine, I've even had it put them into a column in the spreadsheet and they show fine there, but the drop-down always comes up with US format dates even if I read it from the test column in the spreadsheet. It then writes the US format date into the spreadsheet, which causes mayhem next time I run it, as I'm forcing it to read UK style dates in an attempt to make it work. It sometimes does decide to work fine, I'm never sure why, but it changes back to being wrong again when I close and restart it. I've checked my regional settings, and they're right.

Dim i As Integer
Dim ThisWeek As Date
Dim rCell As Range
Dim UsedWeek As Date
FirstTime = False
For i = 0 To 20
Redim Week(i) As Date
Next i
ThisRow = Cells(Cells.Rows.Count, "A").End(xlUp).Row+1
If ThisRow = 9 Then............

View 2 Replies View Related

Date Format In Combobox

Feb 27, 2007

I need to set the format which a date appears in a combobox as it is initialised.

At the moment the combobox looks for data in a named range.
The data appears in the following format on the sheet.
"Jan 07"
"Feb 07"
"Mar 07" etc

When the UserForm opens and I go to the combobox "pulldown"
the date is formatted as follows:
"1/1/2007'
"2/1/2007"
"3/1/2007"

How do I get the date format to reflect the cell format in a combobox?

View 9 Replies View Related

Toggle Show & Hide Controls In Range

Oct 27, 2006

Having a problem with a survey I'm creating in Excel.

I have a question with a Yes/No response cell. I want to show/hide several rows below it. The problem is that these rows also contain 6 option buttons, which I also need to hide/show depending on the response cell.

Is there a handy way to hide all of these shapes/controls in the defined range, and then "unhide" them if the cell value changes back to "Yes"?

View 7 Replies View Related

Format Date From Input Box?

Mar 10, 2012

I have an input box that requires the user to enter a date or accept today's date, which is the default, and when they click ok it is entered in cell "Data!D25". I want the format to be "yyyy-mm-dd". I have set the cell "Data!D25" to automatically use this format if I type the date directly into the cell by typing "yyyymmdd" without the dashes but when they type in the input box without the dashes, the result in the "Data!D25" cell is "############".

How can I correct this?

Code:

Sub PrintForms()
' Dim StartRow As Integer
' Dim EndRow As Integer
' Dim Msg As String
' Dim I As Integer

[Code]...

View 9 Replies View Related

Input Box - Collective Format

Sep 22, 2009

I have a userforms (using multipage) with columns of input textboxes for the user to input.

Multipage1. Page1
Columns of data to input are %
There are 4 columns of 10 rows (therefore 40 textboxes)
I have the following code that will format the input to be seen as % by the user and to be treated as % in the worksheet calculations.


Private Sub TextBox1_KeyDown(ByVal KeyCode As MSForms.ReturnInteger, _
ByVal Shift As Integer)
Select Case KeyCode
Case 9, 13
Sheets("Sheet1").Range("rate").Value = TextBox1.Value
With TextBox1
.Text = Format(WorksheetFunction.Substitute(.Text, "%", ""), "0.00") & "%"
Sheets("Sheet1").Range("rate").Value = .Value
End With
End Select
End Sub

Do I have to code this for every textbox? Is there an easier way to do so. Can I create a loop or routine that will pass through all the textboxes and perform the above procedures?

Please let me know because I don't want to undertake a cumbersome exercise of programming this code for each and every textbox.

By the way, page 2 of the multipage, will have textboxes for % entries; textboxes for 0.00 entries and textboxes for $0.00 entries. I have similar code as above for the 0.00 and $0.00 entries and again I'm trying to prevent programming unnecessarily if I somehow could find a way to code a loop to pass through common textboxes for %, 0.00 and $0.00 entries.

View 9 Replies View Related

ComboBox Output Set In Date Format

Aug 10, 2006

I'm creating a workbook with the ultimate aim of graphing some data between any two dates. For this I plan to use the ComboBoxes on the Control Toolbox. Each ComboBox takes its range of data from a list of dates, with the cells set as Date format (custom as dd-mmm-yy), however when I select a date in the dropdown of the ComboBox, it is shown in number format, i.e. 38723 etc.

When I ask the ComboBox to put the output in another cell, it is input in text format as that number. Changing the output cell type does work, but once you select a new date in the dropdown, it reverts to text once again. how to set the ComboBox to display dd-mmm-yy format and it's output to be the same?

View 5 Replies View Related

Add Controls To Right Click Menu Based On Range List

Sep 28, 2007

I have customised the right click menu's for this spreadsheet and currently it is all hard coded. I was wondering if it is possible to dynamically modify the right click menu? The code currently has right click buttons for each staff member, and when clicked other actions are performed. I have added a "Staff" sheet and was wondering if there is a way the code can reference that sheet and create the list based on those entries for example, when new staff join or other staff leave?

I'm sure that there is a better way to go about this, perhaps a For... Next loop but I don't know enough about it. In the mean time, I will keep bashing away at it in hopes of a brainwave... it's a Friday before a long weekend and I think my brain has decided its holiday time.

Option Explicit
Private Sub Workbook_Deactivate()
On Error Resume Next
With Application
. CommandBars("Cell").Controls("Add Nick").Delete
.CommandBars("Cell").Controls("Add Toby").Delete
.CommandBars("Cell").Controls("Add Ben").Delete
.CommandBars("Cell").Controls("Add Matt").Delete
.CommandBars("Cell").Controls("Add Zoe").Delete
.CommandBars("Cell").Controls("Add Anne").Delete
.CommandBars("Cell").Controls("Add Craig").Delete
.CommandBars("Cell").Controls("Add Unknown (1)").Delete
.CommandBars("Cell").Controls("Add Unknown (2)").Delete
.CommandBars("Cell").Controls("Remove").Delete
End With
With Application
.CommandBars("Cell").Controls("Cut").Visible = True
.CommandBars("Cell").Controls("Copy").Visible = True...............................

View 2 Replies View Related

Cell Format Just Displays What Is Input

Dec 30, 2008

i have a cell that i have to put a lead time into ( weeks ) ie 7-9 if i type this into the cell it throws up all sorts of things but i want it to display 7-9 trouble is i know i could do ="7-10" but other users use it and wont now that how can i format the cell so it just displays what is input?

View 3 Replies View Related

Date Format In Input Boxes

Jan 20, 2007

I have designed a spreadsheet to calculate time and speed averages of a ships voyage. When using a date and time value entered into a input box the value in the cell is reversed form the U.K date format to the U.S date format. this has been causing great amount of fustration to me. the cell has the correct date format i want and the excel system is configured to the U.K format. my program to allow you to look at it my knowlege is not very good of VBA. When entering the date in the FAOP from the drop down menu as dd/mm/yy hh:mm in is reversed.

View 2 Replies View Related

ComboBox Selection/Choice Looses Format

Oct 16, 2006

When i select 10% in the combo box, it changes to decimal which is 0.1
How do i change it to a whole number? eg. 0.9 to 90%?

View 6 Replies View Related

Display Decimal Value Input As String Format

Aug 16, 2012

I'm writing a macro that will automatically change the display in a column of cells.

The input in the cell would be a decimal value, (e.g. 1, 1.25, 1.5, 1.75, 2). As of now, I think the only input options are whole numbers and 1/4, 1/2, 3/4 fractions.

After inputting the decimal value, the cell should update to display the value as the following string format :

Input: 1.25
Displays: 1-1/4"

The purpose being to enable fast data entry while displaying in the desired format.

Here is where I know to begin for the automatic update:

Code:

Sub Worksheet_Change(ByVal Target As Range)
Application.EnableEvents = False
'
'
'Code
'
'
Application.EnableEvents = True
End Sub

View 6 Replies View Related

ActiveX Combobox Date Format And List Index

Mar 30, 2014

I have an activeX combo box with dates in the following quarterly format (dec-14, march-15, july-15 etc), with the following code:

[Code] .....

However' while each code works fine standalone, the two codes wont work together - and the listindex reverts back to 0.

View 3 Replies View Related

Format Cells So 24 Hour Time May Be Input Without Colon

Nov 30, 2003

Is there a way to format cells so 24 hour time may be input without the colon, as an example 1425 instead or 14:25? We can do it in Access. One would think it possible in Excel, yet I have not discover how if indeed its possible.

View 9 Replies View Related

Fill ComboBox With Cell Range And Link ComboBox To Cell?

Oct 15, 2006

I have two questions.

1). I have dates listed in excel (01/01/2006 to 12/31/2006) say from range B12:B376.

How do I get these values to a ComboBox.

2). If the above is possible and if I select a value in ComboBox say 08/07/2006, it should get updated in a particular cell say A1

So selection of 08/07/2006 in ComboBox, should reflect 08/07/2006 in cell A1.

Note: This ComboBox is on the UserForm and not on the Excel Sheet.

View 7 Replies View Related

Change Year Value In Dd/mm/yyyy Format Based On Combobox Choice

Jun 14, 2014

I have a TextBox and a ComboBox. the TextBox shows the current date

VB : TextBox1.Value = Format(Date, "dd/mm/yyyy")

The ComboBox has a list index of years say from 1991 to 2030. Is it possible Change only the "yyyy" in the TextBox based on the changed value in ComboBox.

Say the textbox1 shows today 14/06/2014. now if we select 2016 in ComboBox1 the TextBox1 date should changed to 14/06/2016.

View 4 Replies View Related

Excel 2007 :: Input Mask To Format Cell Content

Jan 20, 2014

The cell content is to be 0-7 characters in length.

Alpha characters only, i.e., no numeric.

First character must be uppercase.

Remaining characters may be lowercase or blank.

Is that possible to do in MS Excel 2007?

View 10 Replies View Related

Input And Display Data In Cell In H:mm Format Without Changing To Time

Feb 25, 2010

Can i put into the cells B38-AF38, that would display the sum of B20:AF20 + B24:AF24 + B28:AF28 + B32:AF32 +B36:AF36 in a h:mm format.

When imputing the data into a cell in a h:mm format, I need it to display in that cell and formula bar the h:mm format without having to put an apostrophe in front of "h" or ":mm" value. Once complete, this form is going to go to other trainers to use on their computers and I dont think they would remember to keep putting an apostrophe before the data.

Example:

B20= 1:15 (1h15m) NOT 1:15:00 AM

B24= :30 (30min)

B28= :45 (45min)

B32= 1:45 (1h45m) NOT 1:45:00 AM

B38= 4:15 (4h15min)

I have attached a copy of the form for better clarification.

It doesnt seem to be complicated, but it's certainly a lot more than I thought.

View 4 Replies View Related

UserForm - Keep User In Textbox If They Made Format Input Error

Oct 27, 2012

I have a userfrom with a text box which is used to receive a telephone number from the user. The 'Event' code that checks the formatting of the telephone number is "tbCustTel_Exit". If my user enters a format other than what is acceptable for a tel number, they get an error message telling them to re-enter.

My problem is they still end up EXITING that text box they made a mistake in? How can I override them exiting the text box if they make a mistake - and keep them in the text box so they can try and re-enter the tel number again?

View 6 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved