|
sorry sir, I did not mean that . I wanted to know , the line number , On which the cursor presently is, into the textbox , programically.
Thanks and regards
Pankaj
|
|
|
|
|
Hi,
you can take a look here for a start:
http://www.codeproject.com/cs/samples/linenumberingapp.asp[^]
There are also heaps of hits on google which let you use GetCurPos() and GetCursorPos() to get the position of the caret if you wish to return the line you are currently editing. I'm sure there are some built in things in the framework, though I'm really tired and can't think at the moment.
Cheers,
Daniel
|
|
|
|
|
goodMorning Frendz,
I have one column of datagridview as "date"....so i wnt to ask-> "Is there a columntype of datagridview like "DatagridviewDateTimepicker" like "DataGridViewComboBoxColumn"....if i wnt take datetimepicker on datagridview's each row on specified column wht should i do?
Help me Plizz.
Regards priya
|
|
|
|
|
|
Mam ,
Is this link useful?
Regards
Pankaj
|
|
|
|
|
Thank u so much pankaj....thts nice site.
regards priya
priya
|
|
|
|
|
Hi everyboy. I want to encrypt content in text file and decrypt it to normal text file. please show me the code that do it. thank beforehand.
|
|
|
|
|
|
They System.Cryptography namespace is your best bet here.
Christian Graus - C++ MVP
'Why don't we jump on a fad that hasn't already been widely discredited ?' - Dilbert
|
|
|
|
|
best is rijandel or something like that!!! try Google it...
|
|
|
|
|
How to make a scrolling marque? or do you have some web links that could help my search faster.. thank you...
your help is highly appreciated.. thank you guys...
|
|
|
|
|
Where, in your web app, or your desktop app ? If the latter, the answer is to write one, or google for one that already exists. You'd just set a timer and modify a string you render, to create a scrolling effect.
Christian Graus - C++ MVP
'Why don't we jump on a fad that hasn't already been widely discredited ?' - Dilbert
|
|
|
|
|
|
:(I need to convert any date to a double or long; please help. Thanks
sdkgolf
|
|
|
|
|
Sure
DateTime.Year * 500 + DateTime.Month * 27 + DateTime.Day.
Or, do you require it to be in a specific format ? What are you using it for ?
Christian Graus - C++ MVP
'Why don't we jump on a fad that hasn't already been widely discredited ?' - Dilbert
|
|
|
|
|
The Ticks property of the DateTime class gives you a long value that represents the time in ticks since midnight, January 1, 0001. There are 10000 ticks on a second.
---
Year happy = new Year(2007);
|
|
|
|
|
Thanks guys, but I figured it out on my own, using the below code;
' gets the long number for the date from the date variable
Dim idDt As Double
idDt = Date.Today.ToOADate
Dim dtToday As Date
dtToday = Today()
Dim idt As Long
idt = DateDiff("d", Today(), dtDa)
idt = idt + CLng(idDt)
|
|
|
|
|
I would like to write code in Visual Basic 2005 to produce a text box on a form.
Here is the code which doesn't work.
Public Class Form1
Private Sub CreateMyMultilineTextBox()
' Create an instance of a TextBox control.
Dim textBox1 As New TextBox()
' Set the Multiline property to true.
textBox1.Multiline = True
' Add vertical scroll bars to the TextBox control.
textBox1.ScrollBars = ScrollBars.Vertical
' Allow the RETURN key to be entered in the TextBox control.
textBox1.AcceptsReturn = True
' Allow the TAB key to be entered in the TextBox control.
textBox1.AcceptsTab = True
' Set WordWrap to True to allow text to wrap to the next line.
textBox1.WordWrap = True
' Set the default text of the control.
textBox1.Text = "Welcome!"
End Sub
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
' Create UserTextBox TextBox control.
Dim UserTextBox As New TextBox()
CreateMyMultilineTextBox()
MessageBox.Show("Done")
End Sub
End Class
What, pray tell, is missing? It is a direct copy of MSDN's Visual Basic Express Visual Basic Programming Guide.
Thank you for your help.
Mark H.
|
|
|
|
|
Do you get any errors?
Trinity: Neo... nobody has ever done this before.
Neo: That's why it's going to work.
|
|
|
|
|
No oddly enough, I don't get any errors.
I suspect I have left something out that most visual programmers know about. I've made the textbox visible, made it 20,20 in size, but it still won't appear on the form. Maybe it's not supposed to be done in the form load subroutine.
Mark H.
Thanks for answering.
Mark H.
|
|
|
|
|
Controls.Add(textbox1)
You need to add it to the forms controls collection
Christian Graus - C++ MVP
'Why don't we jump on a fad that hasn't already been widely discredited ?' - Dilbert
|
|
|
|
|
Amazing.
Simple things for simple minds!
Many thanks.
I hope I can help people the way you help me.
Mark H.
|
|
|
|
|
You will - I started off asking lots of questions, over time, you start to ask less, and answer more
Christian Graus - C++ MVP
'Why don't we jump on a fad that hasn't already been widely discredited ?' - Dilbert
|
|
|
|
|
I want to connect oracle 9i database with vb.net. Can anyone help me in doing this?
Thank you.
|
|
|
|
|
Use OleDbConnection
Example connectionString:
"Provider=msdaora; Data Source=MyOracleDB; User Id=myUsername; Password=myPassword;"
Very simple example:
Public Sub InsertRow()
Dim myConnection As New OleDbConnection(myConnectionString)
Dim myInsertQuery As String = "INSERT INTO Customers (CustomerID) Values('1')"
Dim myCommand As New OleDbCommand(myInsertQuery)
myCommand.Connection = myConnection
myConnection.Open()
myCommand.ExecuteNonQuery()
myCommand.Connection.Close()
End Sub
-- modified at 15:19 Monday 15th January, 2007
---------------
http://serverside.no
|
|
|
|