|
Considering you're not telling us what the error is, nor what the definition of List_ or ChangesSet , it'll be pretty much impossible to tell you what you did wrong.
|
|
|
|
|
Figured it out, there was no error i forgot an exit sub before my error handler so it always got executed...
little annoying not gonna lie.
|
|
|
|
|
EliottA wrote: ittle annoying not gonna lie.
People who delete their posts, are a little annoying.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
I figured since the post contained no value whatsoever, had no problem and most probably could not help any others (without an extremely specific search), there wouldn't be a point in leaving it. I did however, leave a summary of the problem and the obvious oversight solution to it.
|
|
|
|
|
Hopefully someone can help clarify what I am doing wrong here. My dev box and clients are running .Net 2.0 Sp 1 installed. I have a .Net .dll (register for COM interop is enabled) which is being used from VB6 (AKA .NETDLL from this point on). Everything works fine on my dev box. The .Net .dll and .tlb are generated properly when I compile and run as expected on the dev box from VB6.
I copy all files to a test client box. I register the .Net dll using "regasm ".NETDLL FILE PATH" (command window states "Types registered successfully" with no errors).
The code which uses the .NETDLL object blows up with error: "The system cannot find the file specified." If I open VB6 on a client box, the .NETDLL is not displayed in the .dll list. I can select browse and manually select the .tlb file and press oK. The reference is added and retained. I can create an instance of the object without any errors, but as soon as I attempt to use the variable, code blows up.
'OK
dim o as new FTP.Client
'Blows up w/ "The system cannot find the file specified."
o.Server = "regasmsucks@ms.com"
Now, if I register the .NETDLL using "regasm ".NETDLL file path" /tlb:".NETDLL tlb path" - everything is fine. Also if I unregister with "regasm ".NETDLL file path" /tlb:".NETDLL tlb path" /u - also works fine. NOTE: unregistering leaving out the .tlb section displays "types unregistered successfully", but nothing is removed (verified using VB6 and looking at references that can be added in).
Any ideas on what I am doing wrong? Do I have to re-create the .tlb file on the client when I already have one for the .dll to register correctly and do I have to include the .tlb in registering/unregistering successfully?
Not a big deal, just thought I'd ask. I don't remember having this problem in the past with previous interop projects.
Any suggestions, ideas, or 'constructive criticism' are always welcome.
"There's no such thing as a stupid question, only stupid people." - Mr. Garrison
|
|
|
|
|
To my Knowledge .NET DLL's are not supposed to be Registerd and i have never registered any .NET DLL. as long you have the Correct framework installed they will work. i see you are still using vb6 DLL's am not sure if thats the Problem. I can mybe ask you one Question
What version of VS did you create the DLLs ?
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
|
|
|
|
|
MSDN direct quote: The Assembly Registration tool reads the metadata within an assembly and adds the necessary entries to the registry, which allows COM clients to create .NET Framework classes transparently. Once a class is registered, any COM client can use it as though the class were a COM class. The class is registered only once, when the assembly is installed. Instances of classes within the assembly cannot be created from COM until they are actually registered.
In VS .Net you can reference and use COM objects through interop (which generate the interop.name.xxx files); likewise you can use .Net assemblies through VB6, after it has been registered with Regasm (which uses the .tlb for linking info).
Any suggestions, ideas, or 'constructive criticism' are always welcome.
"There's no such thing as a stupid question, only stupid people." - Mr. Garrison
|
|
|
|
|
Hi,
I am trying to use thread and it works fine. but my application events are working slowly.
Please help.
There is a timer in which i am calling thread which executes Checkforgrid Procedure which have a
lot of conditions and sending mails programming.
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles timer1.Tick
Dim Counter As Thread = New Thread(AddressOf CheckforGrid)
Counter.Start()
End Sub
Thanks & Regard
Anubhava Dimri
mailto: anubhava.prodata@gmail.com
|
|
|
|
|
Not enough information. This is the code that launches a new thread, but you don't say anything about the Timer interval, nor the code that this thread executes.
Also, launching a thread is an expensive operation. I don't know what kind of performance you're looking for, nor do you say anything about these conditions, or what events are working "slowly".
|
|
|
|
|
Hi Friends,
Actually I have two Pcs On a Lan(Pc1,Pc2).DotNet is installed on pc1 and oracle is installed on pc2...Now Using explorer(isqlplus) i can Access oracle installed on pc2 using(http://pc2/isqlplus).Now my question is how to use oracle in Vb.net on Pc1.If I am using ADO.Net then Connection string is simple
"Provider=OraOLEDB.Oracle; Data Source=oracle; User Id=hr; Password=hr;PLSQLRSet=1;"
But actually oracle is installed on Pc2 so please tell my how can I do this show me some example
|
|
|
|
|
I suggest that you use OracleConnection[^] if possible. If you want a little bit better support against Oracle you can also use ODP.NET provided by Oracle.
Set Data Source in connection string to the name you have defined in TNSNAMES.ORA at client side or use network address.
After that you should be able to connect to the databse.
|
|
|
|
|
Hi all,
I'm recently new to .NET, but have background in VB6 and also web technologies for some years already.
Currently I'm developing an application in VB.NET from which I would like to implement a plug-in architecture.
This would allow to add extra functionality to the application without the need to compile it over and over, and also the chance for 3rd parties to develop their own plug ins.
The idea:
In a very simplistic idea, what I have in mind is something like,the main application (let's say main.exe) and a folder with the plug-ins (in this case dlls, that are basically compiled classes).
main.exe (Main modules, classes, etc)
plugins\myplugin_hello.dll
plugins\myplugin_import.dll
(..etc)
Did some 'web' research and apparently this can be achieved with the Reflection method.
After checking some examples, the way I found to be the most simple to implement it was the following.
No need to add here, for now, the code to parse the plugin folders, just will use one as example.
The code:
(main.exe)
'Read dll
assembly = System.Reflection.Assembly.LoadFrom("myplugin_hello.dll")
For Each fileType As Type In assembly.GetTypes
If fileType.Name = "xPlugin" Then
'Create new instance of class
Dim plugin = Activator.CreateInstance(fileType)
End If
Next
(myplugin_hello.dll)
Public Class xPlugin
Public Sub New()
MsgBox("I am a plug-in !")
End Sub
End Class
Apparently this is what I want, after compiling the xPlugin class (myplugin_hello.dll) and running the main.exe code, a message box with "I am a plug-in!" will be displayed.
The problem:
Well, now the problem is that I need to have some 'interaction' with both pieces of code, the main.exe and the myplugin_hello.dll, without that it is almost useless to have a plug-in : /
How could I, for example, access to main.exe classes and modules from xPlugin class (myplugin_hello.dll) ?
Best regards,
Luís
|
|
|
|
|
There's plenty of plugin articles here on CP.
Basically, you have to establish some sort of the common interface between the main code and the plugin. Usually, you'd base this in, of all things, an Interface, that each plugin would have to implement. This establishes what methods and properties the main code is going to expect each plugin to respond to. The same is true in the opposite direction.
|
|
|
|
|
Dear Friends
how can i iterate through a subset of a datatable in vb.net. Following code is an eg which does not seems to work.
Dim MonthlyDT As DataTable
MonthlyDT = NewMonthlyReportData.MonthlyReportDataTable 'Class Object
Dim MyDataRow As DataRow
'Parent DataTable with Filtering
MonthlyDT.DefaultView.RowFilter = "[MYID]<=716100"
'Set the Clone to be of Parent table
Dim MonthlyDTClone As DataTable = MonthlyDT.Clone()
For Each MyDataRow In MonthlyDTClone.Rows
Select Case MyDataRow("Classification").ToString
Case "Classification1"
Classification1 += 1
Case "Classification2"
Classification2 += 1
Case "Classification3"
Classification3 += 1
End Select
Next
Your help.
|
|
|
|
|
What does 'does not work' mean ? Do you get Id's above 716100 ? Why is the id in [] ? That is not required.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
Sorry for the trouble guys, I have sorted the Filtering problem as follow, but now have the issue of filtering the correct subset based on the month and year value of MemDateAdded (datetime field). Following code does not filter the data instead returns the entire records in the datatable. But if I use any other filtering instead of Date, it works perfectly eg. (STATE='VIC').
MyTableDataRows = MonthlyDT.Select(("Month(MemDateAdded)" = 12 & " AND Year(MemDateAdded)" = 2008)) 'Monthly Total Only
For Each dr As DataRow In MyTableDataRows
Select Case dr("Classification").ToString
Case "Classification1"
Classification1 += 1
Case "Classification2"
Classification2 += 1
Case "Classification3"
Classification3 += 1
End Select
Next
I want to iterate the subset of datatable based on user selected month and year passing to MemDateAdded. User month and year will come from a DateTime Picker control. Basically I want to sum different Classifications and passed them to the variables, which I want to use later on other applications like Excel for poking.
Your URGENT help on this....
|
|
|
|
|
Galle Guy wrote: ("Month(MemDateAdded)" = 12 & " AND Year(MemDateAdded)" = 2008)
what is this??
When not sorting Select() expects a single string, and your selection doesn't use variables, hence put double quotes at both ends, not inside the string and forget about ampersands.
|
|
|
|
|
what are you trying to do?
well, its early in the morning, but some notices to your code:
MonthlyDT.DefaultView.RowFilter = "[MYID]<=716100"
this line is useless in your context. you are filtering the view but later on,
you iterate the underlying datatable
Dim MonthlyDTClone As DataTable = MonthlyDT.Clone()
also useless. you clone the original datatable and iterate it. the method clone()
clones the schema and constraints NO data. use copy if you would like a "copy".
i just can think of what you will do:
Dim dtMonthly As DataTable = NewMonthlyReportData.MonthlyReportDataTable
Dim dvMonthly As DataView = dtMonthly.DataView
'filter wanted data
dvMonthly.RowFilter = "[MYID]<=716100"
'iterate the resulting data
For Each drvMonthly As DataRowView In dvMonthly
Select Case drvMonthly ("Classification").ToString
Case "Classification1"
Classification1 += 1
Case "Classification2"
Classification2 += 1
Case "Classification3"
Classification3 += 1
End Select
Next
|
|
|
|
|
Filtering the data should also eliminate the need for a copy unless you have a specific need for that.
Any suggestions, ideas, or 'constructive criticism' are always welcome.
"There's no such thing as a stupid question, only stupid people." - Mr. Garrison
|
|
|
|
|
How to Change Drive later of disk?? It Possible Please Help me??
For Example I want to Change the drive name D to
Piyush Vardhan Singh
p_vardhan14@rediffmail.com
http://holyschoolofvaranasi.blogspot.com
http://holytravelsofvaranasi.blogspot.com
|
|
|
|
|
Were you asking in the wrong forum before, or are you still hoping to do this in ASP.NET ?
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
No, he's just hoping that someone will tell him it is possible, he doesn't want to accept the truth
Bob
Ashfield Consultants Ltd
|
|
|
|
|
Well, it sure seems likely.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
Let's just say that if you changed the drive letter of the System or Boot partitions, either Windows, or any installed apps would no longer work.
Check out the code in this[^] article. Have fun crashing your system!
|
|
|
|
|
Hello all
Does anybody know how to access the "Save As Text" in FF programmatically?
Thank you in advance
Chandra
|
|
|
|