Solved

MSHFlexGrid problem

Posted on 2000-04-10
7
190 Views
Last Modified: 2011-10-03
I'm using MSHFlexgrid control to display data from SQLServer
my problem is, I want user only can select one row only at the flexgrid
How to do this ? Thanks

 JavaBoy
0
Comment
Question by:JavaBoy060299
  • 3
  • 2
  • 2
7 Comments
 
LVL 14

Expert Comment

by:wsh2
ID: 2699390
<----- Code Begin ----->

Private Sub MSFlexGrid1_KeyPress(KeyAscii As Integer)
'  Enter your row number here
   If MSFlexGrid1.Row <> 1 _
   Then
      MsgBox ("You can only update row 1")
      KeyAscii = 0
   End If
End Sub

<----- Code End ----->

0
 
LVL 142

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 2699479
SelectionMode = 1 - flexSelectionByRow
AllowBigSelection = False
0
 

Author Comment

by:JavaBoy060299
ID: 2703386
Adjusted points from 25 to 50
0
Optimizing Cloud Backup for Low Bandwidth

With cloud storage prices going down a growing number of SMBs start to use it for backup storage. Unfortunately, business data volume rarely fits the average Internet speed. This article provides an overview of main Internet speed challenges and reveals backup best practices.

 

Author Comment

by:JavaBoy060299
ID: 2703387
wsh2:
Maybe there is some misunderstanding
I don't want user to select more than 1 row (not row 1), so user only allowed to block not more than one row

angelIII:
Have you try it ?
I have tried before I post this Q
but nothing happened

 
0
 
LVL 142

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 2703419
i admin, i didn't try the settings, as they seemed evident...

On the other hand, you say you don't want to have more that one row selected, what is if you consider only the Current Row as selected (for recordsets you have only one active row too)
0
 
LVL 14

Accepted Solution

by:
wsh2 earned 50 total points
ID: 2704651
Oh.. thats different.. <smile>.

Private Sub MSFlexGrid1_SelChange()

   MSFlexGrid1.rowsel = MSFlexGrid1.row

End Sub

0
 

Author Comment

by:JavaBoy060299
ID: 2706197
angelIII,

I know that, but I need some solution as wsh2 provides. thanks

wsh2,
Thanks for your answer !
It's exactly I'm looking for

 
0

Featured Post

Simplifying Server Workload Migrations

This use case outlines the migration challenges that organizations face and how the Acronis AnyData Engine supports physical-to-physical (P2P), physical-to-virtual (P2V), virtual to physical (V2P), and cross-virtual (V2V) migration scenarios to address these challenges.

Question has a verified solution.

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

Suggested Solutions

Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
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…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

777 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