Solved

Editing cell using grid32.ocx

Posted on 1998-10-21
7
285 Views
Last Modified: 2008-02-01
Is there a way to edit individual cells using grid32.ocx similar to
the way text can be edited in a TextBox?
0
Comment
Question by:rmoscoso
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
7 Comments
 

Author Comment

by:rmoscoso
ID: 1440979
Edited text of question
0
 
LVL 3

Expert Comment

by:vmano
ID: 1440980
as far as i know, you can not do it. Probably what you can do is, present the contents of the cell in a text box, and allow editing the contents of that cell.
0
 

Author Comment

by:rmoscoso
ID: 1440981
Yes, that is the way I have been doing it.  Unfortunately the powers that be don't
want it that way.  Is there some other type of grid control that I may use that allows
this type of editing?  Or do I have to revert at making a grid out of text boxes?
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:rmoscoso
ID: 1440982
Yes, that is the way I have been doing it.  Unfortunately the powers that be don't
want it that way.  Is there some other type of grid control that I may use that allows
this type of editing?  Or do I have to revert at making a grid out of text boxes?
0
 
LVL 3

Expert Comment

by:vmano
ID: 1440983
try VSFlexGrid Control. their web site www.videosoft.com. if you are using VB 6.0 Enterprise Edition, they are included in that.
0
 
LVL 2

Accepted Solution

by:
dabellei earned 100 total points
ID: 1440984
Private Sub Grid1_KeyDown(KeyCode As Integer, Shift As Integer)
    If KeyCode = 8 Then
        If Len(Grid1.Text) > 0 Then
            Grid1.Text = Left(Grid1.Text, Len(Grid1.Text) - 1)
        Else
            Beep
        End If
    Else
        If (KeyCode > 64 And KeyCode < 90) Or (KeyCode = 32) Then
            Grid1.Text = Grid1.Text & Chr(KeyCode)
        End If
    End If
End Sub


With this code you put in the keydown event of your grid you could simulate what you want and yor editing in the grid directly that's the way i've done it before.
0
 

Author Comment

by:rmoscoso
ID: 1440985
Thank you much!!!
0

Featured Post

Secure Your Active Directory - April 20, 2017

Active Directory plays a critical role in your company’s IT infrastructure and keeping it secure in today’s hacker-infested world is a must.
Microsoft published 300+ pages of guidance, but who has the time, money, and resources to implement? Register now to find an easier way.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
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…

749 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