Not really understand what you want exactly.
Jx_Man
Senior Poster
3,521 posts since Nov 2007
Reputation Points: 1,468
Solved Threads: 514
Skill Endorsements: 64
Jx_Man
Senior Poster
3,521 posts since Nov 2007
Reputation Points: 1,468
Solved Threads: 514
Skill Endorsements: 64
Well.. Datagrid is not the control with that purpose.
You can't do many things like write directly to datagrid.
You can use flexgrid instead of datagrid.
Jx_Man
Senior Poster
3,521 posts since Nov 2007
Reputation Points: 1,468
Solved Threads: 514
Skill Endorsements: 64
Also dont forget to set recordset as datagrid source. It will link database and datagrid.
Set DataGrid1.DataSource = rs
Jx_Man
Senior Poster
3,521 posts since Nov 2007
Reputation Points: 1,468
Solved Threads: 514
Skill Endorsements: 64
Set this :
DataGrid1.AllowAddNew = True ' This line will add new row on datagrid
DataGrid1.AllowUpdate = True ' this line will let you to add data and edit data directly in datagrid
This line will add data directly to database when you write new data on datagrid
Jx_Man
Senior Poster
3,521 posts since Nov 2007
Reputation Points: 1,468
Solved Threads: 514
Skill Endorsements: 64
Datagridview?
Are you use Vb.Net?
Also what you get so far?
Post your code here. Make some efforts.
Jx_Man
Senior Poster
3,521 posts since Nov 2007
Reputation Points: 1,468
Solved Threads: 514
Skill Endorsements: 64
Likes minimize all programs :
You can try this :
This use API function. It will same efect when you press "win+D" in keyboard.
Private Const KEYEVENTF_EXTENDEDKEY As Long = &H1
Private Const KEYEVENTF_KEYUP As Long = &H2
Private Const VK_LWIN As Byte = &H5B
Private Declare Sub keybd_event Lib "user32" (ByVal bVk As Byte, _
ByVal bScan As Byte, ByVal dwFlags As Long, ByVal dwExtraInfo As Long)
Public Sub ClearDesktop()
' Simulate key press
Call keybd_event(VK_LWIN, 0, KEYEVENTF_EXTENDEDKEY, 0)
Call keybd_event(Asc("D"), 0, 0, 0)
' Simulate key release
Call keybd_event(VK_LWIN, 0, KEYEVENTF_EXTENDEDKEY Or KEYEVENTF_KEYUP, 0)
Call keybd_event(Asc("D"), 0, KEYEVENTF_KEYUP, 0)
End Sub
Private Sub Form_Load()
ClearDesktop
End Sub
Jx_Man
Senior Poster
3,521 posts since Nov 2007
Reputation Points: 1,468
Solved Threads: 514
Skill Endorsements: 64
What you mean about clear the screen? what screen?
Jx_Man
Senior Poster
3,521 posts since Nov 2007
Reputation Points: 1,468
Solved Threads: 514
Skill Endorsements: 64