Showing posts with label html. Show all posts
Showing posts with label html. Show all posts

Tuesday, March 20, 2012

Pulling HTML out of a Database

Good Morning,

I'm not quite sure this is the right place to post this, but i'll try anyway.

I have a website where I allow people to create their own layouts in HTML, and in the HTML I have them placeing markers (eg. |1| ) where they would like to place something from a database. All the HTML is stored in a SQL Server DB, and when I pull it out, it's fine, except it won't allow me to Replace any of the markers with values from the DB.

Here's and example line of HTML that's held in the DB:

<table width='50%' border='1'><tr><td>|0|</td><td>|1|</td></tr>

and when I do a strHtml.Replace("|0|", dReader["somefield"].ToString()) or even just a strHtml.Replace("|0|", "Test") it never changes it.

Anyone have any ideas?

Thanks,

Deepthought

String.Replace returns a new string with the values replaced. Should be doing something like this in your code

strHtml= strHtml.Replace("|0|", dReader["somefield"].ToString())

Friday, March 9, 2012

Publishing OLAP based Pivotables from Excel

Hi

I want to publish an OLAP based pivottables from Excel to a HTML file using Office web componets.

I have a server with SQL Analysis Services 2005 cubes and I can browse the cube from my desktop in Excel 2003 Pivottables.

When I publish the Pivottable with Pivottable interactivity I get an error in the browser:

The query could not be processed

- An error was encountered in the transport layer

- The peer prematurely closed the connection

In the Pivottable I have set 'Save password' in properties.

Any suggestions ?

Thomas Black

I'm having the same error msg and problem to access SSAS 2005 cube over http at client machine.

This doesn't happen if you work in server (with Sql Server 2005 and web server installed).

|||Hello

did you manage to get around this error? I get this when I try to display a pivottable for data on a remote (but in LAN) server, connect goes through ...

Thanks for any help

Regards
Klaus Wiesel
|||

I used this link:

http://www.microsoft.com/downloads/details.aspx?FamilyID=38be67a5-2056-46a1-84b1-337ffb549c5c&DisplayLang=en

That enables Pivottables and charts in Sharepoint. Very easy to use. Useful for designing dashboards.

Regard

Thomas

|||

I also encountered this problem ,need any solutions!

thanks a lot!

|||

Hello

I solved this for me.

The following is done by my app:

1) Connect to the server to access the existing AS databases and their cubes

2) make a connectionstring that is later on passed to the pivottable control (named opData here):

.opData.ConnectionString = sConnString
.opData.DataMember = .coCUBE_NAME
When building the sConnString you have to use a named user (in the format domain\username) with his password to be able to display the data of the remote machine

Regards

Klaus

Publishing OLAP based Pivotables from Excel

Hi

I want to publish an OLAP based pivottables from Excel to a HTML file using Office web componets.

I have a server with SQL Analysis Services 2005 cubes and I can browse the cube from my desktop in Excel 2003 Pivottables.

When I publish the Pivottable with Pivottable interactivity I get an error in the browser:

The query could not be processed

- An error was encountered in the transport layer

- The peer prematurely closed the connection

In the Pivottable I have set 'Save password' in properties.

Any suggestions ?

Thomas Black

I'm having the same error msg and problem to access SSAS 2005 cube over http at client machine.

This doesn't happen if you work in server (with Sql Server 2005 and web server installed).

|||Hello

did you manage to get around this error? I get this when I try to display a pivottable for data on a remote (but in LAN) server, connect goes through ...

Thanks for any help

Regards
Klaus Wiesel
|||

I used this link:

http://www.microsoft.com/downloads/details.aspx?FamilyID=38be67a5-2056-46a1-84b1-337ffb549c5c&DisplayLang=en

That enables Pivottables and charts in Sharepoint. Very easy to use. Useful for designing dashboards.

Regard

Thomas

|||

I also encountered this problem ,need any solutions!

thanks a lot!

|||

Hello

I solved this for me.

The following is done by my app:

1) Connect to the server to access the existing AS databases and their cubes

2) make a connectionstring that is later on passed to the pivottable control (named opData here):

.opData.ConnectionString = sConnString
.opData.DataMember = .coCUBE_NAME
When building the sConnString you have to use a named user (in the format domain\username) with his password to be able to display the data of the remote machine

Regards

Klaus