Showing posts with label local. Show all posts
Showing posts with label local. Show all posts

Friday, March 30, 2012

problem running vb.net application with sqlexpress in system with only .NET FRAMEWORK

Hi,

I have developed a stand alone application that get data from excel and dumps it in local database (sql server database primary data file) in visual studio .net 2005. I had no issues while developing the application. When i am trying to install this application in the standalone system with .net framework 2.0 and no backend database it giving the following error

provider: sql network interfaces, error 26 - Error locating Server/ Instance Specified

connection string i am using is

Dim objLocalDB As System.Data.SqlClient.SqlConnection

objLocalDB = New System.Data.SqlClient.SqlConnection("Data Source=.\SQLEXPRESS;AttachDbFilename=" & System.AppDomain.CurrentDomain.BaseDirectory & "LFDB.mdf;Integrated Security=True;User Instance=True")

I dont want to use any backend database. I only want to use the database that comes with .net (i.e sqlexpress)

Please help me how can i get through this problem.

hi,

Manyam wrote:

When i am trying to install this application in the standalone system with .net framework 2.0 and no backend database it giving the following error

provider: sql network interfaces, error 26 - Error locating Server/ Instance Specified

I can't understand if you installed SQLExpress as well, on the target computer... did you?

regards

|||SQL Server Express is a backend database although the GUI tools are more lightweight than the ones of the more bigger editions. If you want to use user instances as mentioned in the connection string, you will need to have a SQL Server Express Service in place to attach the database to the Service. SQL Server Express can be deployed within your application (even through clickonce deplyoment but at the end need to be installed).

HTH, Jens K. Suessmeyer.

http://www.sqlserver0205.de
|||

Manyam wrote:

I dont want to use any backend database. I only want to use the database that comes with .net (i.e sqlexpress)

Please help me how can i get through this problem.

SQL Express is not part of the .NET Framework, it is a completely separate product that must be installed if you are going to use it. You can add SQL Express as a prerequisite to you application installation automatically using either ClickOnce or standard Setup Projects in VS 2005, in your projects properties, click the Prerequisite button and make sure SQL Express is checked in the list. This will automatically include the SQL Express installer in your deployment and install it on the target computer if it is needed.

Mike

|||

Hi,

Thanks for your suggestion. So we cannot run vb.net application that is developed using sql server management studio without SQL EXPRESS and only .net framework.

I tried to open the link provided by you. Its not opening. I am getting page cannot be displayed.

|||

Hi,

Thanks for your valueable suggestion. So i cannot run a vb application developed using sql server management studio without SQL EXPRESS.I tried installing SQL EXPRESS in standalone system, but its giving issues.

Process followed -->

Uninstalled existing framework.

Installed .NET framework 2.0Dowloaded SQLEXPRESS and istalled in system.

Its throwing a error that .net should require some updates... What updates do we need to install to get this working.

Thanks in advance.

|||What's your OS? If WIndows XP Pro, this needs SP2 and updated security patches

Monday, March 26, 2012

Problem remotely stopping and starting services in SQL Server 2005

Hi guys

I've been dealing with a few problems with SQL Server 2005.

We don't want to give our DBA's local administrator access to the servers so we had a problem with SSIS which I managed to resolve by adding their global group into the local DCOm group and modifying the security properties of MsDtsServer.

Another problem I've come across is when you log into Management Studio as an account that has local administrator access to the server you have the Green symbol next to the registered server, you can then right click and Stop, Restart services etc.

If I log into Management Studio with an account that has full SQL sysadmin rights but not local administrator rights to the server then the Green symbol doesn't appear and the Stop, restart options are all greyed out - all other functionality appears okay, they just seem to lose the ability to remotely stop and start services.

All of the above is with Windows Firewall turned off, if the user has local administrator rights but the SQL Server has the Windows Firewall switched on they are unable to remotely stop and restart services.

Port 1433 is open on the firewall and program execptions are there for sqlbrowse.exe

Anyone come across this particular problem before?

Any help would be appreciated.

Cheers

HanleyI like the easy questions!

