Solved

<object> problem with ListView

Posted on 2000-03-28
3
392 Views
Last Modified: 2008-02-01
I want to put a ListView (from mscomctl.ocx) in a page. The problem is: the first time I load the page, it works fine, but after that, pressing de refresh button or going to another page with the same control, doesn 't show the items (the items ARE there, yo can scroll trough them, but there 's no text).

This is an extract from the HTML code:

<object
CLASSID="clsid:BDD1F04B-858B-11D1-B16A-00C0F0283628"
ID=lv
WIDTH=600
HEIGHT=200
>

<PARAM NAME=LabelWrap value=-1>
<PARAM NAME=HideSelection value=-1>
<param name=ForeColor value=-2147483640>
<param name=BackColor value=-2147483643>
<param name=BorderStyle     value=1>
<param name=Appearance  value=0>
<param name=AllowReorder value=-1>
<param name=NumItems  value=0>
<param name=FullRowSelect value=-1>
<param name=LabelEdit value=1>
<param name=sorted value=-1>

</object>



<script language=VbScript>
  Dim item


  lv.columnheaders.clear
  lv.listitems.clear

  lv.ColumnHeaders.Add , , "column 1", 100, 0
  lv.ColumnHeaders.Add , , "column 2", 100, 0
  lv.ColumnHeaders.Add , , "column 3", 100, 0


  set item = lv.ListItems.Add (1,"k1" , "1-1")
  item.ListSubItems.Add , , "1-2"
  item.ListSubItems.Add , , "1-3"


  set item = lv.ListItems.Add (2, "k2", "2-1" )
  item.ListSubItems.Add , , "2-2"
  item.ListSubItems.Add , , "2-3"

  lv.View = 3
</script>

0
Comment
Question by:marpon
  • 2
3 Comments
 

Author Comment

by:marpon
ID: 2665388
More info:
-MS Windows Controls 6.0
-Internet Explorer 5.0
0
 

Author Comment

by:marpon
ID: 2673218
I tested in two different machines with the same result: it works fine the first time but I can not reload the page. Assuming it worked for you, do you have any ideas of what can be the differences in our configurations ?
0
 

Accepted Solution

by:
sofox earned 200 total points
ID: 2875830
maybe you used a wrong clsid, try this
58DA8D8A-9D6A-101B-AFC0-4210102A8DA7
I have tested under ie4/ie5, all works

it is strange for different clsid for similar control?

remeber this control may not recognize FullRowSelect

good luck.

sofox
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Statistic Calculator using Javascript 7 46
HTML button disabled 11 36
CSS grid style change 2 14
Change month dropdown 5 15
Building a website can seem like a daunting task to the uninitiated but it really only requires knowledge of two basic languages: HTML and CSS.
Not sure what the best email signature size is? Are you worried about email signature image size? Follow this best practice guide.
In this tutorial viewers will learn how to position items using CSS's three positioning types Create a new HTML document with an internal stylesheet.: Create another div in CSS and name it Absolute : Type "position:absolute;" and "top:10px; left:50p…
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…

707 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

14 Experts available now in Live!

Get 1:1 Help Now