Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Visual Basic > VB 6 Visual Basic 6 > Pro VB 6
|
Pro VB 6 For advanced Visual Basic coders working in version 6 (not .NET). Beginning-level questions will be redirected to other forums, including Beginning VB 6.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Pro VB 6 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 10th, 2008, 10:17 AM
Registered User
 
Join Date: Mar 2008
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default Selecting Cells In Flexgrid and Merging

I'm trying to use the Flexgrid. I want to merge a couple of cells but I have a couple of questions.

If I or a user selects 2 or more cells in the grid, how can I fill up the selected cells with text and then merge them? What I can't figure out is how to loop through the selected cells.

Also after a merge is performed, you cannot select multiple cells again. The grid is restricted to single cell selection. Can this be changed so that other cells can be selected and merged (while keeping the original merged cells intact)?


Code:
    MSFlexGrid1.MergeCells = flexMergeFree
    MSFlexGrid1.MergeCol(3) = True
    MSFlexGrid1.TextMatrix(3, 3) = "GB"
    MSFlexGrid1.TextMatrix(4, 3) = "GB"
    MSFlexGrid1.TextMatrix(10, 3) = "GB"
    MSFlexGrid1.TextMatrix(11, 3) = "GB"

Rather than reference the cells by the actual rows and columns, I want to fill in the user selected cells with a string.






Similar Threads
Thread Thread Starter Forum Replies Last Post
Datagrid-Merging Cells p330418 ASP.NET 2.0 Professional 0 February 29th, 2008 12:06 AM
Merging cells in Datagrid p330418 ASP.NET 2.0 Basics 0 February 28th, 2008 11:21 PM
merging excel cells anoopkpanicker Beginning VB 6 1 March 26th, 2007 05:11 PM
Selecting multiple rows in a flexgrid dfbosse VB How-To 2 May 23rd, 2006 12:18 AM
How to know cells in table is merging?? DorisTan VB How-To 0 January 13th, 2005 09:50 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.