Showing posts with label vb6. Show all posts
Showing posts with label vb6. Show all posts

Monday, March 26, 2012

Read SP source code from VB

Hi,
I'm developing an application to crypt SQL databases and i need to
read SP and Views source code from VB6, if you know how to do this
please answer me.

Greetings."Carpi" <carlos.rodriguez@.sparks-software.com> wrote in message
news:5280f320.0401080621.514fd41f@.posting.google.c om...
> Hi,
> I'm developing an application to crypt SQL databases and i need to
> read SP and Views source code from VB6, if you know how to do this
> please answer me.
> Greetings.

Probably the best place to start is the .Script method of the SQLDMO
objects, which will generate the CREATE statements for all object types.

Simon

Friday, March 9, 2012

RDC Connection string data

I am using RDC for the Crystal Report 8. I use VB6 and connect to a MSSQL 2000 DB. I currently connect to the database by:

CRReport.Database.Tables(1).SetLogOnInfo sCRServer, sCRDatabase, sCRLogin, sCRPassword

and that works fine, but I would like to be able to pass the Workstation ID(WSID) and App name(APP) like can be done in a standard ado connection string.

i.e.
Cn = "uid=sa;pwd=admin;driver={SQL Server};server=NTSERVER5;WSID=" & Trim(sUserName) & "-" & getUserComputerName() & ";APP=" & App.EXEName & "-" & sServerName & ";database=" & sDatabaseName & ";dsn=,,connection=adConnectAsync"

Any ideas on how to pass that information for crystal to use it, when logging in?I also connected to crystal using :
CRReport.Database.LogOnServerEx "pdssql.dll", sCRServer, sCRDatabase, sCRLogin, sCRPassword, "uid=sa;pwd=admin;driver={pdssql.dll};server=" & sCRServer & ";WSID=" & Trim(sUserName) & "-" & getUserComputerName() & ";APP=" & "CR" & App.EXEName & "-" & sServerName & ";database=" & sDatabaseName & ";dsn=,,connection=adConnectAsync"

but MS SQL in the Prodcess Info, when the report runs stilll doesn't show the WSID and APP information on the server. I passed it above, but??

Any ideas.

thanks,

Dean