The problem is that only members of the Local Administrators group have permission to start and stop services on a Windows machine by default. You'll have to modify the ACLs on the machine to grant the permission needed to start and stop the service(s). There's a great article (http://www.windowsitpro.com/Articles/ArticleID/48881/48881.html?Ad=1) at Windows IT Pro with the step-by-step for doing this.

For what it is worth, I would STRONGLY recommend creating a local (machine) group and granting it the necessary privleges via the ACL, then creating a DBA group in AD and making that domain group a member of the local group. While this seems a bit arcane, it means that when you put a login into the DBA group in AD, they inherit the ability to start and stop the SQL Services.

-PatP|||Using group policy I assigned my user account (SQLTest) Start, Stop and Pause permissions to MSSQLSVC and SQL Server Agent.

When I load management studio using this ID I'm still unable to stop or start the services. If I put the ID into local admin it works okay?

2nd Question - even with my ID in the local administrators group it doesn't work with the firewall turned on, am I missing any exceptions, these are what I have:

Program Exceptions

C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Binn\sqlservr.exe:*:enabled:M S SQLServer

C:\Program Files\Microsoft SQL Server\90\DTS\Binn\MsDtsSrvr.exe:*:enabled:MS DTS

C:\Program Files\Microsoft SQL Server/90\Shares\sqlbrowser.exe:*:enabled : SQL Browser

Port Exceptions

1433:TCP:*:enabled : SQL Server
1434:UDP:*:enabled : SQL Instance
2725:TCP:*:enabled : SQL Analysis Services
135:TCP:*:enabled : SQL Integration Services

As said above, even using an ID with local admin permissions to the server I still cannot remotely stop and start SQL services with the firewall turned on.

Friday, March 23, 2012

Problem Printing local report in Sql reporting services

I have a local report for which i am binding the Dataset dynamically. I am trying to print this report using a seperate button on the page. I saw in the forums saying that the reportviewer can be converted to an EMF file, bind this to an image control and can Print this image using Javascript.

Can anyone help me with the sample code to print local report from the reportviewer (it may be in any approach.)

Thanks in advance.

Sekhar TThis thread should help.

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=790287&SiteID=1&mode=1&PageID=0

or at least get you on the right path.|||

Am sorry, my app is not windows, it is web based

I tried it but didn't help me a lot. My requirement is to allow clients to print reports from their browsers. I am using a single reportviewer control to display reports by dynamically binding different business objects and reports. One important thing to notice is that my connection string changes on user selection.

I am not really sure if there is another way using server mode to do this. I don't want to create reports to each database on the server. I am looking for a solution where i can use the same report for different databases.

|||When you say "One important thing to notice is that my connection string changes on user selection." you mean you're connecting to different reporting servers?

Here's my class. at the moment i'm confused as to why the 2nd device info has a start page of + 1 where the 1st one is set to 0. But it should work for you, assuming you know how to change the properties on each report server, aka changing the reportview.serverreport.reportpath, and the reportview.serverreport.reportserverurl. (these contain the same info as the connection string)

Hope this helps.

using System;
using System.IO;
using System.Data;
using System.Text;
using System.Drawing.Imaging;
using System.Drawing.Printing;
using System.Collections.Generic;
using System.Collections.Specialized;
using Microsoft.Reporting.WebForms;
using Microsoft.Reporting;
using System.Drawing;
public partial class _Default : System.Web.UI.Page
{

protected void Page_Load(object sender, EventArgs e)
{
Demo demo = new Demo();
demo.Run();
}
}

public class Demo : IDisposable
{

private int m_currentPageIndex;
private IList<Stream> m_streams;

private void Export(ServerReport report)
{
string deviceInfo =
"<DeviceInfo>" +
"<OutputFormat>EMF</OutputFormat>" +
" <MarginTop>0.25in</MarginTop>" +
" <MarginLeft>0.25in</MarginLeft>" +
" <MarginRight>0.25in</MarginRight>" +
" <MarginBottom>0.25in</MarginBottom>" +
" <StartPage>0</StartPage>" +
"</DeviceInfo>";

m_streams = new List<Stream>();

string encoding;
string mimeType;
string extension;
Warning[] warnings;
string[] streamIDs = null;
Byte[][] pages = null;

//Create Byte array containing the rendered image. of the 1st page.
Byte[] firstPage = report.Render("Image", deviceInfo, out mimeType, out encoding, out extension, out streamIDs, out warnings);

m_streams.Add(new MemoryStream(firstPage));

// The total number of pages of the report is 1 + the streamIDs
int m_numberOfPages = streamIDs.Length + 1;
pages = new Byte[m_numberOfPages][];

// The first page was already rendered
pages[0] = firstPage;

for (int pageIndex = 1; pageIndex < m_numberOfPages; pageIndex++)
{
// Build device info based on start page
deviceInfo = String.Format(
"<DeviceInfo>" +
"<OutputFormat>EMF</OutputFormat>" +
" <MarginTop>0.25in</MarginTop>" +
" <MarginLeft>0.25in</MarginLeft>" +
" <MarginRight>0.25in</MarginRight>" +
" <MarginBottom>0.25in</MarginBottom>" +
" <StartPage>{0}</StartPage>" +
"</DeviceInfo>", pageIndex+1);

//Render the page to a byte array.
pages[pageIndex] = report.Render("Image", deviceInfo, out mimeType, out encoding, out extension, out streamIDs, out warnings);

//create a stream of the page's byte array
m_streams.Add(new MemoryStream(pages[pageIndex]));

//set the position of the stream to 0 to make sure when the stream is read
//it starts from the beginning.
m_streams[m_streams.Count-1].Position = 0;
}

m_currentPageIndex = 0;
}

private void PrintPage(object sender, PrintPageEventArgs ev)
{
//create a new metafile based on the page that we're trying to print.
Metafile pageImage = new Metafile(m_streams[m_currentPageIndex]);

//draw the an image deciding what to draw, and where to place it on the page.
ev.Graphics.DrawImage(pageImage, 0, 0);
//increment to the next page.
m_currentPageIndex++;

//decide if we've read our last stream.
ev.HasMorePages = (m_currentPageIndex < m_streams.Count);
}

private void Print()
{
//the name of the printer.
const string printerName = "Microsoft Office Document Image Writer";//;"\\\\NPSERVER\\MAIN"

//if there's nothing to print return
if (m_streams == null || m_streams.Count == 0)
return;

//create the printdocument object
PrintDocument printDoc = new PrintDocument();

//set the printername, deal w/ the printer being invalid
printDoc.PrinterSettings.PrinterName = printerName;
if (!printDoc.PrinterSettings.IsValid)
{
string msg = String.Format("Can't find printer \"{0}\".", printerName);
System.Diagnostics.Debug.WriteLine(msg);
return;
}
//attatch an event handler that will fire for each page that is printed.
printDoc.PrintPage += new PrintPageEventHandler(PrintPage);
//call print method, which get's the process going and ultimately calls the printpage method via the eventhandler.
printDoc.Print();
}

public void Run()
{
//create a new reportviewer object
ReportViewer rv = new ReportViewer();

//set the serverreport properties
rv.ServerReport.ReportPath = "/CRAMReports/ConcentrationReport";
rv.ServerReport.ReportServerUrl = new System.Uri("http://localhost/reportserver");

//configure params
List<ReportParameter> myParams = new List<ReportParameter>();
ReportParameter param = new ReportParameter("NAV", "0", false);
myParams.Add(param);
//set the params based on the param list.
rv.ServerReport.SetParameters(myParams);

//call the export method that builds the stream list.
Export(rv.ServerReport);

//call the print funciton
Print();

//call dispose which closes all the streams.
Dispose();
}

public void Dispose()
{
if (m_streams != null)
{
foreach (Stream stream in m_streams)
stream.Close();
}
}
}
|||

I am using reportviewer in local mode, where i am not using sql reporting server.

what i meant saying different connection strings is for different business objects from different databases in sql server 2005. we have different databases in sql server 2005.

Does your solution print from the browser? shall give it a try now

Thnks


|||

Hi, i have add that code

and everything is very good when i run it local through the visual Studio 2005

but when i upload the Application and run it thought the IIS the printing doent work and i dont know why.

Note: i am using local report.

i hope any one help coz i need it so much

|||

Hi, i have add that code

and everything is very good when i run it local through the visual Studio 2005

but when i upload the Application and run it thought the IIS the printing doent work and i dont know why.

Note: i am using local report.

|||What type of printers do you have? What are the print drivers?|||

hi,

i dont know if i understand your question well or not but iam using printer HP DeskJet 1220C from my client PC,

i hope i answer your question ,

i hope you help me soon because i need this part so much.

Maylo

|||

Guys,

There seem to be a couple of confusions here (I may be misreading the messages, but I'm going to give this a try anyway).

1. Sekhar T, even though you are using "local mode", not server mode, it's not like the actual databinding is happening on the client. It's happening on your web server. So to my mind the fact that you are dynamically binding is not all that relevant. You have the same opportunity in a "separate button" as you do when the page is normally posted back, to evaluate the user's needs and re-bind.

2. While it is true that report pages can be rendered to EMF, that doesn't make sense in your case. First, because you would be doing that on the web server (which has nothing to do with printing in the browser, agreed) and second, because I am not sure localmode reports can render to EMFs.

3. *HOWEVER* localmode reports can render to PDFs and of course PDFs can be easily printed by the user. While the user can already export to PDF from the reportviewer interface, you can in fact use a separate button for this purpose on the web page. See code below; I will include some binding code.

Code Snippet

Partial Class pages_Default

Inherits System.Web.UI.Page

' here's a sketch of how to send the PDF

' back from your separate button

Protected Sub Button1_Click( _

ByVal sender As Object, ByVal e As System.EventArgs) _

Handles Button1.Click

Dim buffer As Byte(), f As String, fs As System.IO.FileStream

f = System.IO.Path.GetTempFileName()

System.IO.Path.ChangeExtension(f, "PDF")

' there is probably a better way to set up the rendered PDF

' for redirecting to the Response output, but this one works.

' here is the binding bit. Revise to suit your dynamic situation.

' if you aren't really dynamically binding data against one

' loaded report, but rather changing

' reports to suit the user's needs, that will work too.

Dim ReportDataSourceX = _

New Microsoft.Reporting.WebForms.ReportDataSource()

ReportDataSourceX.Name = "DataSet1_Recipient"

ReportDataSourceX.Value = Me.SqlDataSource1

With Me.ReportViewer1.LocalReport

.DataSources.Clear()

.DataSources.Add(ReportDataSourceX)

buffer = .Render("PDF", Nothing, Nothing, Nothing, _

Nothing, Nothing, Nothing)

End With

fs = New System.IO.FileStream(f, System.IO.FileMode.Create)

fs.Write(buffer, 0, buffer.Length)

fs.Close()

fs.Dispose()

Response.ContentType = "Application/pdf"

Response.WriteFile(f)

Response.End()

System.IO.File.Delete(f)

End Sub

End Class

4. I am not so sure that it makes sense to have the separate button actually do the printing instead of bringing back the PDF and having the user print. If the user has to push a button anyway, shouldn't the user be able to make the normal printing decisions (such as what printer and features to use)? This is kind of the nature of a browser-based application.

5. If you really wanted javascript to print, the code would be a little different than what you see below, but not all that much. Instead of being a server-side control, I would use a "regular" button. The client side script would post to a URL that contained the required information for this user to get the report and data the way the user needed it. The client side script would receive back this data from its post and then probably save the file locally, finally sending the file out to the printer. However I don'tt think this is going to work in a whole bunch of security-limited cases. It requires too much control by script in the browser complex. Try what I"m suggesting in points 3 and 4, please, and think it over...

HTH,

>L<

Problem Printing local report in Sql reporting services

I have a local report for which i am binding the Dataset dynamically. I am trying to print this report using a seperate button on the page. I saw in the forums saying that the reportviewer can be converted to an EMF file, bind this to an image control and can Print this image using Javascript.

Can anyone help me with the sample code to print local report from the reportviewer (it may be in any approach.)

Thanks in advance.

Sekhar T
This thread should help.

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=790287&SiteID=1&mode=1&PageID=0

or at least get you on the right path.
|||

Am sorry, my app is not windows, it is web based

I tried it but didn't help me a lot. My requirement is to allow clients to print reports from their browsers. I am using a single reportviewer control to display reports by dynamically binding different business objects and reports. One important thing to notice is that my connection string changes on user selection.

I am not really sure if there is another way using server mode to do this. I don't want to create reports to each database on the server. I am looking for a solution where i can use the same report for different databases.

|||When you say "One important thing to notice is that my connection string changes on user selection." you mean you're connecting to different reporting servers?

Here's my class. at the moment i'm confused as to why the 2nd device info has a start page of + 1 where the 1st one is set to 0. But it should work for you, assuming you know how to change the properties on each report server, aka changing the reportview.serverreport.reportpath, and the reportview.serverreport.reportserverurl. (these contain the same info as the connection string)

Hope this helps.

using System;
using System.IO;
using System.Data;
using System.Text;
using System.Drawing.Imaging;
using System.Drawing.Printing;
using System.Collections.Generic;
using System.Collections.Specialized;
using Microsoft.Reporting.WebForms;
using Microsoft.Reporting;
using System.Drawing;
public partial class _Default : System.Web.UI.Page
{

protected void Page_Load(object sender, EventArgs e)
{
Demo demo = new Demo();
demo.Run();
}
}

public class Demo : IDisposable
{

private int m_currentPageIndex;
private IList<Stream> m_streams;

private void Export(ServerReport report)
{
string deviceInfo =
"<DeviceInfo>" +
"<OutputFormat>EMF</OutputFormat>" +
" <MarginTop>0.25in</MarginTop>" +
" <MarginLeft>0.25in</MarginLeft>" +
" <MarginRight>0.25in</MarginRight>" +
" <MarginBottom>0.25in</MarginBottom>" +
" <StartPage>0</StartPage>" +
"</DeviceInfo>";
m_streams = new List<Stream>();

string encoding;
string mimeType;
string extension;
Warning[] warnings;
string[] streamIDs = null;
Byte[][] pages = null;

//Create Byte array containing the rendered image. of the 1st page.
Byte[] firstPage = report.Render("Image", deviceInfo, out mimeType, out encoding, out extension, out streamIDs, out warnings);

m_streams.Add(new MemoryStream(firstPage));

// The total number of pages of the report is 1 + the streamIDs
int m_numberOfPages = streamIDs.Length + 1;
pages = new Byte[m_numberOfPages][];

// The first page was already rendered
pages[0] = firstPage;

for (int pageIndex = 1; pageIndex < m_numberOfPages; pageIndex++)
{
// Build device info based on start page
deviceInfo = String.Format(
"<DeviceInfo>" +
"<OutputFormat>EMF</OutputFormat>" +
" <MarginTop>0.25in</MarginTop>" +
" <MarginLeft>0.25in</MarginLeft>" +
" <MarginRight>0.25in</MarginRight>" +
" <MarginBottom>0.25in</MarginBottom>" +
" <StartPage>{0}</StartPage>" +
"</DeviceInfo>", pageIndex+1);

//Render the page to a byte array.
pages[pageIndex] = report.Render("Image", deviceInfo, out mimeType, out encoding, out extension, out streamIDs, out warnings);

//create a stream of the page's byte array
m_streams.Add(new MemoryStream(pages[pageIndex]));

//set the position of the stream to 0 to make sure when the stream is read
//it starts from the beginning.
m_streams[m_streams.Count-1].Position = 0;
}

m_currentPageIndex = 0;
}

private void PrintPage(object sender, PrintPageEventArgs ev)
{
//create a new metafile based on the page that we're trying to print.
Metafile pageImage = new Metafile(m_streams[m_currentPageIndex]);

//draw the an image deciding what to draw, and where to place it on the page.
ev.Graphics.DrawImage(pageImage, 0, 0);
//increment to the next page.
m_currentPageIndex++;

//decide if we've read our last stream.
ev.HasMorePages = (m_currentPageIndex < m_streams.Count);
}

private void Print()
{
//the name of the printer.
const string printerName = "Microsoft Office Document Image Writer";//;"\\\\NPSERVER\\MAIN"

//if there's nothing to print return
if (m_streams == null || m_streams.Count == 0)
return;

//create the printdocument object
PrintDocument printDoc = new PrintDocument();

//set the printername, deal w/ the printer being invalid
printDoc.PrinterSettings.PrinterName = printerName;
if (!printDoc.PrinterSettings.IsValid)
{
string msg = String.Format("Can't find printer \"{0}\".", printerName);
System.Diagnostics.Debug.WriteLine(msg);
return;
}
//attatch an event handler that will fire for each page that is printed.
printDoc.PrintPage += new PrintPageEventHandler(PrintPage);
//call print method, which get's the process going and ultimately calls the printpage method via the eventhandler.
printDoc.Print();
}

public void Run()
{
//create a new reportviewer object
ReportViewer rv = new ReportViewer();

//set the serverreport properties
rv.ServerReport.ReportPath = "/CRAMReports/ConcentrationReport";
rv.ServerReport.ReportServerUrl = new System.Uri("http://localhost/reportserver");

//configure params
List<ReportParameter> myParams = new List<ReportParameter>();
ReportParameter param = new ReportParameter("NAV", "0", false);
myParams.Add(param);
//set the params based on the param list.
rv.ServerReport.SetParameters(myParams);

//call the export method that builds the stream list.
Export(rv.ServerReport);

//call the print funciton
Print();

//call dispose which closes all the streams.
Dispose();
}

public void Dispose()
{
if (m_streams != null)
{
foreach (Stream stream in m_streams)
stream.Close();
}
}
}
|||

I am using reportviewer in local mode, where i am not using sql reporting server.

what i meant saying different connection strings is for different business objects from different databases in sql server 2005. we have different databases in sql server 2005.

Does your solution print from the browser? shall give it a try now

Thnks


|||

Hi, i have add that code

and everything is very good when i run it local through the visual Studio 2005

but when i upload the Application and run it thought the IIS the printing doent work and i dont know why.

Note: i am using local report.

i hope any one help coz i need it so much

|||

Hi, i have add that code

and everything is very good when i run it local through the visual Studio 2005

but when i upload the Application and run it thought the IIS the printing doent work and i dont know why.

Note: i am using local report.

|||What type of printers do you have? What are the print drivers?|||

hi,

i dont know if i understand your question well or not but iam using printer HP DeskJet 1220C from my client PC,

i hope i answer your question ,

i hope you help me soon because i need this part so much.

Maylo

|||

Guys,

There seem to be a couple of confusions here (I may be misreading the messages, but I'm going to give this a try anyway).

1. Sekhar T, even though you are using "local mode", not server mode, it's not like the actual databinding is happening on the client. It's happening on your web server. So to my mind the fact that you are dynamically binding is not all that relevant. You have the same opportunity in a "separate button" as you do when the page is normally posted back, to evaluate the user's needs and re-bind.

2. While it is true that report pages can be rendered to EMF, that doesn't make sense in your case. First, because you would be doing that on the web server (which has nothing to do with printing in the browser, agreed) and second, because I am not sure localmode reports can render to EMFs.

3. *HOWEVER* localmode reports can render to PDFs and of course PDFs can be easily printed by the user. While the user can already export to PDF from the reportviewer interface, you can in fact use a separate button for this purpose on the web page. See code below; I will include some binding code.

Code Snippet

PartialClass pages_Default

Inherits System.Web.UI.Page

' here's a sketch of how to send the PDF

' back from your separate button

ProtectedSub Button1_Click( _

ByVal sender AsObject, ByVal e As System.EventArgs) _

Handles Button1.Click

Dim buffer AsByte(), f AsString, fs As System.IO.FileStream

f = System.IO.Path.GetTempFileName()

System.IO.Path.ChangeExtension(f, "PDF")

' there is probably a better way to set up the rendered PDF

' for redirecting to the Response output, but this one works.

' here is the binding bit. Revise to suit your dynamic situation.

' if you aren't really dynamically binding data against one

' loaded report, but rather changing

' reports to suit the user's needs, that will work too.

Dim ReportDataSourceX = _

New Microsoft.Reporting.WebForms.ReportDataSource()

ReportDataSourceX.Name = "DataSet1_Recipient"

ReportDataSourceX.Value = Me.SqlDataSource1

WithMe.ReportViewer1.LocalReport

.DataSources.Clear()

.DataSources.Add(ReportDataSourceX)

buffer = .Render("PDF", Nothing, Nothing, Nothing, _

Nothing, Nothing, Nothing)

EndWith

fs = New System.IO.FileStream(f, System.IO.FileMode.Create)

fs.Write(buffer, 0, buffer.Length)

fs.Close()

fs.Dispose()

Response.ContentType = "Application/pdf"

Response.WriteFile(f)

Response.End()

System.IO.File.Delete(f)

EndSub

EndClass

4. I am not so sure that it makes sense to have the separate button actually do the printing instead of bringing back the PDF and having the user print. If the user has to push a button anyway, shouldn't the user be able to make the normal printing decisions (such as what printer and features to use)? This is kind of the nature of a browser-based application.

5. If you really wanted javascript to print, the code would be a little different than what you see below, but not all that much. Instead of being a server-side control, I would use a "regular" button. The client side script would post to a URL that contained the required information for this user to get the report and data the way the user needed it. The client side script would receive back this data from its post and then probably save the file locally, finally sending the file out to the printer. However I don'tt think this is going to work in a whole bunch of security-limited cases. It requires too much control by script in the browser complex. Try what I"m suggesting in points 3 and 4, please, and think it over...

HTH,

>L<

Problem Printing local report in Sql reporting services

I have a local report for which i am binding the Dataset dynamically. I am trying to print this report using a seperate button on the page. I saw in the forums saying that the reportviewer can be converted to an EMF file, bind this to an image control and can Print this image using Javascript.

Can anyone help me with the sample code to print local report from the reportviewer (it may be in any approach.)

Thanks in advance.

Sekhar T
This thread should help.

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=790287&SiteID=1&mode=1&PageID=0

or at least get you on the right path.
|||

Am sorry, my app is not windows, it is web based

I tried it but didn't help me a lot. My requirement is to allow clients to print reports from their browsers. I am using a single reportviewer control to display reports by dynamically binding different business objects and reports. One important thing to notice is that my connection string changes on user selection.

I am not really sure if there is another way using server mode to do this. I don't want to create reports to each database on the server. I am looking for a solution where i can use the same report for different databases.

|||When you say "One important thing to notice is that my connection string changes on user selection." you mean you're connecting to different reporting servers?

Here's my class. at the moment i'm confused as to why the 2nd device info has a start page of + 1 where the 1st one is set to 0. But it should work for you, assuming you know how to change the properties on each report server, aka changing the reportview.serverreport.reportpath, and the reportview.serverreport.reportserverurl. (these contain the same info as the connection string)

Hope this helps.

using System;
using System.IO;
using System.Data;
using System.Text;
using System.Drawing.Imaging;
using System.Drawing.Printing;
using System.Collections.Generic;
using System.Collections.Specialized;
using Microsoft.Reporting.WebForms;
using Microsoft.Reporting;
using System.Drawing;
public partial class _Default : System.Web.UI.Page
{

protected void Page_Load(object sender, EventArgs e)
{
Demo demo = new Demo();
demo.Run();
}
}

public class Demo : IDisposable
{

private int m_currentPageIndex;
private IList<Stream> m_streams;

private void Export(ServerReport report)
{
string deviceInfo =
"<DeviceInfo>" +
"<OutputFormat>EMF</OutputFormat>" +
" <MarginTop>0.25in</MarginTop>" +
" <MarginLeft>0.25in</MarginLeft>" +
" <MarginRight>0.25in</MarginRight>" +
" <MarginBottom>0.25in</MarginBottom>" +
" <StartPage>0</StartPage>" +
"</DeviceInfo>";
m_streams = new List<Stream>();

string encoding;
string mimeType;
string extension;
Warning[] warnings;
string[] streamIDs = null;
Byte[][] pages = null;

//Create Byte array containing the rendered image. of the 1st page.
Byte[] firstPage = report.Render("Image", deviceInfo, out mimeType, out encoding, out extension, out streamIDs, out warnings);

m_streams.Add(new MemoryStream(firstPage));

// The total number of pages of the report is 1 + the streamIDs
int m_numberOfPages = streamIDs.Length + 1;
pages = new Byte[m_numberOfPages][];

// The first page was already rendered
pages[0] = firstPage;

for (int pageIndex = 1; pageIndex < m_numberOfPages; pageIndex++)
{
// Build device info based on start page
deviceInfo = String.Format(
"<DeviceInfo>" +
"<OutputFormat>EMF</OutputFormat>" +
" <MarginTop>0.25in</MarginTop>" +
" <MarginLeft>0.25in</MarginLeft>" +
" <MarginRight>0.25in</MarginRight>" +
" <MarginBottom>0.25in</MarginBottom>" +
" <StartPage>{0}</StartPage>" +
"</DeviceInfo>", pageIndex+1);

//Render the page to a byte array.
pages[pageIndex] = report.Render("Image", deviceInfo, out mimeType, out encoding, out extension, out streamIDs, out warnings);

//create a stream of the page's byte array
m_streams.Add(new MemoryStream(pages[pageIndex]));

//set the position of the stream to 0 to make sure when the stream is read
//it starts from the beginning.
m_streams[m_streams.Count-1].Position = 0;
}

m_currentPageIndex = 0;
}

private void PrintPage(object sender, PrintPageEventArgs ev)
{
//create a new metafile based on the page that we're trying to print.
Metafile pageImage = new Metafile(m_streams[m_currentPageIndex]);

//draw the an image deciding what to draw, and where to place it on the page.
ev.Graphics.DrawImage(pageImage, 0, 0);
//increment to the next page.
m_currentPageIndex++;

//decide if we've read our last stream.
ev.HasMorePages = (m_currentPageIndex < m_streams.Count);
}

private void Print()
{
//the name of the printer.
const string printerName = "Microsoft Office Document Image Writer";//;"\\\\NPSERVER\\MAIN"

//if there's nothing to print return
if (m_streams == null || m_streams.Count == 0)
return;

//create the printdocument object
PrintDocument printDoc = new PrintDocument();

//set the printername, deal w/ the printer being invalid
printDoc.PrinterSettings.PrinterName = printerName;
if (!printDoc.PrinterSettings.IsValid)
{
string msg = String.Format("Can't find printer \"{0}\".", printerName);
System.Diagnostics.Debug.WriteLine(msg);
return;
}
//attatch an event handler that will fire for each page that is printed.
printDoc.PrintPage += new PrintPageEventHandler(PrintPage);
//call print method, which get's the process going and ultimately calls the printpage method via the eventhandler.
printDoc.Print();
}

public void Run()
{
//create a new reportviewer object
ReportViewer rv = new ReportViewer();

//set the serverreport properties
rv.ServerReport.ReportPath = "/CRAMReports/ConcentrationReport";
rv.ServerReport.ReportServerUrl = new System.Uri("http://localhost/reportserver");

//configure params
List<ReportParameter> myParams = new List<ReportParameter>();
ReportParameter param = new ReportParameter("NAV", "0", false);
myParams.Add(param);
//set the params based on the param list.
rv.ServerReport.SetParameters(myParams);

//call the export method that builds the stream list.
Export(rv.ServerReport);

//call the print funciton
Print();

//call dispose which closes all the streams.
Dispose();
}

public void Dispose()
{
if (m_streams != null)
{
foreach (Stream stream in m_streams)
stream.Close();
}
}
}
|||

I am using reportviewer in local mode, where i am not using sql reporting server.

what i meant saying different connection strings is for different business objects from different databases in sql server 2005. we have different databases in sql server 2005.

Does your solution print from the browser? shall give it a try now

Thnks


|||

Hi, i have add that code

and everything is very good when i run it local through the visual Studio 2005

but when i upload the Application and run it thought the IIS the printing doent work and i dont know why.

Note: i am using local report.

i hope any one help coz i need it so much

|||

Hi, i have add that code

and everything is very good when i run it local through the visual Studio 2005

but when i upload the Application and run it thought the IIS the printing doent work and i dont know why.

Note: i am using local report.

|||What type of printers do you have? What are the print drivers?|||

hi,

i dont know if i understand your question well or not but iam using printer HP DeskJet 1220C from my client PC,

i hope i answer your question ,

i hope you help me soon because i need this part so much.

Maylo

|||

Guys,

There seem to be a couple of confusions here (I may be misreading the messages, but I'm going to give this a try anyway).

1. Sekhar T, even though you are using "local mode", not server mode, it's not like the actual databinding is happening on the client. It's happening on your web server. So to my mind the fact that you are dynamically binding is not all that relevant. You have the same opportunity in a "separate button" as you do when the page is normally posted back, to evaluate the user's needs and re-bind.

2. While it is true that report pages can be rendered to EMF, that doesn't make sense in your case. First, because you would be doing that on the web server (which has nothing to do with printing in the browser, agreed) and second, because I am not sure localmode reports can render to EMFs.

3. *HOWEVER* localmode reports can render to PDFs and of course PDFs can be easily printed by the user. While the user can already export to PDF from the reportviewer interface, you can in fact use a separate button for this purpose on the web page. See code below; I will include some binding code.

Code Snippet

Partial Class pages_Default

Inherits System.Web.UI.Page

' here's a sketch of how to send the PDF

' back from your separate button

Protected Sub Button1_Click( _

ByVal sender As Object, ByVal e As System.EventArgs) _

Handles Button1.Click

Dim buffer As Byte(), f As String, fs As System.IO.FileStream

f = System.IO.Path.GetTempFileName()

System.IO.Path.ChangeExtension(f, "PDF")

' there is probably a better way to set up the rendered PDF

' for redirecting to the Response output, but this one works.

' here is the binding bit. Revise to suit your dynamic situation.

' if you aren't really dynamically binding data against one

' loaded report, but rather changing

' reports to suit the user's needs, that will work too.

Dim ReportDataSourceX = _

New Microsoft.Reporting.WebForms.ReportDataSource()

ReportDataSourceX.Name = "DataSet1_Recipient"

ReportDataSourceX.Value = Me.SqlDataSource1

With Me.ReportViewer1.LocalReport

.DataSources.Clear()

.DataSources.Add(ReportDataSourceX)

buffer = .Render("PDF", Nothing, Nothing, Nothing, _

Nothing, Nothing, Nothing)

End With

fs = New System.IO.FileStream(f, System.IO.FileMode.Create)

fs.Write(buffer, 0, buffer.Length)

fs.Close()

fs.Dispose()

Response.ContentType = "Application/pdf"

Response.WriteFile(f)

Response.End()

System.IO.File.Delete(f)

End Sub

End Class

4. I am not so sure that it makes sense to have the separate button actually do the printing instead of bringing back the PDF and having the user print. If the user has to push a button anyway, shouldn't the user be able to make the normal printing decisions (such as what printer and features to use)? This is kind of the nature of a browser-based application.

5. If you really wanted javascript to print, the code would be a little different than what you see below, but not all that much. Instead of being a server-side control, I would use a "regular" button. The client side script would post to a URL that contained the required information for this user to get the report and data the way the user needed it. The client side script would receive back this data from its post and then probably save the file locally, finally sending the file out to the printer. However I don'tt think this is going to work in a whole bunch of security-limited cases. It requires too much control by script in the browser complex. Try what I"m suggesting in points 3 and 4, please, and think it over...

HTH,

>L<

Wednesday, March 21, 2012

Problem opening local cube with ProClarity 6.2

I am new to BI and have a perplexing problem. I need to create a local cube for offline use in ProClarity 6.2 for mobile users.

I have created a sample cube in AS2005 using the following code:

CREATE GLOBAL CUBE [RainbowBranch]

Storage 'C:\SourceData\RainbowBranch.cub'

FROM [Rainbow Trade Sales]

(

MEASURE [Rainbow Trade Sales].[Adj Sales Value],

DIMENSION [Rainbow Trade Sales].[Branch]

)

The resultant cube can be opened in Excel 2003 with no problems, but when opened in ProClarity, there is no cube name to select, so I can never get to see the cube data.

Is there a problem with my cube build statement? Does it need more in terms of parameters, etc.

Regards,

Charles.

Hello. The coming 6.3 version of ProClarity, supposed to be released any day, will have strong improvements for local cubes. You can have a problem with a bug in 6.2

HTH

Thomas Ivarsson

|||

Thanks Thomas,

I heard about the forthcoming ProClarity 6.3 release. I believe that it will only be available from our vendor at the end of March, which is a problem in terms of making decisions at this point in time. Anyhow, back to my current problem; A colleague sent me a cub file to test, the cub is named "Debtors Analysis" - I think it is part of sample data but I do not know how it was generated (AS2000 perhaps or ProClarity 5.3 ?). This "Debtors Analysis" cub opens perfectly in both ProClarity 6.1 & 6.2 as well as in Excel 2003. This leads me to believe that my problem lies with my cub file - either something missing in my cub file which causes ProClarity to fail, or something extra in the cub file which ProClarity does not recognise.

Are you aware of any other way to create cub files that I can test in the meantime. Preferably not using another 3rd party, commercial product. Thanks.

Regards,

Charles.

|||Have you tried looking on the Proclarity community bulletin boards... There are many similar posts|||I have the same problem to open local cube.

Problem opening local cube with ProClarity 6.2

I am new to BI and have a perplexing problem. I need to create a local cube for offline use in ProClarity 6.2 for mobile users.

I have created a sample cube in AS2005 using the following code:

CREATE GLOBAL CUBE [RainbowBranch]

Storage 'C:\SourceData\RainbowBranch.cub'

FROM [Rainbow Trade Sales]

(

MEASURE [Rainbow Trade Sales].[Adj Sales Value],

DIMENSION [Rainbow Trade Sales].[Branch]

)

The resultant cube can be opened in Excel 2003 with no problems, but when opened in ProClarity, there is no cube name to select, so I can never get to see the cube data.

Is there a problem with my cube build statement? Does it need more in terms of parameters, etc.

Regards,

Charles.

Hello. The coming 6.3 version of ProClarity, supposed to be released any day, will have strong improvements for local cubes. You can have a problem with a bug in 6.2

HTH

Thomas Ivarsson

|||

Thanks Thomas,

I heard about the forthcoming ProClarity 6.3 release. I believe that it will only be available from our vendor at the end of March, which is a problem in terms of making decisions at this point in time. Anyhow, back to my current problem; A colleague sent me a cub file to test, the cub is named "Debtors Analysis" - I think it is part of sample data but I do not know how it was generated (AS2000 perhaps or ProClarity 5.3 ?). This "Debtors Analysis" cub opens perfectly in both ProClarity 6.1 & 6.2 as well as in Excel 2003. This leads me to believe that my problem lies with my cub file - either something missing in my cub file which causes ProClarity to fail, or something extra in the cub file which ProClarity does not recognise.

Are you aware of any other way to create cub files that I can test in the meantime. Preferably not using another 3rd party, commercial product. Thanks.

Regards,

Charles.

|||Have you tried looking on the Proclarity community bulletin boards... There are many similar posts

Problem opening diagrams in enterprise manager

Hi,
since 2 days I cannot open any database diagram on any sql server using my local pc. Using a remote desktopn session, I can use the enterprise manager installed on the servers to open the disgrams, but using my local instance I simply get an empty white w
indow - that's all. There's no error message. from my pc it seems the diagrams are empty. Also I get no context menu from that empty window. I guess something with the MMC on my pc is wrong - but what can I do? I've already reinstalled the sql server clie
nt tools on my pc and I've also tried to install a development edition with SP3 - no success.
Sven
hi Sven, Bill,
"Sven" <anonymous@.discussions.microsoft.com> ha scritto nel messaggio
news:A59FC9F1-35DD-488D-9273-1A4AE8109E0A@.microsoft.com...
> Hi,
> since 2 days I cannot open any database diagram on any sql server using my
local pc. Using a remote desktopn session, I can use the enterprise manager
installed on the servers to open the disgrams, but using my local instance I
simply get an empty white window - that's all. There's no error message.
from my pc it seems the diagrams are empty. Also I get no context menu from
that empty window. I guess something with the MMC on my pc is wrong - but
what can I do? I've already reinstalled the sql server client tools on my pc
and I've also tried to install a development edition with SP3 - no success.
> Sven
please report these issues, if you think they are related to VB6 sp6 to
Microsoft VB MVP Randy Birch in the microsoft.public.vb.bugs newsgroup ,
thread "Please Report SP6 bugs! (was [BUG] Crash di vb.exe)" dated
04/10/2004
(http://tinyurl.com/23w8s)... he is collecting a bug list to be presented to
VB dev team in order to prepare a hotfix post service pack 6...
thank you
Andrea Montanari (Microsoft MVP - SQL Server)
http://www.asql.biz/DbaMgr.shtmhttp://italy.mvps.org
DbaMgr2k ver 0.7.0 - DbaMgr ver 0.53.0
(my vb6+sql-dmo little try to provide MS MSDE 1.0 and MSDE 2000 a visual
interface)
-- remove DMO to reply

Tuesday, March 20, 2012

Problem on getting resultset from remote stored procedure

Hi!
I've a problem on getting resultset from remote stored procedure from the local server.
The stored procedure on the remote server:
create procedure sp_test
begin
create table #temp
( field_a char(10,
field_b char(15) )
insert into #temp
select * from abc
select * from #temp
end
on the local server, the command is
create table #temp
( field_a char(10,
field_b char(15) )
insert into #temp
select * from openquery(LINKEDSERVER,'LINKEDSERVER.DBNAME.dbo.sp_test')
/*****/
the server prompt that table #temp not found
if I simply run LINKEDSERVER.DBNAME.dbo.sp_test
it works.
Actually I need to prepare a stored procedure on the local server to execute sp_temp on remote server.
I tried to use other method to do the task, such as
insert into #temp
exec LINKEDSERVER.DBNAME.dbo.sp_test
but the server prompt that MSDTC service not found in the server.
as i'm not quite familer on MSDTC service, I tried to use other method.
for doing this task, is it a must to start the MSDTC service.
if I start it, what effect will be (performance, loading etc)
please help!! thanks!!
Yeah, for the most part just start DTC and let it go its merry way. It will not have a negative impact on performance. Can somebody check me on this please?|||

Yes, I just afraid the loading and performance would be affected after starting MSDTC.

Friday, March 9, 2012

Problem migrating from sql7 to sql2000 - connection failure

We have an inhouse app written in Delphi which connects to a local server
running SQL7. When we migrated the database to a server running SQL2000 we
ran into problems.
When a user uses the Delphi app to browse data, it seems ok, but when the
user insert records, the app responded "Connection failure".
In the application log of the event viewer, we noticed the following:
Error: 17805, Severity: 20, State: 3
Invalid buffer received from client.
I did a search on support.microsoft.com for this message. It seems there is
some information regarding this on some complicated cause which will be
addressed in service pack 4.
I wonder should I wait for service pack 4 to solve it, or is there something
I can do?LL
From Erland
The message indicates a protocol error in the dialog between client and
server. There are several possible causes for this. The most likely
causes are 1) network problems 2) bug in the client library.
"LL" <LL@.discussions.microsoft.com> wrote in message
news:8A487A41-DE7C-4A5A-B7B7-0397322AD79D@.microsoft.com...
> We have an inhouse app written in Delphi which connects to a local server
> running SQL7. When we migrated the database to a server running SQL2000 we
> ran into problems.
> When a user uses the Delphi app to browse data, it seems ok, but when the
> user insert records, the app responded "Connection failure".
> In the application log of the event viewer, we noticed the following:
> Error: 17805, Severity: 20, State: 3
> Invalid buffer received from client.
> I did a search on support.microsoft.com for this message. It seems there
is
> some information regarding this on some complicated cause which will be
> addressed in service pack 4.
> I wonder should I wait for service pack 4 to solve it, or is there
something
> I can do?|||I dont know how it relates to network problem, because the error condition
only happens when we use a user account to insert/change data via the app.
The only thing that i can say is that the sql 2000 database resides on the
domain controller server, whereas, before the sql 7 database resides on a
workgroup server. i will need to follow up with the programmer to see if
there exist some hardcoded machine name inside the app that causes the
failure.
As for 'bug in client library', i dont know why a failure only happens
during write. but it sounds like i can only try to get the programmer to
check the app or see if there are other compatible versions of delphi that
works with sql2000.
thanks for your reply anyways...
"Uri Dimant" wrote:
> LL
> From Erland
> The message indicates a protocol error in the dialog between client and
> server. There are several possible causes for this. The most likely
> causes are 1) network problems 2) bug in the client library.
>
> "LL" <LL@.discussions.microsoft.com> wrote in message
> news:8A487A41-DE7C-4A5A-B7B7-0397322AD79D@.microsoft.com...
> > We have an inhouse app written in Delphi which connects to a local server
> > running SQL7. When we migrated the database to a server running SQL2000 we
> > ran into problems.
> >
> > When a user uses the Delphi app to browse data, it seems ok, but when the
> > user insert records, the app responded "Connection failure".
> >
> > In the application log of the event viewer, we noticed the following:
> >
> > Error: 17805, Severity: 20, State: 3
> > Invalid buffer received from client.
> >
> > I did a search on support.microsoft.com for this message. It seems there
> is
> > some information regarding this on some complicated cause which will be
> > addressed in service pack 4.
> >
> > I wonder should I wait for service pack 4 to solve it, or is there
> something
> > I can do?
>
>|||Dear LL :
I also got this error when using delphi 7 to update or changing the
record. My database is also migrating from sql7 to sql2k, please send me
some information if you can solve this problem , tkx so much
George

Problem migrating from sql7 to sql2000 - connection failure

We have an inhouse app written in Delphi which connects to a local server
running SQL7. When we migrated the database to a server running SQL2000 we
ran into problems.
When a user uses the Delphi app to browse data, it seems ok, but when the
user insert records, the app responded "Connection failure".
In the application log of the event viewer, we noticed the following:
Error: 17805, Severity: 20, State: 3
Invalid buffer received from client.
I did a search on support.microsoft.com for this message. It seems there is
some information regarding this on some complicated cause which will be
addressed in service pack 4.
I wonder should I wait for service pack 4 to solve it, or is there something
I can do?
LL
From Erland
The message indicates a protocol error in the dialog between client and
server. There are several possible causes for this. The most likely
causes are 1) network problems 2) bug in the client library.
"LL" <LL@.discussions.microsoft.com> wrote in message
news:8A487A41-DE7C-4A5A-B7B7-0397322AD79D@.microsoft.com...
> We have an inhouse app written in Delphi which connects to a local server
> running SQL7. When we migrated the database to a server running SQL2000 we
> ran into problems.
> When a user uses the Delphi app to browse data, it seems ok, but when the
> user insert records, the app responded "Connection failure".
> In the application log of the event viewer, we noticed the following:
> Error: 17805, Severity: 20, State: 3
> Invalid buffer received from client.
> I did a search on support.microsoft.com for this message. It seems there
is
> some information regarding this on some complicated cause which will be
> addressed in service pack 4.
> I wonder should I wait for service pack 4 to solve it, or is there
something
> I can do?
|||I dont know how it relates to network problem, because the error condition
only happens when we use a user account to insert/change data via the app.
The only thing that i can say is that the sql 2000 database resides on the
domain controller server, whereas, before the sql 7 database resides on a
workgroup server. i will need to follow up with the programmer to see if
there exist some hardcoded machine name inside the app that causes the
failure.
As for 'bug in client library', i dont know why a failure only happens
during write. but it sounds like i can only try to get the programmer to
check the app or see if there are other compatible versions of delphi that
works with sql2000.
thanks for your reply anyways...
"Uri Dimant" wrote:

> LL
> From Erland
> The message indicates a protocol error in the dialog between client and
> server. There are several possible causes for this. The most likely
> causes are 1) network problems 2) bug in the client library.
>
> "LL" <LL@.discussions.microsoft.com> wrote in message
> news:8A487A41-DE7C-4A5A-B7B7-0397322AD79D@.microsoft.com...
> is
> something
>
>
|||Dear LL :
I also got this error when using delphi 7 to update or changing the
record. My database is also migrating from sql7 to sql2k, please send me
some information if you can solve this problem , tkx so much
George

