|
aajignesh wrote: i am never use treeview before
...or Google apparently. Only about 378,000 hits on google for treeview samples in VB so it should be possible for you to use one of those.
Bob
Ashfield Consultants Ltd
Proud to be a 2009 Code Project MVP
|
|
|
|
|
Sarcasm is the lowest form of wit but I love it
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Mycroft Holmes wrote: Sarcasm is the lowest form of wit
I know, but sometimes its just too tempting
Bob
Ashfield Consultants Ltd
Proud to be a 2009 Code Project MVP
|
|
|
|
|
Ah the rapier like thrust of a well weighted insult into the vitals of such a pillock as this, is most satisfying I must admit.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Mycroft Holmes wrote: Ah the rapier like thrust of a well weighted insult
Wouldn't say it was that good
Mycroft Holmes wrote: such a pillock as this
can't argue about that
Bob
Ashfield Consultants Ltd
Proud to be a 2009 Code Project MVP
|
|
|
|
|
Just parse your datatable in dataset with parent and child fields and add nodes to treeview, can you handle this or you want more in code?
|
|
|
|
|
Ya sir Please Give Me Some code
|
|
|
|
|
Hi to All,
I have created a new process using
dim p as new process
And then I have ran a particular file. But, I ran that in a loop, where three process will be created with the same file/exe. Would there be any concurrency problem?
Thax in advance
|
|
|
|
|
Do you mean you are running the same EXE three times concurrently? Probably not, but some EXEs don't like being run at the same time as another instance of them. It depends on the EXE.
|
|
|
|
|
thax colin....I am running an powerpoint ppt,..So is there any problem.
Actually, my current situation is somethng like this:: i have a server, where my ppt(for quize) is stored. Now from each client connected to it, I am running the same ppt( in fact am planning to make it as pps format).
Now what I felt is, because every process has its own stack and all, it wont have any problem . But still I want to conform it.. Could u pls lel me know about the same...
Thanks in advance
Himangshu
|
|
|
|
|
PowerPoints should have no problem with running on multiple computers at once (in fact, my college computer science course is doing it right now). However PowerPoint may set the file as read-only beyond the first person open the file. That way any editing is done by one person.
Regards,
Thomas Stockwell
Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning.
Visit my Blog
|
|
|
|
|
Hi all...
I want to change system volume through my application.
Suggest me how can I do this.
Thanks.
Gagan
|
|
|
|
|
What do you mean by "system Volume
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
system volume means I want to control master volume of system through my program.
|
|
|
|
|
Import "winmm.dll". You will find suitable methods to do so.
The word "politics" describes the process so well: "Poli" in Latin meaning "many" and "tics" meaning "bloodsucking creatures."
|
|
|
|
|
Hi Experts,
I am making an vb.net application in vs2005. I run a ppt( quize ) (which is a VBA application again,) from a button click using process.
Now my problem is to link/share the vb.net variable with the variable which i am using in VBA coding(ie total score of quize). so that I can write the score for the particular user who has logged in in my application and has ran the powerpoint(VBA).
[ score is a vriable in VBA, username is the variable present in vb.net application ]
Thanks in advance
Himangshu
|
|
|
|
|
Member 4250705 wrote: Now my problem is to link/share the vb.net variable with the variable which i am using in VBA coding(ie total score of quize).
You can't share variables between two entirely different processes. Your VBA code would have to put this value in a hidden textbox on a PowerPoint slide, then your VB.NET code would have to run PowerPoint as a COM server, show the slide show, let the VBA code run, then pick out that value from the slide using PowerPoint's object model.
No, I don't have any example code. I don't normally do any Office Interop.
Oh, and noone cares how urgent it is. It's not going to get you an answer any faster. After all, you're not paying for this support, are you?? We all donate our time here to answer questions, and we do it when we can, not when you insist on it. We don't get paid to do this...
|
|
|
|
|
thanks for ur reply...And really sorry for the word urgent...sorry for that, actually my deadline was approaching so....anyway thax a lot. I will try the same...
Regards
Himangshu
|
|
|
|
|
Hi all out there!
I got a function (in a C++ dll) that i want to call from VB.NET 2005 (Express). But every time i try this i receive an error "R6034". What can i do against this?
It would be very great, if someone gets me a hint!
Thanky you in advance!
|
|
|
|
|
The answer to this, and all of life's problems are here.[^]
|
|
|
|
|
from http://msdn.microsoft.com/en-us/library/ms235560(VS.80).aspx[^] :-
"Visual C++ Concepts: Building a C/C++ Program
C Run-Time Error R6034
Error Message
An application has made an attempt to load the C runtime library without using a manifest. This is an unsupported way to load Visual C++ DLLs. You need to modify your application to build with a manifest. For more information, see the "Visual C++ Libraries as Shared Side-by-Side Assemblies" topic in the product documentation.
Applications must use a manifest to load the C runtime library. For more information, see Visual C++ Libraries as Shared Side-by-Side Assemblies and Manifest Generation in Visual Studio.
In release builds, the diagnostic message reads: "An application has made an attempt to load the C runtime library incorrectly. Please contact the application's support team for more information."
To correct this error
*
Rebuild your application with a manifest. Building an application with Visual Studio automatically puts the manifest into the resulting EXE or DLL file. If you are building at the command line, use the mt.exe tool to add the manifest as a resource. Use resource ID 1 if building an EXE, 2 if building a DLL. For more information, see How to: Embed a Manifest Inside a C/C++ Application."
|
|
|
|
|
I need to get the account number located in cell f10, g10, and h10 of a number of excel files.
I also need to get the total $ amount located in cell H42 of a number of excel files.
I have set up the program to browse for the excel files I want the information from.
But I'm not sure how to get the data I need from them and put into another excel file.
Here is the code I have so far:
Imports System.IO
Public Class Form1
Dim TheFile As Microsoft.Office.Interop.Excel.Workbook
Dim SaveFile As StreamWriter
Dim Files() As String
' Dim filebrowser As New FolderBrowserDialog
Dim intAccountNumber As Integer
Dim decTotal As Decimal
Private Sub btnexit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnexit.Click
'Closes the application
Me.Close()
End Sub
Private Sub btnshowthefile_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnshowthefile.Click
'Shows the spreadsheet
TheFile = GetObject("G:\data\dr.xls")
TheFile.Application.Visible = True
TheFile.Windows(1).Visible = True
TheFile.Application.WindowState = Microsoft.Office.Interop.Excel.XlWindowState.xlMaximized
End Sub
Private Sub btnbrowse_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnbrowse.Click
FolderBrowserDialog1.Description = "Select location of file"
FolderBrowserDialog1.ShowNewFolderButton = False
FolderBrowserDialog1.RootFolder = Environment.SpecialFolder.MyComputer
'FolderBrowserDialog1.Filter = "Excel files (*.xls)|*.xls"
FolderBrowserDialog1.ShowDialog()
Dim fpath As String = FolderBrowserDialog1.SelectedPath()
Dim tfiles() As String
Dim files() As String
Dim count As Integer
tfiles = Directory.GetFiles(fpath)
files = tfiles
For count = 0 To files.Length() - 1
ListBox1.Items.Add(files(count))
Next
SaveFile = File.CreateText("G:\data\dr.xls")
End Sub
Function findAccountNumber()
'To find the account number
Try
If TheFile.Worksheets("sheet1").cells("9", "f").value = ("State") Then
intAccountNumber = TheFile.Worksheets("sheet1").cells("10", "f").value
Else
intAccountNumber = TheFile.Worksheets("sheet1").cells("10", "g").value
End If
Catch ex As Exception
intAccountNumber = 0
End Try
Return intAccountNumber
End Function
Function findthetotal()
Dim intTotalSearch As Integer = 0
'find the total
Try
For intTotalSearch = 0 To 90
If TheFile.Worksheets("sheet1").cells(intTotalSearch, "g").value = ("Total") Then
decTotal = TheFile.Worksheets("sheet1").cells(intTotalSearch, "h").value
Else
MessageBox.Show("Wrong")
End If
Next intTotalSearch
Catch ex As Exception
decTotal = 0
End Try
Return decTotal
End Function
Private Sub btnaccountinformation_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnaccountinformation.Click
Try
For Each item As String In Files
findAccountNumber()
findthetotal()
'ListBox2.Items.Add("Account # " & intAccountNumber & " Total " & decTotal)
ListBox2.Items.Add("Account # " & findAccountNumber() & " Total " & findthetotal())
'To append
TheFile.AppendFile(intAccountNumber & vbTab & decTotal & vbCrLf)
Next
Catch ex As Exception
End Try
End Sub
Thanks for any help...
|
|
|
|
|
What happens when you run the code?
|
|
|
|
|
Well the browse feature works great...
There isn't any errors but it doesn't give me the values I want for the function findaccountnumber and function findthetotal...
But also don't know if I'm searching the files I browsed for to find the information...
|
|
|
|
|
Is is possible to create an exe which doesn't need to be installed to run from a windows.form?
I have a history viewer that I want to just run on the fly when the exe is clicked rather than ask the user if they want to install the application
Cheers
|
|
|
|