|
Add a reference to Microsoft Agent in your project's References or add the Microsoft Agent Control to your form and use the Set Char = Character.Load ("CharacterName", "CharacterFilePath") to load the character.
|
|
|
|
|
|
sun of tuscany helps grapes
|
|
|
|
|
i need help in changing the txt colour in the txt box by pressin a button i've only just started this
|
|
|
|
|
under the click event, try this
Textbox1.ForeColor = Color.Red
That will change the font color of the textbox to Red.
|
|
|
|
|
In VB6, is there a way to manage the printer spool for adding documents in stand-by mode, remove them when necessary, ... ?? I'm wondering if there's a way to do that not depending onto the printer selected.
Thanks in advance,
Marc Soleda.
PD: I've posted the same message in VC++ forum bcause I need to do it in both platforms.
... she said you are the perfect stranger she said baby let's keep it like this... Tunnel of Love, Dire Straits.
|
|
|
|
|
There are a number of API calls in Winspool.drv that allow you to monitor, alter and delete print jobs e.g. OpenPrinter, GetJob, SetJob, FindFirstPrinterChangeNotification etc.
|
|
|
|
|
Hello All,
I have developed an application using vb.net. Now I want to create its setup in InstallShield 10.5. The problem is that in the setup I need to check two things
1. Microsoft .Net Framework 1.1 is installed
2. MDAC 2.7 is installed.
If any of them is not installed on the destination machine then install it else not.
Plz tell me how to achieve it. How to apply conditions on setup.
Thanx in Advance
_mubashir
|
|
|
|
|
|
I have a datagrid in which I have 'Paging' functionality of type numeric (pages 1 to 10....) and also a search functionality wherein the user enters say name or branchname or recordno in the text box and the datagrid searches the desired record/s.
My problem is the 'search' functionality works only the first page (or parent page) of the datagrid but when I am on say page no 2 or 4 or 10 etc... it doesn't work it comes with the following error:
System.Web.HttpException: Invalid CurrentPageIndex value. It must be >= 0 and < the PageCount.
My code for paging is as follows:
'***********************************************************************
Sub DataGrid_PageChanger(Source As Object, E As DataGridPageChangedEventArgs)
' Set the CurrentPageIndex before binding the grid
DataGrid.CurrentPageIndex = E.NewPageIndex
Refreshgrid(Cint(ddlBranch.SelectedItem.Value),txtsearch.text)
End Sub
'***********************************************************************
Any suggestions?
Thanks a ton!!!
Aartee.
...HE is watching Us All!
|
|
|
|
|
Hello all. I've been programming for quite a while now, but I'm stuck wiht something and I need some help.
I have a program in which users add information into a database type thing. The information they are adding is going to be mainly one of the items in an arraylist, but not always.
I need some code that will do like an "auto complete" type thing. If there is an item with "Hello" in the arraylist and the user types in an "H", "ello" will appear, selected. If "Howdy" is also in the arraylist and they add a "o" to the "H", (making the text box text "Ho"), I need a "wdy" to appear, selected.
Basically, an autocomplete feature.
Please help me with this!!
|
|
|
|
|
How are the users entering the data? Is it on a .NET form? If so, try using a ComboBox control. It can do most of what you want.
...Steve
|
|
|
|
|
It is on a VB.NET form. However, a) there are too many different possible things to work with a Combobox. It would be too slow to work with. b) The users have to be able to insert their own data if it's not in the list. If you have the ComboBox property on "DropDownList", the autocomplete property does what it's supposed to (you type in the first few letters and get the rest of it), but it doesn't allow you to add your own items.
Right now I'm taking the autocomplete things I can find and trying to put them into a text box and an arraylist, rather than the combobox which they're written for. None of the ones I have tried so far have worked though...
Thanks anyways... any other ideas?
|
|
|
|
|
OK I see your problem more clearly. How many list entries are you talking about? 100, 1000, 10000? I don't have a complete answer but I'd tackle it like this:
1. Set the DropDownStyle to DropDown (not DropDownList) then you get partial functionality whereby the combobox will allow entry of non-ListItem text. When the user hits the down arrow the entry in the list that starts with the entered text (if one exists) is auto selected.
2. Override several of the combobox events to capture the entered text character by character and auto-complete the text depending upon the combobox's ListItems (i.e. if there is an entry that starts with the entered text, set the Text property to match it etc).
3. If there is no corresponding entry in the ListItems do nothing yet. You can then programmatically determine whether or not to add this to the combobox's list or store it for future use.
These suggestions may already be implemeted in code you've obtained elsewhere. My advice though is to customize the operation of the ComboBox rather than roll your own since a lot of the work has already been done for yuu - unless there is good reason to abandon it.
...Steve
|
|
|
|
|
Hello Steve,
I have fixed the problem!
The estimated number of entries is about 2,500, although it may be more. I copied all of them into MS Word, each entry taking up one line, and it was 61 pages long! Thus, I didn't want to use a ComboBox for this.
However, searching through this site, there were a few things for autocomplete for a ComboBox. None of them worked for even a ComboBox. I edited the code up so that it would work correctly. Then, I edited the code even more to replace the ComboBox items with the arraylist items. I had to add a few things to make up for features that were included with the ComboBox that weren't with the array list(like the search features). I also had to add some code to get the selection stuff to work properly, but for the most part it worked fine.
Also, because it's SO terribly slow to search through 2,500+ items in an arraylist, I am using multiple arraylists. When it's ready to search, it finds out which arraylist to use and searches in that one. The result? MUCH faster and MUCH smoother running.
Thank you for your time!
If anyone else is interested, I would be glad to e-mail you the result.
|
|
|
|
|
Glad to hear you've solved it Matthew. Please feel free to write an article for The Code Project with your solution. I'm sure that others will be interested.
...Steve
|
|
|
|
|
This is the best I could come up with, not very good coding, but it's all I got and hopefully it'll help you get what you need. This works on buttons only, and you need to hit the button for it to check.
This code does NOT work. There's a problem with the indexof that I can not figure out, and therefore I'm posting this after 1hour+ worth of thoughts and this is it. This is not advanced coding by the way, just how I would come about this issue.
Dim database(99) As String
Dim counterbtn As Integer
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
counterbtn += 1
database(counterbtn) = txtbox.Text
End Sub
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
Dim wordlist(99) As String
Dim r As String
Do
Dim b As String = txtbox.Text
counterbtn += 1
r = database(counterbtn).IndexOf(b)
If r <> 0 Then
wordlist(counterbtn) = database(counterbtn)
End If
Loop Until counterbtn = "99"
End Sub
|
|
|
|
|
How will I going to open a file and browse from it like read/write?
If so happen that I'd like to call a VC++ function or classes from their program, How? Is it possible? Newbie here, sorry
|
|
|
|
|
I'm sorry but I cannot understand what you are talking about. I realize that English may not be your native language but we must have a more coherent question before we can attempt to understand and then help you.
From what I can read between the lines of your post you want to do some very basic file operations from within a program? If so, a Google[^] search will probably find you more help in the first instance than this board.
...Steve
|
|
|
|
|
VC++? --> Throw New Exception("Wrong Board")
To Browse for a file have a look at the OpenFileDialog Class in the MSDN, it's ready to use.
To Open a File you can use old legacy Open VB statement (definetly not advisable) or open it through one of the .NET provided classes. It really depends on the file content and waht are you to do with it.
|
|
|
|
|
hi all,
I need some help in Vb.net or VB6 i would like to retrive the public IP of the system which is similar to the http://www.nirsoft.net/show_my_ip_address.php i would like to Retrive even if i a behind the firewall. Can any one help me on that. If you have one please mail me the code to
suresh@fuseflow.com
Thanks in Advance
Sur
|
|
|
|
|
You have two options to write this application.
1) You can write an application to try to resolve the host name assigned to you by your ISP. This will usually return the IP address assigned to you. (This one is easier!)
2) Or, you can write your application to talk to your router and get the address from either a telnet server on your router or from a web page from your router. In iether case, you'll have to parse the data returned to get at the address.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Does VB .NET 2003 have a bug with the UrlEncode method?
It will not convert ' to %27
As a result HREF using Request.QueryString.ToString fails due to an extra quote.
For example:
F1="Fred's Fish"
F1 = Server.UrlEncode(F1)
'F1 returns "Fred's+Fish"
I am having to write a replacement function for UrlEncode.
Gary
|
|
|
|
|
There are no known issues with the .UrlEncode() method.
But since you're putting this path into an A HREF tag, shouldn't you be using .UrlPathEncode() instead?
HttpServerUtility.UrlPathEncode Method[^]
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Thanks for responding.
I don't need .UrlPathEncode since I am creating a custom link to another page.
As for the .UrlEncode shouldn't it encode a Quote character?
I have traced it and a ' does not encode to %27. What am I missing?
Gary
|
|
|
|