|
We are not here to do your homework for you!
It is set for a reason. It is there so that you think about what you have been told, and try to understand it. It is also there so that your tutor can identify areas where you are weak, and focus more attention on remedial action.
Try it yourself, you may find it is not as difficult as you think!
Start by reading the values into an array, then write a method to do the sort. That's not difficult, the algorithm is pretty basic and freely available: Bubble sort - Wikipedia[^]
If you meet a specific problem, then please ask about that and we will do our best to help. But we aren't going to do it all for you!
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
|
|
|
|
|
First save the values in an array, then sort.
We do not do your HomeWork.
HomeWork is not set to test your skills at begging other people to do your work, it is set to make you think and to help your teacher to check your understanding of the courses you have taken and also the problems you have at applying them.
Any failure of you will help your teacher spot your weaknesses and set remedial actions.
So, give it a try, reread your lessons and start working. If you are stuck on a specific problem, show your code and explain this exact problem, we might help.
As programmer, your job is to create algorithms that solve specific problems and you can't rely on someone else to eternally do it for you, so there is a time where you will have to learn how to. And the sooner, the better.
When you just ask for the solution, it is like trying to learn to drive a car by having someone else training.
Creating an algorithm is basically finding the maths and make necessary adaptation to fit your actual problem.
Patrice
“Everything should be made as simple as possible, but no simpler.” Albert Einstein
|
|
|
|
|
Hi,
I have written a surveying program for a ppc 2003 device using VB 2005. I need the code to make it search for a Bluetooth instrument and pair with it. It has to send a command for that instrument to take measurements and then receive the measurements and populate text boxes in my program.
Can someone help please..
Many thanks
|
|
|
|
|
This will depend on what commands the device accepts and how it presents the data. The device documentation would be the best place to look.
|
|
|
|
|
Thanks Richard,
For now I just need the code for my program to discover and pair with other devices.
I will contact the manufacturer to see if he is willing to help. Instrument documents don't show anything like that.
Regards
|
|
|
|
|
Google will find you many articles that explain Bluetooth connection and pairing.
|
|
|
|
|
|
i used keyboard shortcuts to windows form application...
but when i minimize the form application key shortcuts what i used for form applies on other applications also ... need help....plz ... send me solution
|
|
|
|
|
Keyboard input is send to the active window. If you have minimized your application it does not have an active window anymore and the input is send to the window which is then active (the desktop if there is no application window).
See also About Keyboard Input (Windows)[^]:
Quote: The system posts keyboard messages to the message queue of the foreground thread that created the window with the keyboard focus. The keyboard focus is a temporary property of a window. The system shares the keyboard among all windows on the display by shifting the keyboard focus, at the user's direction, from one window to another. The window that has the keyboard focus receives (from the message queue of the thread that created it) all keyboard messages until the focus changes to a different window.
...
The concept of keyboard focus is related to that of the active window. The active window is the top-level window the user is currently working with. The window with the keyboard focus is either the active window, or a child window of the active window. To help the user identify the active window, the system places it at the top of the Z order and highlights its title bar (if it has one) and border.
So there is no solution. Your form must be the active window to receive keyboard messages.
|
|
|
|
|
Hello everyone, I'm new here.
I am desperate for a solution to my problem in the visual basic code.
With the library TagLib I can write ID3v2 tags on mp3. I'm having trouble seeing the text Lyrics on Android devices and I realized that the problem is the text encoding (by TagLib).
With an encoding in ISO-8859-1 or UTF16 everything works good, but with UTF8 encoding will not work.
What I would know is how can I set the encoding TagLib write ISO-8859-1.
I do not know how, but it is the library that selects and applies automatic text encoding even if I have encode the text before in ISO-8859-1.
How can I fix?
Here's the code:
Imports TagLib
Dim Testo As String = "Text Lyrics"
Dim mp3 As TagLib.File = TagLib.File.Create("C:\Music.mp3")
mp3.Tag.Lyrics = Testo
mp3.Save()
mp3.Dispose()
Thanks!
modified 20-Feb-17 17:52pm.
|
|
|
|
|
- Read the banner at the top; this is the lounge, general conversation, no programming questions.
- There are forums for various topics; post your question in the appropriate forum.
|
|
|
|
|
Here[^] is the proper forum for your question. You could also ask in "Quick Answers" which is on the banner at the top. You're more likely to get positive responses in one of those two As Tim said, this forum is for casual conversation not questions.
|
|
|
|
|
|
Nothing. I had already tried but could not find anything.
|
|
|
|
|
Im sort of stuck here on using Groups in ListView.
I need to to group invoices to emails, and have a list of contacts within the group to send them to.
I found some examples, but they didn't make sense to me, I just didn't pick up on it.
So with my code example, I have 1 group and it prints in the ListView as Default in Blue
And then my 2 contacts underneath it.
Sounds dumb, so you have to make an item, then add a group of items?
or the other way around?
-- Invoice 120589 - The Big Store
persona@email.com
personb@email.com
presonc@email.com
lv_JobStatus.Groups.Add(New ListViewGroup() With {
.Name = m_invoiceNumber,
.Header = m_invoiceNumber & " - " & m_companyName,
.HeaderAlignment = HorizontalAlignment.Left,
.Tag = idx
})
For Each contact As model_ar_contactRecord In customer.FCONTACTS
Dim item1 As New ListViewItem(m_invoiceNumber, idx)
item1.Checked = False
item1.SubItems.Add(m_item_customerNumber)
item1.SubItems.Add(m_item_companyName)
item1.SubItems.Add(contact.FCONTACT)
item1.SubItems.Add(contact.FEMAIL)
item1.SubItems.Add(If(dwXCode = 0, "X", ""))
item1.SubItems.Add("")
lv_JobStatus.Items.Add(item1)
lv_JobStatus.EndUpdate()
Next
If it ain't broke don't fix it
|
|
|
|
|
I got the group title to format the way I wanted,
Let me see if I can pickup the email destinations now
Dim group1 As New ListViewGroup()
group1.Name = m_invoiceNumber
group1.Header = m_invoiceNumber & " - " & m_companyName
group1.HeaderAlignment = HorizontalAlignment.Left
group1.Tag = m_invoiceNumber
lv_JobStatus.Groups.Add(group1)
For Each contact As model_ar_contactRecord In customer.FCONTACTS
Dim item1 As New ListViewItem(m_invoiceNumber, idx)
item1.Group = group1
item1.Checked = False
item1.SubItems.Add(m_item_customerNumber)
item1.SubItems.Add(m_item_companyName)
item1.SubItems.Add(contact.FCONTACT)
item1.SubItems.Add(contact.FEMAIL)
item1.SubItems.Add(If(dwXCode = 0, "X", ""))
item1.SubItems.Add("")
lv_JobStatus.Items.Add(item1)
Next
If it ain't broke don't fix it
|
|
|
|
|
I'm trying to develop an excel add-in which generates certain reports which need me to add a pivot table. Below are 2 ways I have tried to do it the first one highlights an error "Reference to a non-shared member requires an object reference" and gives me an error on run time:
Dim PTCache As PivotCache = ThisApp.ThisWorkbook.PivotCaches.Create(SourceType:= _ Excel.XlPivotTableSourceType.xlDatabase, SourceData:=ws2.Range("A1").CurrentRegion.Address)
Dim PTable As Excel.PivotTable = ThisApp.PivotTables.Add(PivotCache:=PTCache, TableDestination:=_ ws3.Range("A1"), TableName:="DaPTable")
The second one just runs without any error but No pivot table created at the end:
m PTCache As PivotCache = ThisApp.ThisWorkbook.PivotCaches.Create(SourceType:= _ Excel.XlPivotTableSourceType.xlDatabase, SourceData:=ws2.Range("A1").CurrentRegion.Address). CreatePivotTable(PivotCache:=PTCache, TableDestination:=_ ws3.Range("A1"), TableName:="DaPTable")
Please Help where I'm getting it wrong or another better way of doing it.
|
|
|
|
|
Hi All,
I have created a ribbon to show in "new mail" or compose email window. This is a VB project.
I have three buttons:
- Add To : This adds an email address to the TO
- Add Subject : To add a text into the subject line of the new email
- Add Body : To add the message body.
These three button are available on the new mail windows. How do i get these buttons to work.
Any help is appreciated.
Regards,
Rahul
|
|
|
|
|
Member 13001124 wrote: How do i get these buttons to work. Most likely by writing some code. But without considerably more detail it is anyone's guess what you are trying to do.
|
|
|
|
|
Sorry for being vague.
I have a button on the newmail/compose windows in Outlook. When i click on templates, it should populate the To, CC, Subject and Body of the new email.I have attached a screenshot.
[^]
|
|
|
|
|
Your link is not correct. And I am afraid a picture is not going to tell us anything useful. What code executes when the button is pressed and what errors do you see?
|
|
|
|
|
Thats the problem. I am not sure what code should to use to insert subject line into the subject box of the new email.
I know how to call a new email and set the parameters. but in this case, the button is on the new mail window.
https://1drv.ms/i/s!Aqlv4pnf0jmdnX3WQdSkj-2q52op
|
|
|
|
|
You need to find the names of the properties that refer to those fields in the template. The best place to start would be the Outlook reference documentation.
|
|
|
|
|
Is there a way to make a call from a windows form? The company i work for now uses S4B. I would like to have a button on a form and when the user clicks on the button it will take a phone number from a label or textbox and open there S4B client and place the call. If anyone could point me in the right direction will be a big help.
|
|
|
|
|
Google[^] is the best place to start.
The first result even points you to the MSDN documentation[^].
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|