|
If you are using a datagridview here's an example:
txtAC.Text = DataGridView1.CurrentRow.Cells(9).Value & " "
PUT THIS IN THE DATAGRIDVIEW CLICK EVENT.
jhoga
|
|
|
|
|
Hi all,
Datagrid ctrl using with ComboBox and Text box...But how to assign the Value in Datagrid..so pls send me sample coding format.........
thanking you
Somasundaram G
|
|
|
|
|
Hi
Wath is Your Usage?
You Use DataGrid With Database? or Not?
Mogtabam
|
|
|
|
|
Yes through Database Only... Pls tel me...
iam selecting the item in combobox from Database....
somasundaram
|
|
|
|
|
You Must Use Microsoft ADO Control (for example Named Adodc1). And Set TextBox & Combobox DataSurce to Adodc1 & Specified DataField For TextBox & ComboBox.
Then If You Change Textbox Or Combobox The Data In DataGrid & DataBase Will Be Changed.
Good Luck
Mogtabam
|
|
|
|
|
I have created a form in the Resolution of my system as 1024 X 768 Pixels. But when I submit the project at the client side the Resolution is some 800 X 600 Pixels. In some other different Resolution is there.
How can I change my Form Dynamically according to the Resolution present in the System where we are using.
Thanx in advance
Priya
|
|
|
|
|
Hi
This May Useful for you.
Width Of Screen In Pixel: Screen.Width / Screen.TwipsPerPixelX
Height Of Screen In Pixel: Screen.Height / Screen.TwipsPerPixelY
For Example :
Private Sub Form_Load()
Me.Width = Screen.Width
Me.Height = Screen.Height
Me.Top = 0
Me.Left = 0
End Sub
Good Luck
Mogtabm
|
|
|
|
|
|
I have created a form in the Resolution of my system as 1024 X 768 Pixels. But when I submit the project at the client side the Resolution is some 800 X 600 Pixels. In some other different Resolution is there.
How can I change my Form Dynamically according to the Resolution present in the System where we are using.
When I Use this Code:
Width Of Screen In Pixel: Screen.Width / Screen.TwipsPerPixelX
Height Of Screen In Pixel: Screen.Height / Screen.TwipsPerPixelY
For Example :
Private Sub Form_Load()
Me.Width = Screen.Width
Me.Height = Screen.Height
Me.Top = 0
Me.Left = 0
End Sub
Displaying of Form is OK.
But controls are missing.
What I need is It has to adjust the controls also according to the System Resolution and all the content present in the Form should be displayed in the Resolution present in the System.
controls as well as form should be resized according to the System resolution.
Priya
|
|
|
|
|
Hi
For Resizing Controls You Can Use "Microsoft Forms2"
You Can Resize Zoom In & Zoom Out In Microsoft Forms2 Components.
But I don't Remember How You Can Resize Or Zoom In & Zoom Out.
If I Remember I Will Send You An Example Code.
Good Luck.
Mogtabam
|
|
|
|
|
What I have done in the past is design the form at the lowest usable resolution, then in the same routine that sets the size of the form I figure out the difference in the screen sizes and iterate through the forms control collection and set the position and size to what I want it to be.
You also will need to adjust your font size for each control
-- modified at 12:32 Monday 12th March, 2007
|
|
|
|
|
write an HTML code to present two frames in a window. the first frame presents the list of programming labs for MCA-IIyr. and the second frame presents the list of programs to be written in the selected programming lab.write vbscript to do the above.
|
|
|
|
|
Is this your homework that you are trying to get someone else to do for you? It really sounds like that, anyway.
Unless you explain a bit more about what you are doing, and specifically what it is that you need help with, I don't think that you will get many answers.
Also, this is rather a web development question than a VB question. VBScript is not VB.
---
single minded; short sighted; long gone;
|
|
|
|
|
I want to change the color of the small box in the checkbox.
If I change the backcolor to white, it does not affect the small square inside the checkbox border on which we actually click.
Can anyone please tell me how can I change that color ?
|
|
|
|
|
I dont' believe you can simply by setting a property. You can extend the checkbox by creating a class and inheriting the checkbox. In the OnPaint event you could fill that square in yourself with a different color. However, you'll have to draw the check mark as well.
|
|
|
|
|
when a row is double clicked in datagrid ,the row data should display in textboxes.waiting for help.
thank u
-- modified at 1:03 Tuesday 13th March, 2007
|
|
|
|
|
Generally whenever you are displaying data in a grid it contains a unique value in a particular column. So, put the unique column number
Formname.textboxname.text=val(datagrid.textmatrix(datagrid.row,colnumber)
Then you can write a query for displaying other things using this unique vale
I hope this can solve your problem
Priya
|
|
|
|
|
I am making a windows application in VB.NET 2003 and ACCESS.I want to set reminders through a windows form.I want a popup message to be shown whenever I login to my system or a pop-up is shown whenever the reminder time is equal to my system clock.
Please help me.
Live life to the fullest
|
|
|
|
|
what coding do i do so that my textbox take values only between two integers say 0 to 45, any value other than this range gives error..
thanks
|
|
|
|
|
Try a NumericUpDown control. If that's not an option you could do this a few ways. For one, in the validating event you could check the value to see if it's okay. Unless you want to disable copy/paste you'll probably have to validate the entry here anyway. The other option would be in the keypress event. You could check if the keypress was a number, if it's not you wouldn't allow it. Secondly, if it's a digit and the current contents including the new digit is > 45 you could dissallow it. If you prevent '-', this would take care of anything less then 0 so you wouldn't really need to worry about it.
|
|
|
|
|
Hi
You Can Use This Code.
(Text1 is your TextBox)
Private Sub Text1_Change()
If Val(Text1.Text) > 45 Then Text1.Text = 45: MsgBox "Please Enter A Number Between 0 to 45", vbCritical
End Sub
Private Sub Text1_KeyPress(KeyAscii As Integer)
Select Case KeyAscii
Case 48 To 57: '0 To 9
Case 8: 'Back Space
Case 13: 'Enter
Case Else: 'Other Keys
KeyAscii = 0
End Select
End Sub
Good Luck
Mogtabam
|
|
|
|
|
thanks people...
for sending me solutions...
regards..
manni
|
|
|
|
|
Hi,
Could anybody tell me what I'm doing wrong with this:
Dim objDsExistingXRatesFile As DataSet<br />
objDsExistingXRatesFile = New DataSet("StoredRates")<br />
objDsExistingXRatesFile.ReadXml("xrates.xml")<br />
<br />
Dim MaxRows = objDsExistingXRatesFile.Tables("StoredRates").Rows.Count<br />
MsgBox(MaxRows.ToString)
Its giving me an error on the 'Dim MaxRows' line saying, "NullReferenceException was unhandled" - "Object reference not set to an instance of an object" - advising me that I need to use the New command.
It isn't null, because I can put the data into a DataGridView to test it!
|
|
|
|
|
Try:
Dim MaxRows as integer = objDsExistingXRatesFile.Rows.Count
|
|
|
|
|
Check that the table "StoredRates" actually exists in the objDsExistingXRatesFile dataset.
It looks like the name of your dataset is "StoredRates", not the table. Not sure what the table name would be as that may depend on your XML.
|
|
|
|