|
Member 3487632 wrote: ***But the same code On successful execution of sql statement the dbstatus value is giving 0 on some other enviornment where ODBC version and sql server version is different .
You can either change the specs (requirements to run your software), or the software (have it check the version of the available drivers/software and act accordingly). We mostly choose the first option.
Write down the versions of the ODBC-driver, and update the out-of-date systems to match your test-server.
Bastard Programmer from Hell
if you can't read my code, try converting it here[^]
|
|
|
|
|
Production Environment version :-
OS windows server 2003
sql server 2000
ODBC 3.526.3959.0
My Testing Environment version :-
OS Windows 7
sql server 2005
ODBC 6.1.7600.16385
What shall i change from above to execute the code . Software i can't change i have no authority to do that.Please help me out
|
|
|
|
|
And which of those two returns the correct results?
That's the one with the correct ODBC-version. I suggest you stick to that particular version, and not start supporting "random combinations of versions".
Bastard Programmer from Hell
if you can't read my code, try converting it here[^]
|
|
|
|
|
Production Environment version :-
OS windows server 2003
sql server 2000
ODBC 3.526.3959.0
My Testing Environment version :-
OS Windows 7
sql server 2005
ODBC 6.1.7600.16385
First one returns the 0
Second one return -1
|
|
|
|
|
..and which of those two is correct? The first one with the 0, or the test-environment with the 1?
Write down the version of the ODBC-driver, and make sure the other machine uses the same version.
The reason we "have" versions is because things tend to change. That means that those two ODBC-versions that you are working with work different, with different assumptions. The older one might have bugs that are solved in the new version. The framework might expect the old bug, and not be able to cope with the new version. There's all kinds of stuff that can go wrong, and unless you know WHAT has been changed in the ODBC-driver, you simply use the LATEST version that you tested against.
Bastard Programmer from Hell
if you can't read my code, try converting it here[^]
|
|
|
|
|
Hi
I am new to VB .Net and is currently using VB2008. I have created a MDI Parent form and and MDI Child Form
On clicking a Menu item in MDI Parent I am trying to Enable/Disable a Text Box in Child. But this is not working. Can somebody tell me how to do this?
In the Menu Iem Click Event I am putting the code as Parent.child.txtbox.enabled = True. But when I run the program the text box is not getting enabled.
Note: The child form is loaded along with the Parent form. It is not called from any menu Item.
|
|
|
|
|
I highly suggest picking up a beginners book on VB.NET and working through it.
Right now, you're just guessing at what may work and that's not a good idea when dealing with the basics of a language and framework.
Your should be declaring an Interface that your MdiChild form implements, exposing a method that the MdiParent form will use to tell the child to enable/disable the textbox.
Public Interface ISampleInterface
Sub EnableTextBox(enable As Boolean)
End Interface
Public Class MyMdiChildForm
Implements ISampleInterface
...
Public Sub EnableTextBox(enable As Boolean) Implements ISampleInterface.EnableTextBox
MyTextBox.Enabled = enable
End Sub
End Class
MdiParent code:
Dim newChild As New MyMdiChildForm
newChild.Parent = Me
newChild.Show
.
.
.
newChild.EnableTextBox = True
If you can't understand this code or have questions on it, you REALLY need to go through a beginner book.
|
|
|
|
|
Thanks a lot Dave. I will go through the Beginner's book. But I do have invented a crude method to take care of the same for the time being. 
|
|
|
|
|
Don't get into the habit of doing things the wrong way. You're just going to paint yourself into a corner later.
|
|
|
|
|
Hi Dave
Thanks for the advice.
I doubt this will happen since what I am doing is closing the earlier opened form and re-opening the child again. A few micro-seconds extra, maybe, but hardly noticeable I am sure. This does the work very simply.
In case you can think of any problems which it may raise in future I will surely like to know.
Thanks again
Sandipan
|
|
|
|
|
SandipanSengupta wrote: I doubt this will happen
I wasn't talking about your current application. I was talking about the bad habits you develop that are hard to break and prevent you from solving problems correctly in the future.
SandipanSengupta wrote: In case you can think of any problems which it may raise in future I will surely
like to know
Far more than can be described in forum posts...
|
|
|
|
|
I'm developing a VB Window's Forms application in Visual Studio 2010. I choose an object out of the forms toolbox, say a chart. Then I adjust the properties in the properties window to get what I want. Is there any way I can see the actual code that generates those properties?
|
|
|
|
|
You could open the containing folder for your project and then find the <formname>.Designer.vb file and open that file as a text file. I do not think that it shows up in your solution explorer by default.
Why is common sense not common?
Never argue with an idiot. They will drag you down to their level where they are an expert.
Sometimes it takes a lot of work to be lazy
Please stand in front of my pistol, smile and wait for the flash - JSOP 2012
|
|
|
|
|
|
You're welcome.
Why is common sense not common?
Never argue with an idiot. They will drag you down to their level where they are an expert.
Sometimes it takes a lot of work to be lazy
Please stand in front of my pistol, smile and wait for the flash - JSOP 2012
|
|
|
|
|
Visual Studio offers a "show all" button in the solution pane.
|
|
|
|
|
Merci
Why is common sense not common?
Never argue with an idiot. They will drag you down to their level where they are an expert.
Sometimes it takes a lot of work to be lazy
Please stand in front of my pistol, smile and wait for the flash - JSOP 2012
|
|
|
|
|
recently I converted a database migration utility from VB(VS6 sp6) to VB.NET(VS 2008 SP1). It is ported succesfully. I am able to open it development M/C. But if I am trying to open the same application in installer M/C.(Fresh machine) my application is crashing.
can anyone let me know what run time dll should be included so that it will work fine.
System Details
1: XP SP3
asdasdadadasd
|
|
|
|
|
ash mishra wrote: can anyone let me know what run time dll should be included so that it will work fine.
The .NET Framework should be included; the same version that you used to develop against. You can't install just "a few dll's", as most of them have quite some dependencies.
Does your installer have an option to see if there's a .NET framework?
Bastard Programmer from Hell
if you can't read my code, try converting it here[^]
|
|
|
|
|
1) Open VS 2008 and load the project.
2) Right click the project name in solution explorer and select properties.
3) Select the Compile tab and click the Advanced Compiler Settings
4) Check the target Framework version
5) Install that Framework version on target machine
6) Build project and copy EXE file to target machine
|
|
|
|
|
vb6 sp6 working in virtual XP machine under win 7
This setup has been working fine and the projects have existed for years but a couple of them have started failing to compile
They all compile and run ok with Control F5 (Run with full compile) but when you use the File->Make xxxxx.exe option it works for a while and the progress line of "Writing EXE" partially colours blue and it then stops with
Microsoft Visual Basic, "Unexpected Error" Ok Help
Help tells me I may have a hardware or software error. gee you think
At least one of the failing projects hasn't been modified (using sourcesafe so I can be sure of this) since it last compiled ok
Other projects compile ok
Does anyone have any ideas where to look for more info?
EDIT: Things I have checked
There is plenty of free disk
running the compiler from the command line gives the same result
a repair install doesn't change anything
repeat install of sp6 didn't help
modified 18-Jul-12 7:54am.
|
|
|
|
|
Mike Deeks wrote: Does anyone have any ideas where to look for more info?
In 2008, as that's when extended support for VB6 ended
FWIW;
- Make sure you registered all the controls that you're using
- Compile under Windows XP, or download XP-mode for Windows 7
- Keep removing code (comment it out) until you got something that compiles again
- Start migrating to VB.NET; the compiler is free, and you can mix VB6 and .NET code, using the Interop ToolBox from Microsoft.
- Check if the VB6 IDE created a logfile under C:\Windows\System32, and check the EventLog for clues.
Bastard Programmer from Hell
if you can't read my code, try converting it here[^]
|
|
|
|
|
Eddy Vluggen wrote: In 2008, as that's when extended support for VB6 ended
2008 is quite recent really
Thanks for the suggestions
it is possible that upgrading office broke it but that had to be done as office was broken, I will have a look when I did that and perhaps try another virtual machine
I am running under XP, in a virtual though
the code hasn't changed on at least one of the projects that is now failing to compile
I will investigate interop
no IDE log file unfortunately
|
|
|
|
|
Mike Deeks wrote: 2008 is quite recent really
Read that again; extended support ended four years ago.
Imagine your virusscanner being outdated four years.
Mike Deeks wrote: it is possible that upgrading office broke it but that had to be done as office was broken
..and now you have to re-create a working compiler-environment. And those Office-dependencies are usually tied to a specific version.
I suggest you create a minimal build environment in a VM, and keep it clean. That probably involves in listing all your external references and verifying their existence and that those are the correct versions.
Bastard Programmer from Hell
if you can't read my code, try converting it here[^]
|
|
|
|
|
Eddy Vluggen wrote: Read that again; extended support ended four years ago.
Imagine your virusscanner being outdated four years.
Your right of course and my comment was not intended to be serious but...
Why should it worry me if the extended support that I never used anyway has expired. As long as the program is a valid method of producing binaries (maybe I should keep quiet about that is it isn't at the moment ) then I see no reason why I shouldn't use it
I like the language and, as the largest project is up to 140,000 lines of code, moving to another development environment is not at all easy but as the whole things changes every few years anyway it is hard to see the point. It would be interesting to know the overall number of developers currently using vb6, vb2005, vb2008, vb2010
I am not a luddite and keep up to date with technology but my grandads King Dick socket set still seems to work as well for me as it did for him when he bought it quite a few years ago
Thank you for your helpful advice
|
|
|
|