Problem migrating from sql7 to sql2000 - connection failure

We have an inhouse app written in Delphi which connects to a local server
running SQL7. When we migrated the database to a server running SQL2000 we
ran into problems.
When a user uses the Delphi app to browse data, it seems ok, but when the
user insert records, the app responded "Connection failure".
In the application log of the event viewer, we noticed the following:
Error: 17805, Severity: 20, State: 3
Invalid buffer received from client.
I did a search on support.microsoft.com for this message. It seems there is
some information regarding this on some complicated cause which will be
addressed in service pack 4.
I wonder should I wait for service pack 4 to solve it, or is there something
I can do?LL
From Erland
The message indicates a protocol error in the dialog between client and
server. There are several possible causes for this. The most likely
causes are 1) network problems 2) bug in the client library.
"LL" <LL@.discussions.microsoft.com> wrote in message
news:8A487A41-DE7C-4A5A-B7B7-0397322AD79D@.microsoft.com...
> We have an inhouse app written in Delphi which connects to a local server
> running SQL7. When we migrated the database to a server running SQL2000 we
> ran into problems.
> When a user uses the Delphi app to browse data, it seems ok, but when the
> user insert records, the app responded "Connection failure".
> In the application log of the event viewer, we noticed the following:
> Error: 17805, Severity: 20, State: 3
> Invalid buffer received from client.
> I did a search on support.microsoft.com for this message. It seems there
is
> some information regarding this on some complicated cause which will be
> addressed in service pack 4.
> I wonder should I wait for service pack 4 to solve it, or is there
something
> I can do?|||I dont know how it relates to network problem, because the error condition
only happens when we use a user account to insert/change data via the app.
The only thing that i can say is that the sql 2000 database resides on the
domain controller server, whereas, before the sql 7 database resides on a
workgroup server. i will need to follow up with the programmer to see if
there exist some hardcoded machine name inside the app that causes the
failure.
As for 'bug in client library', i dont know why a failure only happens
during write. but it sounds like i can only try to get the programmer to
check the app or see if there are other compatible versions of delphi that
works with sql2000.
thanks for your reply anyways...
"Uri Dimant" wrote:

