|
Hi,
Im using a Pie Chart from Component art & was wondering if you could add a click event on the legend, so it will redirect to another page.
Thanks in advance.
|
|
|
|
|
Your best bet is to ask the vendor.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
|
Please help..........
How to refresh font folder after installing new fonts by application setup?? by using Vb.Net
Hitesh sojitra
modified on Monday, September 15, 2008 2:45 AM
|
|
|
|
|
After copying fonts to Fonts folder, you will need to use AddFontResource Api function.
You may also check following link to get more information about this method –
http://www.pinvoke.net/default.aspx/gdi32/AddFontResource.html
-Dave.
------------------------------------
http://www.componentone.com
------------------------------------
|
|
|
|
|
I have a textbox with AutoCompleteSource set to CustomSource. AutoCompleteCustomSource has to be of type AutoCompleteStringCollection. During suggestions, .NET uses--I believe--sort on strings and gives suggestions. So if the string collection contains: 22, 26, 2162, 2052, 2002 and user types in 2 it will suggest 2002, 2052, 2162, 22, 26 because this is ascending order for strings. However, I want it to suggest in ascending order for integers so suggestion will be: 22, 26, 2002, 2052, 2162.
Even if the source for AutoCompleteCustomSource is sorted it get resorted based on string sort. Any ideas how I can show them in ascending order of integers?
|
|
|
|
|
Please don't cross post, you already asked this in the C# forum. Just because you didn't get an answer quickly posting to another forum will not help. If you bothered to use Google you could have found the answer anyway.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
I did use Google and I did not find an answer. I need help and since I did not get it in the C# forum I thought I will give it a try here as vb.net developers are more familiar with .NET controls--at least that is what I think.
Ashfield wrote: If you bothered to use Google you could have found the answer anyway.
Can you provide a link?
|
|
|
|
|
Hi There
I have done the Auto Complete Text Box in vb.net
You have to write the code in Form Load Event
Here there is a TextBox named txtVehicle_No
and a Sub named AutoComplete.
call the Sub in form load event
I have fetched data from oracle database
see the code......
Private Sub AutoComplete()
txtVehicleNo.AutoCompleteSource = AutoCompleteSource.CustomSource
txtVehicleNo.AutoCompleteMode = AutoCompleteMode.Suggest
adp = New OracleDataAdapter("select distinct vehicle_no from pil_tripvehicle", CDF.Connection)
tbl = New DataTable
adp.Fill(tbl)
Dim auto As AutoCompleteStringCollection = New AutoCompleteStringCollection()
For i As Integer = 0 To tbl.Rows.Count - 1
auto.Add(tbl.Rows(i)(0).ToString)
Next
txtVehicleNo.AutoCompleteCustomSource = auto
End Sub
Ashim Das
|
|
|
|
|
This has now happened 3 times with VS 2005. For some unknown reason (to me) there comes a point when I rebuild the app and all the toolstrip buttons disapear.
They are still in the app (looking at the properties combo) but they do not show anymore.
Is this a bug?
I have re-written this app 2 other times becaue of the same issue, getting a little old.
tia
Rafone
Statistics are like bikini's...
What they reveal is astonishing ...
But what they hide is vital ...
|
|
|
|
|
Ok I had a post earlier about finding a string in a file and all that, well I got that code working, but I have a new problem. I want to put it all into a function or a sub. I'm not sure what the difference is but I want it to have an input, use the code, and then return what the code says. Is something like this possible? Here is the code I am using:
The input is startval and the output is roundednum
I have a listbox full of options, and there are cases under if it is selected, it would input a string to be searched and then a number would be returned.
Dim fs As New FileStream("C:\Program Files\World of Warcraft\WTF\Account\<accountname>\SavedVariables\Auc-Stat-Simple.lua", FileMode.Open)
Dim sr As New StreamReader(fs)
Dim intcounter As Integer
Dim line As String = ""
Dim count As Integer
Dim LineOfText As String
Dim i As Integer
Dim aryTextFile() As String
Dim startval As String
Dim chArr() As Char = {"""", ","}
Dim roundednum As Double
startval = ""
Try
Do
line = sr.ReadLine()
If line IsNot Nothing Then
If line.Contains(startval) Then
intcounter = intcounter + 1
If intcounter = 1 Then
LineOfText = line
aryTextFile = LineOfText.Split(";".ToCharArray)
For i = 0 To UBound(aryTextFile)
count = count + 1
If count = 6 Then
roundednum = aryTextFile(i).Trim(chArr)
If roundednum.ToString.Length = 5 Then
roundednum = roundednum * 0.01
roundednum = Math.Round(roundednum, 0)
Else
roundednum = roundednum * 0.0001
roundednum = Math.Round(roundednum, 0)
End If
'Label11.Text = (aryTextFile(i).Trim(chArr))
Label11.Text = (roundednum)'as a test
count = 0
End If
Next i
'Label11.Text = line
End If
End If
End If
Loop While line IsNot Nothing
Catch a As Exception
Label11.Text = "Not Found"
End Try
sr.Close()</accountname>
|
|
|
|
|
Maffyx wrote: I want to put it all into a function or a sub. I'm not sure what the difference is but I want it to have an input, use the code, and then return what the code says. Is something like this possible? H
Ahhh...one of the things I really disliked about VB/VB.NET was that it makes such a distinction between a "sub" and a "function". This difference is really just a syntax difference that the language exposes, not a real difference in the runtime itself.
A "sub" and a "function" are both part of a concept generally known as methods. A method can have a "return type" or can return nothing, in which case it is said to have a "void" return type. The return type is the output of the method. In all cases a method can have one or more parameters specified, which are the inputs to the method.
Most languages do not make a distinction between a method that has a real return type or a void return type. VB/VB.NET, however, does. A "sub" in VB/VB.NET is simply a method that has a void return type while a "function" is a method that has a real return type.
You actually answered your own question when you asked it...you specifically stated that you "want it to have an input...and then return..." so you are looking for a "function" that has a real return type.
As far as taking your code and wrapping it in a function, you need to decide what your inputs should be and what your return type should be. Looking at your sample code it looks like you are setting Label11.Text so you probably want to return a String value and you probably want a String return type as well.
Your code should end up looking something like this:
Public Function F1 (filePath as String) As String
Begin
' Your code goes here...
' This is how you actually return a value from a function. In this
' case the function returns a String, so you set the name of the
' function equal to the value you want returned.
F1 = "text"
End
Scott Dorman Microsoft® MVP - Visual C# | MCPD
President - Tampa Bay IASA
[ Blog][ Articles][ Forum Guidelines] Hey, hey, hey. Don't be mean. We don't have to be mean because, remember, no matter where you go, there you are. - Buckaroo Banzai
|
|
|
|
|
Awesome thanks for the help, this worked out well for me!
|
|
|
|
|
You're welcome. Glad you got it worked out.
Scott Dorman Microsoft® MVP - Visual C# | MCPD
President - Tampa Bay IASA
[ Blog][ Articles][ Forum Guidelines] Hey, hey, hey. Don't be mean. We don't have to be mean because, remember, no matter where you go, there you are. - Buckaroo Banzai
|
|
|
|
|
Anyone here know how to get the number of items currently in the user's Recycle Bin? Oh, and just to let you know, i'm using .NET 3.0, so it will have to work in that.
Edit: almost forgot. If you know how, i would also like something that can return the path to the user's recycle bin, or a function that will empty it. Thanks.
modified on Saturday, September 13, 2008 8:06 PM
|
|
|
|
|
|
lol, Didn't mean it had to be .NET, just had to work in it. Thanks.
|
|
|
|
|
I am trying to import data using xml file into Tally. For that i am using below code in vb.net.
Dim strXml As XmlTextReader
myLink = New RTSlink()
strXml = New XmlTextReader("Test.xml")
strXml.MoveToContent()
Dim n As Long = myLink.Send(strXml.ReadOuterXml(), TallyServer)
Thanks
Regards,
Pinakin
|
|
|
|
|
... and? I take it there's a question in there somewhere... Maybe if you explained what you're trying to do, what Tally is, and and error messages your getting, we might be able to help.
|
|
|
|
|
I assume something is not working, so I suggest you contact Tally - whoever they are.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
My system gives the following "An unhandled exception of type 'System.Data.OleDb.OleDbException' occurred in system.data.dll
what does it mean?
Can someone help me please?
|
|
|
|
|
dereck wrote: Can someone help me please?
of course - first go and read the topmost post in the forum about how to get an answer to your question ..
then, you're going to need to debug/trace through your source code to the line(s) you think are throwing the exception
then you're going to need to post some source-code ie the lines surrounding the line where the error occurs, so people can maybe look at it
... else its a bit like expecting us to be mind-readers
|
|
|
|
|
Garth J Lancaster wrote: to be mind-readers
Sorry, my mind reading department is closed for the weekend
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
"Not only do you continue to babble nonsense, you can't even correctly remember the nonsense you babbled just minutes ago." - Rob Graham
|
|
|
|
|
yeah well, its 1:19am on a Sunday am here, a colleague and I are in the office for perhaps another hour ... so if they read my mind it'll be
------------------------------------------ (flatline)
|
|
|
|
|
Garth J Lancaster wrote: so if they read my mind it'll be
------------------------------------------ (flatline)
Yep
My mom once had a license plate frame on her car that said:
I read your mind, but it was blank
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
"Not only do you continue to babble nonsense, you can't even correctly remember the nonsense you babbled just minutes ago." - Rob Graham
|
|
|
|