Solved

FlexGrid additem

Posted on 2000-04-23
4
1,688 Views
Last Modified: 2008-02-26
Hi i am using FlexGrid.additem method and it always results that the first row is always a blank row. Why does that happen ? Can anyone suggest anything ?
0
Comment
Question by:vbRetard
4 Comments
 
LVL 8

Expert Comment

by:stefanx
ID: 2742408
Uhmm, this should not happen. Are you sure that on initialization, your MSFlexgrid does not maybe have its Rows property set to 2?

Assuming that you have at least one Fixedrow, do the following int your Form_Load() sub :

MSFlexGrid1.Rows = 1

Then try you additems as before.
0
 

Author Comment

by:vbRetard
ID: 2742453
Yes i've tried that all but it still adds to the second row and leaves the first one blank.
0
 
LVL 38

Expert Comment

by:PaulHews
ID: 2742561
That's the way AddItem works for the flexgrid.  It adds a new row.  If you want to add text to an existing cell, you need to use .TextMatrix or .TextArray properties. These will add to the cell (Row, Col) that you specify.
0
 
LVL 6

Accepted Solution

by:
setiawan earned 15 total points
ID: 2742573
Hi vbRetard,

just try like this :

dim idx
idx = 1
MSFlexGrid1.addItem "abc" & chr(9) & "abc" & chr(9) ...., idx

note : use chr(9) as field delimiter in your grid
good luck

 danny
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

758 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

19 Experts available now in Live!

Get 1:1 Help Now