> LL
> From Erland
> The message indicates a protocol error in the dialog between client and
> server. There are several possible causes for this. The most likely
> causes are 1) network problems 2) bug in the client library.
>
> "LL" <LL@.discussions.microsoft.com> wrote in message
> news:8A487A41-DE7C-4A5A-B7B7-0397322AD79D@.microsoft.com...
> is
> something
>
>|||Dear LL :
I also got this error when using delphi 7 to update or changing the
record. My database is also migrating from sql7 to sql2k, please send me
some information if you can solve this problem , tkx so much
George

Saturday, February 25, 2012

Problem installing SQL 2000 on SBS2003

Hi,
I am getting an error right after it asks if the server is local or remote.
It says that a previous program installation created pending file operations
on the installation machine. And that i must restart the computer. I've
restarted...doesn't make a difference. The server has MSDE for sbs
installed. Not sure what to do.
Thanks,
Andrew OuellettePlease try the following:
1. Run Registry Editor
2. Go to HKEY_LOCAL_MACHINE folder
3. Go to SYSTEM folder
4. Go to CurrentControlSet folder
5. Go to Control folder
6. Go to Session Manager folder
7. Double-click on the PendingFileRenameOperations key
and remove everything from the Value Data section
This ought to do it, I hope!
Thanks,
Dee
>--Original Message--
>Hi,
>I am getting an error right after it asks if the server
is local or remote.
>It says that a previous program installation created
pending file operations
>on the installation machine. And that i must restart the
computer. I've
>restarted...doesn't make a difference. The server has
MSDE for sbs
>installed. Not sure what to do.
>Thanks,
>Andrew Ouellette
>.
>