Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 144
Default Issue with listbox not showing the last value in the range

Hi all,

This one is leaving laughing in utter frustration and delirium (have been
spending a LOT of time lately in VBA trying to finish my project... :)

The issue is that the last value in my range that is being pulled into a
listbox in a form is not showing in the listbox. I can see just the very
very top of the text of the last value in the listbox, however, for some
reason, the listbox will not scroll down to that last value. It's very odd
-- the scroller on the listbox shows just a tad of space between the current
position and the end, but it won't let me scroll to the end.

I have increased my range to include a blank cell -- this allows the last
value to show -- however, I'm wondering why the heck this is happening.
Thanks! Code is below:

Formula in sheet for specified range (under "Insert" - "Name" -- note that
this is the formula which results in the last cell in the range not showing
in the listbox):
=OFFSET('Commdet formulas'!$BA$1,0,0,COUNTA('Commdet formulas'!$BA:$BA),1)
---------
Code of form initialization:
Private Sub UserForm_Initialize()

'Sheets("Commdet formulas").Activate
With lstmissingids
'populate listbox with appropriate values
.RowSource = Range("txtmissing").Address
End With

End Sub
-------
Code of formatting of form:
With frmmissingent
.Show vbModeless
.Caption = "Open Sales transactions"
.lstmissingids.Top = 198
.lstmissingids.Height = 100.5
.cmdcopylbl.Top = 312
.cmdcopy.Top = 312
.cmdclose.Top = 312
.lblmissingent.Height = 180
.Height = 380
End With


--
Robert
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,986
Default Issue with listbox not showing the last value in the range

You can adust the height property for the listbox which might help. Also,
might try the text align property.

"robs3131" wrote:

Hi all,

This one is leaving laughing in utter frustration and delirium (have been
spending a LOT of time lately in VBA trying to finish my project... :)

The issue is that the last value in my range that is being pulled into a
listbox in a form is not showing in the listbox. I can see just the very
very top of the text of the last value in the listbox, however, for some
reason, the listbox will not scroll down to that last value. It's very odd
-- the scroller on the listbox shows just a tad of space between the current
position and the end, but it won't let me scroll to the end.

I have increased my range to include a blank cell -- this allows the last
value to show -- however, I'm wondering why the heck this is happening.
Thanks! Code is below:

Formula in sheet for specified range (under "Insert" - "Name" -- note that
this is the formula which results in the last cell in the range not showing
in the listbox):
=OFFSET('Commdet formulas'!$BA$1,0,0,COUNTA('Commdet formulas'!$BA:$BA),1)
---------
Code of form initialization:
Private Sub UserForm_Initialize()

'Sheets("Commdet formulas").Activate
With lstmissingids
'populate listbox with appropriate values
.RowSource = Range("txtmissing").Address
End With

End Sub
-------
Code of formatting of form:
With frmmissingent
.Show vbModeless
.Caption = "Open Sales transactions"
.lstmissingids.Top = 198
.lstmissingids.Height = 100.5
.cmdcopylbl.Top = 312
.cmdcopy.Top = 312
.cmdclose.Top = 312
.lblmissingent.Height = 180
.Height = 380
End With


--
Robert

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 144
Default Issue with listbox not showing the last value in the range

I tried adjusting the height and the textalign property...neither worked.
The scroll bar literally shows that theres a little space left, implying
there's another record, it just won't let me scroll down.

--
Robert


"JLGWhiz" wrote:

You can adust the height property for the listbox which might help. Also,
might try the text align property.

"robs3131" wrote:

Hi all,

This one is leaving laughing in utter frustration and delirium (have been
spending a LOT of time lately in VBA trying to finish my project... :)

The issue is that the last value in my range that is being pulled into a
listbox in a form is not showing in the listbox. I can see just the very
very top of the text of the last value in the listbox, however, for some
reason, the listbox will not scroll down to that last value. It's very odd
-- the scroller on the listbox shows just a tad of space between the current
position and the end, but it won't let me scroll to the end.

I have increased my range to include a blank cell -- this allows the last
value to show -- however, I'm wondering why the heck this is happening.
Thanks! Code is below:

Formula in sheet for specified range (under "Insert" - "Name" -- note that
this is the formula which results in the last cell in the range not showing
in the listbox):
=OFFSET('Commdet formulas'!$BA$1,0,0,COUNTA('Commdet formulas'!$BA:$BA),1)
---------
Code of form initialization:
Private Sub UserForm_Initialize()

'Sheets("Commdet formulas").Activate
With lstmissingids
'populate listbox with appropriate values
.RowSource = Range("txtmissing").Address
End With

End Sub
-------
Code of formatting of form:
With frmmissingent
.Show vbModeless
.Caption = "Open Sales transactions"
.lstmissingids.Top = 198
.lstmissingids.Height = 100.5
.cmdcopylbl.Top = 312
.cmdcopy.Top = 312
.cmdclose.Top = 312
.lblmissingent.Height = 180
.Height = 380
End With


--
Robert

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
listbox issue [email protected] Excel Programming 4 March 14th 07 09:45 AM
showing a listbox with last entry as the default Katrina Excel Programming 3 November 8th 06 06:24 AM
Showing Zero for all blank cells in a range ashish128 Excel Discussion (Misc queries) 2 June 20th 06 10:06 AM
UserForm Listbox issue bach Excel Discussion (Misc queries) 29 October 6th 05 01:48 PM
Showing Worksheet Range in Userform RonMcC[_2_] Excel Programming 0 February 23rd 04 03:46 PM


All times are GMT +1. The time now is 09:02 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"