|
Pick a single forum, don't ask more than once.
Luc Pattyn [Forum Guidelines] [My Articles] Nil Volentibus Arduum
Please use <PRE> tags for code snippets, they preserve indentation, improve readability, and make me actually look at the code.
|
|
|
|
|
Hi;
Please help me in VB6 programming,
for: [On/Off] 2#LEDs by 1#USB port.
source code & simple Electronic Interface.
Thans a lot.
ufo4444p239@yahoo.com
|
|
|
|
|
Not going to happen.
First, VB6 is dead and has been for quite some time. Move to VB.NET.
Second, Google for "VB6 control LED USB" and see what you get. You can do this yourself because it's probably going to be the very first thing anyone else is going to do for you, or not.
|
|
|
|
|
If he pays enough, he will get also VB6 support. I will call it not a fee, but a compensation for pain and suffering.
I cannot remember: What did I before google?
|
|
|
|
|
No help will be coming, VB6 is no longer used or supported.
If you are being taught this, and have paid a fee, demand your money back, right now!
------------------------------------
I will never again mention that I was the poster of the One Millionth Lounge Post, nor that it was complete drivel. Dalek Dave
CCC Link[ ^]
Trolls[ ^]
|
|
|
|
|
je veux savoir comment je peux passer des éléments sélectionnes dans un listbox à un datagrid
|
|
|
|
|
This is an English speak site. This is what Google Translate thinks you said:
I want to know how I can pass the selected items in a listbox to a datagrid
The easiest way to do it would be if you bound the datagridview to the same source you bound your ListBox to.
If not, then you'll have to iterate over the items in the listbox and add them to the rows or a manually setup DataGridView or to a DataTable object and bind your DGV to that.
|
|
|
|
|
I want to read excel sheet cells.
I have written the following code in Visual Basic 2005 in single desktop environment with no net connectivity:
Public Class Form1
Public xl As New Excel.Application
Public xlsheet As Excel.Worksheet
Public xlwbook As Excel.Workbook
Public j As Integer
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
MsgBox("Hello")
xlwbook = xl.Workbooks.Open("D:\sample.xls")
xlsheet = xlwbook.Sheets.Item(1)
TextBox1.Text = xlsheet.Cells(2, 1) ' row 2 col 1
TextBox2.Text = xlsheet.Cells(2, 2) ' row 2 col 2
xl.ActiveWorkbook.Close(False, "D:\sample.xls")
xl.Quit()
End Sub
End Class
I am getting the errors as:
C:\Windows\Microsoft.NET\Framework\v2.0.50727\Vbc.exe /noconfig /imports:Microsoft.VisualBasic,System,System.Collections,System.Collections.Generic,System.Data,System.Drawing,System.Diagnostics,System.Windows.Forms /nowarn:42016,41999,42017,42018,42019,42032,42036,42020,42021,42022 /rootnamespace:VBCheck /doc:obj\Debug\VBCheck.xml /define:"CONFIG=\"Debug\",DEBUG=-1,TRACE=-1,_MyType=\"WindowsForms\",PLATFORM=\"AnyCPU\"" /reference:C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Data.dll,C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Deployment.dll,C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.dll,C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Drawing.dll,C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Windows.Forms.dll,C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Xml.dll /main:VBCheck.My.MyApplication /debug+ /debug:full /out:obj\Debug\VBCheck.exe /resource:obj\Debug\VBCheck.Form1.resources /resource:obj\Debug\VBCheck.Resources.resources /target:winexe Form1.vb Form1.Designer.vb "My Project\AssemblyInfo.vb" "My Project\Application.Designer.vb" "My Project\Resources.Designer.vb" "My Project\Settings.Designer.vb"
error BC30002: Type 'Excel.Application' is not defined.
error BC30002: Type 'Excel.Worksheet' is not defined.
error BC30002: Type 'Excel.Workbook' is not defined.
How to get rid of this error?
|
|
|
|
|
|
Do you have Excel installed?
Can you post import directives?
This may help.
"You get that on the big jobs."
|
|
|
|
|
You'll have to add
Imports System.Runtime.InteropServices
Imports Microsoft.Office.Interop.Excel
|
|
|
|
|
I am working on a VB.Net project and have been using SVN(tortise SVN) for version control.
So far I have been making commits on the whole project folder so all files that have been changed are committed at the same time and the log comments apply to all the changed files .
Is there any advantage in committing single files at a time when I have made changes to a group of source code files.
Any advice on best practice would be helpful.
This is the first project I put under version control that has really grown in file count size.
Thanks,
cages
|
|
|
|
|
What you are doing is standard. I'm not aware of any advantage to committing single files. Sometimes other developers are waiting for your changes so that could be a reason. Best to complete a single task and commit before starting another task, if possible.
"You get that on the big jobs."
|
|
|
|
|
Thanks, I will keep committing all changes at the same time. Might make less changes between each commit to reduce the information that should be included in the log.
I have not been committing changes regularly as I am the only developer.
Cages
|
|
|
|
|
It's been a few years since I used SVN (Tortoise SVN), but from what I remember is that SVN is actually quite good at posting only the necessary changes back to the repository each time you commit. For example, if you had a 100 line SQL script and you made 2 lines of change, the only thing that was actually stored back in SVN was the 2 lines of change. At least that is what I remember ... I could be wrong.
Remember that you don't need to version control the binary files created by Visual Studio, only the source files. Storing of binary files may not be very efficient in SVN.
My 2 cents.
|
|
|
|
|
I am trying to put the ribbon in the nonclient area, and have the caption buttons on top of it, and also be able to drag the form by the title bar.
I want to make the ribbon look like the picture shown here: http://ribbon.codeplex.com[^] instead of what is shown on the http://guitarsoft.codeplex.com[^] The ribbon not embeded in the non-client area
Im just a newbie and Im grateful for any help.
|
|
|
|
|
|
What is the link? its asking me to download something.
Nagy Vilmos wrote: And eat bacon. Bacon's real important for 'puters.
|
|
|
|
|
A rar-file, and it contains;
Visual Basic 6 code
I are Troll
|
|
|
|
|
Link provided by you is WebHosting related stuff and my ISP has blocked it.
Regarding your question, use Random Number to generate Random Class to assign a teacher.
|
|
|
|
|
Vb Rnd wrote: How can I distribute periods for teachers randomly in an ideal facility?
I'm sorry, but your question is too complex for me to understand. You'd get more responses if you'd;
- Copy the code that you wrote (part with the question-marks) here
- Can give an example of a couple of teachers and where'd you like to distribute them (the datastructure)
I'd also mark it as VB6-code, as most people will be expecting VB.NET as it's got a comparable syntax.
You already did that
I are Troll
|
|
|
|
|
Hi friends,
I am trying to Write the CD from my VB6 application and succeeded using IMAPI.
But before writing the content into CD I need to check whether CD inserted or not and CD has enough disk space or not .
Can any one please help me in this task.
Thanks in advance
|
|
|
|
|
Hi I have written code to check whether Cd inserted or not in drive using WMI wuery and VB6.
But while executing the code it throwing an error in while entering into 'For each' loop i.e <b>Runtime error '-21456793':Automation error.</b>
Can any one please help me to find out the solution for this.
Private Sub Command1_Click()
Dim strComputer
Dim objWMIService
Dim colItems
Dim objItem
strComputer = "."
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2")
Set colItems = objWMIService.ExecQuery("Select * from __InstanceModificationEvent Within 1 Where TargetInstance ISA 'Win32_CDROMDrive' and TargetInstance.MediaLoaded = True and PreviousInstance.MediaLoaded = False ")
For Each objItem In colItems
MsgBox "Device ID: " & objItem.DeviceID
MsgBox "Media Loaded: " & objItem.MediaLoaded
Next
End Sub
Thanks in advance
|
|
|
|
|
Please help! I'm not a script wrriter, I used skript form "scripting Guys" to extract text marked in certain color from Word document, and it works great for any color. Then I got Word 2007 and now same script works only with color "Red", none of other font colors does work. If I use "brush tool" and apply, let say color "blue" or, any other, from my old document made in Word 2003, script works, but when I use colors from Word 2007 manu it does not. Below is the script (this one for Red and the only one that works):
Const wdColorRed = 255
Set objWord = CreateObject("Word.Application")
objWord.Visible = True
Set objDoc = objWord.Documents.Open("C:\Scripts\Form name for test.doc")
Set objSelection = objWord.Selection
Set objDoc2 = objWord.Documents.Add()
Set objSelection2 = objWord.Selection
objSelection.Find.Forward = True
objSelection.Find.Format = True
objSelection.Find.Font.Color = wdColorRed
Do While True
objSelection.Find.Execute
If objSelection.Find.Found Then
strText = strText & objSelection.Text & vbCrLf
Else
Exit Do
End If
Loop
objSelection2.TypeText strText
Thanks!
|
|
|
|
|
Apparently you have to specify a new color value to search for. 255 would indicate Red. This value has to be changed to the color value you need.
That first line could be rewritten as:
Const wdColorRed = RGB(255, 0, 0)
You need to specify either the integer value for the color you want, or the three integers inside the RGB function to build the color value for you. Each component of those would be in the range 0 to 255.
|
|
|
|