|
Dave Kreskowiak wrote: John Simmons / outlaw programmer wrote:
Unbelievable #2
This one is also associated with the shortcut. The documentation says I have to pass a parameter to VB6 so that VB6 can pass it to the application being "compiled". Is that really true? Is there no project setting for this?
----
Uhhh, another steaming pile. Nothing is passed to the project being compiled, other than the usual compiletime constants, which you can specify in the project properties.
I think I didn't explain this one well enough - the app that uses the DLL we're working on accepts a command line parameter. They imply that in order to pass this parameter to the application from within VB, we have to first pass it as a command line parameter to VB. Since I have no experience with VB (at all), I'm not familiar with the compiler's requirements in this area.
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
John Simmons / outlaw programmer wrote: I think I didn't explain this one well enough - the app that uses the DLL we're working on accepts a command line parameter. They imply that in order to pass this parameter to the application from within VB, we have to first pass it as a command line parameter to VB.
Never heard of it. There's nothing on the VB6 command line that you couldn't do in the Project properties, other than changing the dev environment from SDI to MDI.
|
|
|
|
|
Hi All,
Thank you for your help in advance !! Here is my situation
a. I have a ASP.NET application running on Machine1(lets say this is the presentation layer and we need to keep it as light weight as possible and so there is no db work being done here. I dont even want to store the db logon credentials on this Machine as it will be exposed to www)
b. I have an application server Machine2 lets say(This needs to have a windows service with remotable objects, so that Machine 1 can tap into these, and have machine 2 do the business logic operations with the database and return data back to client app on Machine 1 and i display them there and have a clean separation...and have a three tier architecture)
c. My problem is this. I created a VB.net class library and the corresponding Windows service on Machine2. Since i did not want to hard code the db logon credentials, I put them in a config file of the service under <appsettings>. The service is running on Machine2. I made a reference from machine1 (my client app) to the remote class library dll on machine2(across the network...iam using the tcp://machine2:49134/remoteobject etc...for the remoting). When i run this. I get an error and it is not able to read the class library methods itself, forget the config file. So I copy the dll to a local location on Machine1 and reference from there. This time it does work, but it is trying to read from the config file(the machine.config file on Machine1) and not from Machine2. What am i doing wrong???? I tried putting the db parameters on machine.config of Machine2...no help. If i remove the appsettings for dbconnection from machine1 it does not work !!
d. above is one problem. The other problem is when i reference the class dll locally, even if i put the activator.getobject parameter for URL as CNN.com or anything else, i do not get a remote machine refused message, things continue to work. Why?
Please help !!! Sample code is much much appreciated
Thanks
RH
|
|
|
|
|
Ridge Howison wrote: I made a reference from machine1 (my client app) to the remote class library dll on machine2(across the network...iam using the tcp://machine2:49134/remoteobject etc...for the remoting). When i run this. I get an error and it is not able to read the class library methods itself, forget the config file
If you're using remoting, why do you want to read the config file from M1, you could make the Service in M2 return it as a string to M1.
What you need is a a way through which the ASP.NET app in M1 have a 2 way conversation with the Windows Service in M2. This, I believe, You've already done using remoting.
Ridge Howison wrote: I dont even want to store the db logon credentials on this Machine as it will be exposed to www
That's a good measure, but not very beautiful. You also have the choice of encrypting your connection strings in your web.config. Plus, you have a variety of algorithms you can use. That should be safe enough.
SG
|
|
|
|
|
Hello,
[VS 2005]
I have a windows service and a windows application. The windows service is used to send e-mails. This part is ok.
However, I need the windows application to send the e-mail details to the windows service. What is the best way to do this?
Many thanks for your ideas,
Steve
|
|
|
|
|
The server has to expose some kind of server, be it Remotable components, or a TCP/IP daemon, or Message Queing, or possibly even looking in a folder for configuration information in files.
The files solution would be the easiest, employing a FileSystemWatcher component.
|
|
|
|
|
Hello Dave,
Thanks for the reply.
I looked at the fileSystemWatcher component.
I was thinking of using a xml file.
I am not sure if the above is the correct solution. The service will be used to send many emails for a user specified period. The emails are reminder emails that will be send to many people.
The user will use the window application to click send, and select the duration of time between reminders for this customer (every 1, 10, 20 minutes)
Sending the e-mail is not a problem, it is control the communication between the windows application and the remote windows service.
Thanks for any more suggestions,
Steve
|
|
|
|
|
I already gave you a bunch. If it's a remote server that's sending out the emails, you may even consider moving the service code to a Web Service, which is probably going to be the best bet.
|
|
|
|
|
Hello all,
I am working on an application that facilitates script/request movement between developers and DBAs (who must approve said items).
Basically, as a developer, we choose the source server/database from a bound combobox. The DBA then sees our choices and completes whatever the task may be. The problem is that as a developer, if I want the source server/database to be those that show up by default in my bound combobox, when the DBA sees this (their server/database list differs) they will see the default server/database from their list.
i.e. My list of databases: cowboy, drones
DBA list of databases: alldepts, boondocks, cowboy, drones
If I sent in a request for the cowboy database (I didn't touch the combo box), it will show up to our DBAs as the "alldepts" database, since that is their default choice.
I have tried to set the text in the combobox before allowing a save, then checking for the value of "---" (for example), but this will not register, and doing a quick test, the "cowboy" database is the actual combobox.selectedItem. I also tried to add a new item to the bound combobox, but this isn't working for obvious reasons. Basically, I want to FORCE the developer to choose a database from a bound combobox.
Has anyone run into this issue before?
Thanks for all the help in advance!
-Joe
-- modified at 12:27 Wednesday 6th June, 2007
|
|
|
|
|
JoeFid wrote: Has anyone run into this issue before?
It would appear that you using the index numbers of selected items instead of the selected items themselves.
|
|
|
|
|
I'm having problems because the use of Format function gives different results in VB6 and in VB.NET.
That line: format("80", "000")
results "80" in VB6, and "000" in VB.NET.
How can I solve that?
Regards,
Diego F.
|
|
|
|
|
I could solve that by adding String before format function. So:
Format("80", "000") returns "000"
String.Format("80", "000") returns "80"
Regards,
Diego F.
|
|
|
|
|
Diego F. wrote: String.Format("80", "000") returns "80"
That's because you are specifying a format string without any formatting what so ever. String.Format("80", "fubar") also returns "80".
What you want is:
80.ToString("000")
or
String.Format("{0:000}", 80)
---
single minded; short sighted; long gone;
|
|
|
|
|
It doesn't work because the "000" format specifier is for numeric values only. You passed in a string of characters ("80"). It will work if you do
Dim str As String = Format(80, "000")
returns "080".
|
|
|
|
|
Hello,
I made an application that automates SolidWorks 2006. I added references in my project to 2 type libraries from the SolidWorks 2006 folder.
The problem is the application only with 2006 version of SolidWorks; it does not work in 2004 or 2007. Is there a way to make the application independent of type library version?
I already tried late binding by removing the references to SolidWorks and using Objects type variables, but this gives me a run time error when trying to open a document:
Bad variable type. (Exception from HRESULT: 0x80020008 (DISP_E_BADVARTYPE))
-- modified at 14:07 Wednesday 6th June, 2007
|
|
|
|
|
There's no way to do version indendance if you use a reference to a COM object. The version number is part of the binding.
You might be able to do this with some type of proxy, or wrapper class, though. See this[^] for a description.
|
|
|
|
|
Hi All,
I created a new project and from the get go the default telli sense was turned off and it wouldn't show all project and other issues occured. I eventually got most of them down and I added a forgot username a password form to my project, however after developing the design of it when i go to double click on one of the command buttons on the page for example btnSumbit it won't open the code behind page.
When I did set this up i called the page ucForgot.aspx and the code behind file is called ucForgot.aspx.vb but the code with in it is follows
Partial Class includes_uc_security_ucForgot
Inherits System.Web.UI.UserControl
I did change the class name but that should cause the problem write?
Any ideas?
|
|
|
|
|
This question belongs in the ASP.NET Forum.
But, if you changed the class name in this file, then yes, you've caused a problem. A Partial class is a class that spans multiple files. If you change the name specified in the Partial Class line in one file, you MUST change it in the others that make up the rest of the class. Also, ANY references to this class name in ANY other files must also be changed to use the new name. A search and replace would probably be in order here.
|
|
|
|
|
Sorry Dave I taught I was in the write section.
I think I have changed all references to it. So here it is as follows:
ucForgot.ascx
<%@ Page AutoEventWireup="false" Codebehind="ucForgot.ascx.vb" Inherits="includes_uc_security_ucForgot" Language="vb" %>
Then in the ucForgot.ascx.vb
Partial Class includes_uc_security_ucForgot
Inherits System.Web.UI.UserControl
This is still not working, and out side of this all pages are blank except for a command button on the ucForgot.ascx page to try and get this working.
Then for some reason there is this other file called ucForgot.ascx.designer.vb that i have never used before or don't know what it is for. But it has the correct name and any time i change the name it changes as well automatically.
|
|
|
|
|
I have no idea. ASP.NET is something I haven't touched in 4 years. I'm going by my experience with Partial classes.
|
|
|
|
|
Hi Dave,
Sorry for the inconvience, I decided to recreate everything and no rename the classes, I will someone else worry about that if they really want it a different name to the design.
Thanks again
|
|
|
|
|
That's the easiest way to do it, I guess!
|
|
|
|
|
hello frnds,
how can i send a message to other computer in a same LAN
using vb.net
can i use IP address ???
the messagebox should be displayed on desired computer..
any code ???? Please help...
thankx in advance and regards,
koolprasad2003
If the answer is useful for U then please Rate This message...
Be a good listener...Because Opprtunity knoughts softly...N-Joy
|
|
|
|
|
If you just want a simple messagebox displayed, you may type the following in command prompt, (or run command prompt with the following as argument
net send IP Message
this will display the Massage in IP computer if this access is not restricted in your domain.
If you want to do that by your own program, you should use client/server applications which should run on both computers.
|
|
|
|
|
Thankx a lot,
but i wamt to do it from my program,
if called "shell" from my program n run it
does server knows that, i send the message to BLABLA computer????
thankx and regards,
koolprasad2003
If the it is useful for U then please Rate This message...
Be a good listener...Because Opprtunity knoughts softly...N-Joy
|
|
|
|