Showing posts with label file. Show all posts
Showing posts with label file. Show all posts

Wednesday, March 21, 2012

Distant access to Excel file for import

Hi,

I'm developping a web application and I need to import a data from an excel file to sql server 2005.

It works very well locally (visual studio & sql server & the excel file on the same machine).

But it doesn't work when visual studio & excel file are in a machine and sql server is in another server.

I have always the same problem:

'C:\Documents and Settings\momo\Bureau\File.xls' n'est pas un chemin d'accès valide. Assurez-vous que le nom du chemin d'accès est correct et qu'une connexion est établie avec le serveur sur lequel réside le fichier.

Could any one help me please ?!

Thank you in advance.

It would help if you translated the French error message to English.

|||

Sorry to be late !

Here is the translation :

'C:\Documents and Settings\momo\Desktop\File.xls' isn't a correct access path. Be sure that the name of the access path is correct and a connexion is established with the server where is the file.

In fact, I'm using the FileUpload control as follows:

string filemap = Convert.ToString(fileupload.PostedFile.FileName);

string conString = @."Provider=Microsoft.Jet.OLEDB.4.0;Extended Properties=""Excel 8.0;HDR=YES;"";Data Source=" + filemap;

Could you tell me, please, what do I have to modify in order to be able to import my file from any client machine (of course, each client machine has a copy of the same file locally).

Thanks in advance.

|||

You need to think of a different architecture. You should create a web service that writes to the SQL Server. On each client PC you need a windows application that can read the excel spreadsheet and write to the web service.

|||

Please, could I have more details on how to do it. I'm a begginer in ASP NET and so I do not know what a web service means exactely.

Thanks.

|||

Have a look at http://quickstarts.asp.net/QuickStartv20/webservices/default.aspx and work through the tutorial

"The ASP.NET Web Services QuickStart is a series of client and server samples along with supporting commentary designed to quickly acquaint developers with featuresin ASP.NET Web Services. The QuickStart samples are designed to be short, easy-to-understand illustrations of these features. By the time you finish reviewing these samples, you will be familiar with the majorfeature areas in ASP.NET Web Services. "

Displaying xml with xslt in RS

Hi,

I've got an xml and an xslt - I want to get that into reporting services. Right now I have a link to the xml file in a 'report', which will open it correctly and format with the xslt. I'd like it to display without going to an external link.

I know how to use an xml datasource, but I need the xslt applied, since it has some nice formatting in it - so i don't think that will work.

I'm trying to report on the results of a scripted ms baseline security analyzer of several servers - the style sheet lets you drill down and has links to the base reports.

Thanks for your help.

There is a way to apply xslt "automagically" in a report definition (check the Data Output tab of the Report Properties dialog) , although unfortunately you would probably have to rework your xslt a bit to use it. The reason is that the xml it is going to be applied to is the data XML of the report itself. You either need to define a report that will supply exactly the xml that you currently have as its data result, or you need to change the XSLT to fit the data xml you *will* get from some report.

The key point heres are "from some report" and "data output of a report". You can't just take any xslt result and display it within a ReportViewer interface. Is that what you are trying to do?

Note that it *is* possible to upload arbitrary files to Report Manager and then link to them, I think. But that's not the same thing as displaying those files within a reportviewer control interface.

>L<

|||

"Note that it *is* possible to upload arbitrary files to Report Manager and then link to them, I think. But that's not the same thing as displaying those files within a reportviewer control interface."

Yes, that sounds like it would be what I'm after - I really just need it there because all of our other reports are there, not because of any RS functionality. Now if I only knew the technical term for this to find it in the manual, I'd be set.

"You either need to define a report that will supply exactly the xml that you currently have as its data result"

Seems like this could work too - I'll have to look into it.

Thanks for your help Lisa.

|||

>>Yes, that sounds like it would be what I'm after - I really just need it there because all of our other reports are there, not because of any RS functionality. Now if I only knew the technical term for this to find it in the manual, I'd be set.

<rofl> Well I don't know the techical term but I can tell you that you upload the file using a button in the Report Manager that says... wait for it... Upload File. You give it a title, it becomes a browseable item in the Report manager interface (unless of course you mark it "hide in list view"), etc.

You can do it programmatically as well, you might want to look at this http://www.sqldbatips.com/showarticle.asp?ID=62 or you can probably use the SOAP API for this as well.

>L<

Monday, March 19, 2012

Displaying Report Parameters in File Name

Does anyone know if it is possible to set up a subscription that includes
report parameters in the subject line when emailing a report or report link?
Thanks for the help!!
AnthonyThe only way to accomplish this is to use data driven subscriptions. Even
with this approach you would need to write your query to build up the
subject line.
--
-Daniel
This posting is provided "AS IS" with no warranties, and confers no rights.
"anthonysjo" <anthonysjo@.discussions.microsoft.com> wrote in message
news:8396CC2A-C4C2-4477-AA68-E1508A7159AD@.microsoft.com...
> Does anyone know if it is possible to set up a subscription that includes
> report parameters in the subject line when emailing a report or report
> link?
> Thanks for the help!!
> Anthony|||Ok that is the only way I could think of. Thanks!
"Daniel Reib [MSFT]" wrote:
> The only way to accomplish this is to use data driven subscriptions. Even
> with this approach you would need to write your query to build up the
> subject line.
> --
> -Daniel
> This posting is provided "AS IS" with no warranties, and confers no rights.
>
> "anthonysjo" <anthonysjo@.discussions.microsoft.com> wrote in message
> news:8396CC2A-C4C2-4477-AA68-E1508A7159AD@.microsoft.com...
> > Does anyone know if it is possible to set up a subscription that includes
> > report parameters in the subject line when emailing a report or report
> > link?
> >
> > Thanks for the help!!
> >
> > Anthony
>
>

Friday, March 9, 2012

Displaying image

I have an image (jpg/bmp) file on the hard drive. I want to be able to point
to the path from the report and display the image. The image stored on the
hard drive can change, hence I want the image displayed on the report also to
change accordingly. The stuff I am trying to do is about the company logo.
Currently I have my company's logo displayed, and when the report goes into
production I would like the customer's logo to be displayed on the report.
Any help is appreciated.Hi,
Yes it can be done. Select 'Web' from image properties and give the URL of
the image. But you need to have the same name for all the images. So if you
want to copy a different image change the name of the new image to the same
name what you had given in your URL.
Amarnath
"KMP" wrote:
> I have an image (jpg/bmp) file on the hard drive. I want to be able to point
> to the path from the report and display the image. The image stored on the
> hard drive can change, hence I want the image displayed on the report also to
> change accordingly. The stuff I am trying to do is about the company logo.
> Currently I have my company's logo displayed, and when the report goes into
> production I would like the customer's logo to be displayed on the report.
> Any help is appreciated.|||Sorry for the delay in replying. I don't understand what you are trying to
say - I want to use the file stored on the hard drive of the server, what is
the URL thing. Can you please explain more clearly?
Thanks.
"Amarnath" wrote:
> Hi,
> Yes it can be done. Select 'Web' from image properties and give the URL of
> the image. But you need to have the same name for all the images. So if you
> want to copy a different image change the name of the new image to the same
> name what you had given in your URL.
> Amarnath
> "KMP" wrote:
> > I have an image (jpg/bmp) file on the hard drive. I want to be able to point
> > to the path from the report and display the image. The image stored on the
> > hard drive can change, hence I want the image displayed on the report also to
> > change accordingly. The stuff I am trying to do is about the company logo.
> > Currently I have my company's logo displayed, and when the report goes into
> > production I would like the customer's logo to be displayed on the report.
> > Any help is appreciated.

Wednesday, March 7, 2012

Displaying Backup file locations

Hi,

I have an application that I want to allow a user to backup their sql 2005 database. I use the SMO classes to actually perform the backup, but my application can run on a client machine, not just the database server. As I allow the user to select the location for their backup I would really like to show a folder list of server locations, not local (i.e. client) folders.

Basically I wondered if there were any UI objects available for Sql 2005 ( in the SMO namespaces perhaps), something that will display a list of server folders and could be used from a client machine.

Thanks for your help

Graham

You can get the server's default backup directory within SMO from the server's .Settings.BackupDirectory property. You should be able to find other directories using WMI queries, I'd think.

|||As Allan said, this is done through WMI.

HTH, Jens K. Suessmeyer.

http://www.sqlserver2005.de

Displaying a word document via Reporting Services?

Does anyone know a way to (given a path to the file) display a word document via a reporting services report?

Thanks

This is not possible out-of-the-box. You could implement a custom renderer to do this.

You can publish Word documents into the Report Server catalog and browse them, though, you just can't embed them in reports.

|||I'm not sure what you mean by Report Server Catalog? Where can I read how to do this? I searched the documentation for "report server catalog" and couldn't find any hits. Is this another extension?|||

"Report Server Catalog" refers to the report server metadata database.

In report manager, you can upload reports and you can upload other files, for instance Word documents. You could then add hyperlinks to reports to link to these Word documents stored on the report server (in the metadata database), but you cannot directly embed these documents within reports.

-- Robert

|||Oh, sure! I have already uploaded PDFs, I thought it was something different. Thank you for the clarification!

Saturday, February 25, 2012

Displaying a word document via Reporting Services?

Does anyone know a way to (given a path to the file) display a word document via a reporting services report?

Thanks

This is not possible out-of-the-box. You could implement a custom renderer to do this.

You can publish Word documents into the Report Server catalog and browse them, though, you just can't embed them in reports.

|||I'm not sure what you mean by Report Server Catalog? Where can I read how to do this? I searched the documentation for "report server catalog" and couldn't find any hits. Is this another extension?|||

"Report Server Catalog" refers to the report server metadata database.

In report manager, you can upload reports and you can upload other files, for instance Word documents. You could then add hyperlinks to reports to link to these Word documents stored on the report server (in the metadata database), but you cannot directly embed these documents within reports.

-- Robert

|||Oh, sure! I have already uploaded PDFs, I thought it was something different. Thank you for the clarification!

Displaying a custom and dynamic RTF oder HTML text

Hi,
I need to display a formatted text in the reports. Could be HTML, Word-Doc
or RTF or something else.
The text can be stored as file or in the database.
How I can do this with Reprting Services?
Thanks
EricCurrent Versions of RS does not support HTML or other formatted display
styles... Future releases will support HTML...
You might be able to create a custom control which displays rich text, but
since I have never done that - I can't offer any information as to the
difficulty...
--
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"Eric" <jug@.nospam.nospam> wrote in message
news:O1kBPY7ZFHA.3784@.TK2MSFTNGP12.phx.gbl...
> Hi,
> I need to display a formatted text in the reports. Could be HTML, Word-Doc
> or RTF or something else.
> The text can be stored as file or in the database.
> How I can do this with Reprting Services?
>
> Thanks
> Eric
>|||do you have information on which of the future versions will actually
support HTML? I have seen a chat record on techNet about release of
msSQL2005 and it said that HTML will not be supported in 2005 that is coming
this summer, will be it supported in 2005 sp1?
thanks,
Alexander.
"Wayne Snyder" <wayne.nospam.snyder@.mariner-usa.com> wrote in message
news:ueNRsF8ZFHA.3224@.TK2MSFTNGP10.phx.gbl...
> Current Versions of RS does not support HTML or other formatted display
> styles... Future releases will support HTML...|||Hi Alexander,
I have consulted this with development team, unfortunately, no
out-of-the-box rendering extension for word/RTF formats at this time.
Sincerely yours,
Michael Cheng
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
=====================================================
This posting is provided "AS IS" with no warranties, and confers no rights.

Display tiff in Reporting Services

I have a file directory of tiff images that I need to display dynamically with reporting services. I receive the following error message: "The value of the MIMEType property for the image ‘image1’ is “image/tiff”, which is not a valid MIMEType." After looking it up sure enough tiff is not a valide type. Does anyone know of a way to display tiff images in reporting services.

Thanks,

Ross

Well I see plenty of threads on tiffs in the forums so it must be possible. I'm not sure why you're getting the error though.|||Not sure what your situation is, but one way to display a *.tif file in reporting services is to drag the image tool from the report items onto the canvas and select "Web" from the radio boxes options. Reference your url http://localhost/images/yourTIFname.tif. As far as doing this dynamically, I'm unclear as to what it is that your actually trying to do and why you want to do this in reporting services in the first place as apposed to some other means. There are a lot of easier ways to display images, instead of using reporting services to do this.|||I currently have it set to web however the images are not on a web server. I have to access them via a file path file:\\servername\image\1234.tif. The image tool in reporting services does not support the *.tif format. Is there a way to work around this limitation?|||

I wasn't able to find a solution. I'll have to force the users to publish their CADs in another format. If someone finds a solution in the future to display tiff images in ssrs please post it here for others to see.

Thanks,

Ross

|||

Pardon me. The image control in a report does support TIF.

Could these be multi-page TIFFs by any chance? I guess those might not be supported.

>L<

Display tiff in Reporting Services

I have a file directory of tiff images that I need to display dynamically with reporting services. I receive the following error message: "The value of the MIMEType property for the image ‘image1’ is “image/tiff”, which is not a valid MIMEType." After looking it up sure enough tiff is not a valide type. Does anyone know of a way to display tiff images in reporting services.

Thanks,

Ross

Well I see plenty of threads on tiffs in the forums so it must be possible. I'm not sure why you're getting the error though.|||Not sure what your situation is, but one way to display a *.tif file in reporting services is to drag the image tool from the report items onto the canvas and select "Web" from the radio boxes options. Reference your url http://localhost/images/yourTIFname.tif. As far as doing this dynamically, I'm unclear as to what it is that your actually trying to do and why you want to do this in reporting services in the first place as apposed to some other means. There are a lot of easier ways to display images, instead of using reporting services to do this.|||I currently have it set to web however the images are not on a web server. I have to access them via a file path file:\\servername\image\1234.tif. The image tool in reporting services does not support the *.tif format. Is there a way to work around this limitation?|||

I wasn't able to find a solution. I'll have to force the users to publish their CADs in another format. If someone finds a solution in the future to display tiff images in ssrs please post it here for others to see.

Thanks,

Ross

|||

Pardon me. The image control in a report does support TIF.

Could these be multi-page TIFFs by any chance? I guess those might not be supported.

>L<

Friday, February 24, 2012

display sql datas in xml file with stylesheet

hi,
can any one help me in displaying my sql database datas in an xml file and apply stylesheet to that displayed content.

thanks in advance...You have to learn how to write queries with
FOR XML EXPLICIT close.

Read this article for starters.

http://www.topxml.com/sql/for_xml_explicit.asp

Sunday, February 19, 2012

Display picture in crystal report

i have a picture field in an ms access database and i have problem displaying the picture in crystal report. it shows the name of the file in the field instead of the picture itself.Did you store only filepath or the image itself?
If it is file path then it wont work. You need to save the image itself to the table

Friday, February 17, 2012

Display NULL as BLANK ?

I am new to SQL Server 2005. When I choose "Results to File" for a query,
I find that fields with NULL value is displayed as "NULL" string. In SQL
Server 2000, NULL value is displayed as BLANK.
Is there any option in Management Studio to be set up so that NULL value can
be exported as BLANK ?
If not, what is the best way to handle it (End users expect that NULL string
should not be displayed) ?
ThanksPeter
Are you sure? I have a table with column defined as smallint and allows
NULLS. I got NULL on both SQL 2000 (SP3) and SQL Server 2005 (SP2)
"Peter" <Peter@.discussions.microsoft.com> wrote in message
news:O3CWN6YsHHA.1416@.TK2MSFTNGP06.phx.gbl...
>I am new to SQL Server 2005. When I choose "Results to File" for a query,
> I find that fields with NULL value is displayed as "NULL" string. In SQL
> Server 2000, NULL value is displayed as BLANK.
> Is there any option in Management Studio to be set up so that NULL value
> can
> be exported as BLANK ?
> If not, what is the best way to handle it (End users expect that NULL
> string
> should not be displayed) ?
> Thanks
>|||Not sure of a setting that controls this of the top of my head, however, you
could try something like this...
declare @.var varchar(10)
select @.var = NULL
select case when @.var IS NULL then '' else @.var end
Immy
"Peter" <Peter@.discussions.microsoft.com> wrote in message
news:O3CWN6YsHHA.1416@.TK2MSFTNGP06.phx.gbl...
>I am new to SQL Server 2005. When I choose "Results to File" for a query,
> I find that fields with NULL value is displayed as "NULL" string. In SQL
> Server 2000, NULL value is displayed as BLANK.
> Is there any option in Management Studio to be set up so that NULL value
> can
> be exported as BLANK ?
> If not, what is the best way to handle it (End users expect that NULL
> string
> should not be displayed) ?
> Thanks
>|||Dear Uri,
With SQL Server 2000 Query Analyser (SP4), I run the same query and choose
"Result to file", NULL value is shown as BLANK.
On the other hand, when I use Management Studio (SP2) today, I really get
NULL as string.
Peter
"Uri Dimant" <urid@.iscar.co.il> wrote in message
news:eLLbzLZsHHA.1168@.TK2MSFTNGP02.phx.gbl...
> Peter
> Are you sure? I have a table with column defined as smallint and allows
> NULLS. I got NULL on both SQL 2000 (SP3) and SQL Server 2005 (SP2)
>
>
> "Peter" <Peter@.discussions.microsoft.com> wrote in message
> news:O3CWN6YsHHA.1416@.TK2MSFTNGP06.phx.gbl...
>|||Or, shorten it down to ISNULL or COLAESCE:
SELECT ISNULL(colname, ''), ...
SELECT COALESCE(colname, ''), ...
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"Immy" <therealasianbabe@.hotmail.com> wrote in message
news:%23fhkAPZsHHA.3640@.TK2MSFTNGP05.phx.gbl...
> Not sure of a setting that controls this of the top of my head, however, y
ou could try something
> like this...
> declare @.var varchar(10)
> select @.var = NULL
> select case when @.var IS NULL then '' else @.var end
> Immy
> "Peter" <Peter@.discussions.microsoft.com> wrote in message
> news:O3CWN6YsHHA.1416@.TK2MSFTNGP06.phx.gbl...
>|||and that version too ;)
"Tibor Karaszi" <tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote in
message news:2DF5290B-A646-4C6D-A85B-23EB5C6B6851@.microsoft.com...
> Or, shorten it down to ISNULL or COLAESCE:
> SELECT ISNULL(colname, ''), ...
> SELECT COALESCE(colname, ''), ...
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "Immy" <therealasianbabe@.hotmail.com> wrote in message
> news:%23fhkAPZsHHA.3640@.TK2MSFTNGP05.phx.gbl...
>|||Dear Tibor / Immy,
Many thanks for your advice.
Peter
"Tibor Karaszi" <tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote in
message news:2DF5290B-A646-4C6D-A85B-23EB5C6B6851@.microsoft.com...
> Or, shorten it down to ISNULL or COLAESCE:
> SELECT ISNULL(colname, ''), ...
> SELECT COALESCE(colname, ''), ...
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "Immy" <therealasianbabe@.hotmail.com> wrote in message
> news:%23fhkAPZsHHA.3640@.TK2MSFTNGP05.phx.gbl...
>

Display NULL as BLANK ?

I am new to SQL Server 2005. When I choose "Results to File" for a query,
I find that fields with NULL value is displayed as "NULL" string. In SQL
Server 2000, NULL value is displayed as BLANK.
Is there any option in Management Studio to be set up so that NULL value can
be exported as BLANK ?
If not, what is the best way to handle it (End users expect that NULL string
should not be displayed) ?
ThanksPeter
Are you sure? I have a table with column defined as smallint and allows
NULLS. I got NULL on both SQL 2000 (SP3) and SQL Server 2005 (SP2)
"Peter" <Peter@.discussions.microsoft.com> wrote in message
news:O3CWN6YsHHA.1416@.TK2MSFTNGP06.phx.gbl...
>I am new to SQL Server 2005. When I choose "Results to File" for a query,
> I find that fields with NULL value is displayed as "NULL" string. In SQL
> Server 2000, NULL value is displayed as BLANK.
> Is there any option in Management Studio to be set up so that NULL value
> can
> be exported as BLANK ?
> If not, what is the best way to handle it (End users expect that NULL
> string
> should not be displayed) ?
> Thanks
>|||Not sure of a setting that controls this of the top of my head, however, you
could try something like this...
declare @.var varchar(10)
select @.var = NULL
select case when @.var IS NULL then '' else @.var end
Immy
"Peter" <Peter@.discussions.microsoft.com> wrote in message
news:O3CWN6YsHHA.1416@.TK2MSFTNGP06.phx.gbl...
>I am new to SQL Server 2005. When I choose "Results to File" for a query,
> I find that fields with NULL value is displayed as "NULL" string. In SQL
> Server 2000, NULL value is displayed as BLANK.
> Is there any option in Management Studio to be set up so that NULL value
> can
> be exported as BLANK ?
> If not, what is the best way to handle it (End users expect that NULL
> string
> should not be displayed) ?
> Thanks
>|||Dear Uri,
With SQL Server 2000 Query Analyser (SP4), I run the same query and choose
"Result to file", NULL value is shown as BLANK.
On the other hand, when I use Management Studio (SP2) today, I really get
NULL as string.
Peter
"Uri Dimant" <urid@.iscar.co.il> wrote in message
news:eLLbzLZsHHA.1168@.TK2MSFTNGP02.phx.gbl...
> Peter
> Are you sure? I have a table with column defined as smallint and allows
> NULLS. I got NULL on both SQL 2000 (SP3) and SQL Server 2005 (SP2)
>
>
> "Peter" <Peter@.discussions.microsoft.com> wrote in message
> news:O3CWN6YsHHA.1416@.TK2MSFTNGP06.phx.gbl...
>>I am new to SQL Server 2005. When I choose "Results to File" for a
>>query,
>> I find that fields with NULL value is displayed as "NULL" string. In SQL
>> Server 2000, NULL value is displayed as BLANK.
>> Is there any option in Management Studio to be set up so that NULL value
>> can
>> be exported as BLANK ?
>> If not, what is the best way to handle it (End users expect that NULL
>> string
>> should not be displayed) ?
>> Thanks
>>
>|||Or, shorten it down to ISNULL or COLAESCE:
SELECT ISNULL(colname, ''), ...
SELECT COALESCE(colname, ''), ...
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"Immy" <therealasianbabe@.hotmail.com> wrote in message
news:%23fhkAPZsHHA.3640@.TK2MSFTNGP05.phx.gbl...
> Not sure of a setting that controls this of the top of my head, however, you could try something
> like this...
> declare @.var varchar(10)
> select @.var = NULL
> select case when @.var IS NULL then '' else @.var end
> Immy
> "Peter" <Peter@.discussions.microsoft.com> wrote in message
> news:O3CWN6YsHHA.1416@.TK2MSFTNGP06.phx.gbl...
>>I am new to SQL Server 2005. When I choose "Results to File" for a query,
>> I find that fields with NULL value is displayed as "NULL" string. In SQL
>> Server 2000, NULL value is displayed as BLANK.
>> Is there any option in Management Studio to be set up so that NULL value can
>> be exported as BLANK ?
>> If not, what is the best way to handle it (End users expect that NULL string
>> should not be displayed) ?
>> Thanks
>>
>|||and that version too ;)
"Tibor Karaszi" <tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote in
message news:2DF5290B-A646-4C6D-A85B-23EB5C6B6851@.microsoft.com...
> Or, shorten it down to ISNULL or COLAESCE:
> SELECT ISNULL(colname, ''), ...
> SELECT COALESCE(colname, ''), ...
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "Immy" <therealasianbabe@.hotmail.com> wrote in message
> news:%23fhkAPZsHHA.3640@.TK2MSFTNGP05.phx.gbl...
>> Not sure of a setting that controls this of the top of my head, however,
>> you could try something like this...
>> declare @.var varchar(10)
>> select @.var = NULL
>> select case when @.var IS NULL then '' else @.var end
>> Immy
>> "Peter" <Peter@.discussions.microsoft.com> wrote in message
>> news:O3CWN6YsHHA.1416@.TK2MSFTNGP06.phx.gbl...
>>I am new to SQL Server 2005. When I choose "Results to File" for a
>>query,
>> I find that fields with NULL value is displayed as "NULL" string. In
>> SQL
>> Server 2000, NULL value is displayed as BLANK.
>> Is there any option in Management Studio to be set up so that NULL value
>> can
>> be exported as BLANK ?
>> If not, what is the best way to handle it (End users expect that NULL
>> string
>> should not be displayed) ?
>> Thanks
>>
>>
>|||Dear Tibor / Immy,
Many thanks for your advice.
Peter
"Tibor Karaszi" <tibor_please.no.email_karaszi@.hotmail.nomail.com> wrote in
message news:2DF5290B-A646-4C6D-A85B-23EB5C6B6851@.microsoft.com...
> Or, shorten it down to ISNULL or COLAESCE:
> SELECT ISNULL(colname, ''), ...
> SELECT COALESCE(colname, ''), ...
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "Immy" <therealasianbabe@.hotmail.com> wrote in message
> news:%23fhkAPZsHHA.3640@.TK2MSFTNGP05.phx.gbl...
>> Not sure of a setting that controls this of the top of my head, however,
>> you could try something like this...
>> declare @.var varchar(10)
>> select @.var = NULL
>> select case when @.var IS NULL then '' else @.var end
>> Immy
>> "Peter" <Peter@.discussions.microsoft.com> wrote in message
>> news:O3CWN6YsHHA.1416@.TK2MSFTNGP06.phx.gbl...
>>I am new to SQL Server 2005. When I choose "Results to File" for a
>>query,
>> I find that fields with NULL value is displayed as "NULL" string. In
>> SQL
>> Server 2000, NULL value is displayed as BLANK.
>> Is there any option in Management Studio to be set up so that NULL value
>> can
>> be exported as BLANK ?
>> If not, what is the best way to handle it (End users expect that NULL
>> string
>> should not be displayed) ?
>> Thanks
>>
>>
>

display msgbox in browser

hi..

i have the following embedded code in my rdl file..

Function validateDate (ByVal startDt as datetime, ByVal endDt as datetime)

if (startDt > endDt)
System.Windows.Forms.MessageBox.Show("Date Range From must be earlier or the same as Date Range To")
End if

End function

this code works in VS IDE but the msgbox would not appear when view using a browser...

how can i get the msgbox to appear when view using a browser?

thanksss

Code execution will happen at the server, not at the client. Client only receives the output of the renderer. The MessageBox might be showing up at the server, but that doesn't help the client.

There is no good way to cause such a dialog to display at the client.

|||

thanks mike for your reply. is there any workabout to this?

is there any error handling i can do to alert the users?

thanks!

Display images ...

Hello,
I have a customstrings.xml file containing the following:
<string id="sidContactDisplayFormat">{0} - {1} - {2}</string>
<string
id="sidContactFormatFields">contact_name,contact_p hone,contact_vip_flag</string>
In the ascx file I have:
DataStore("ContactsQuickFind").SetCustomColumn("co ntact_display",
"sidContactDisplayFormat", "sidContactFormatFields", "sidContactEmptyString")
which is using the field referenced in the customstring file.
then the display is done through a dropdownlist:
<aw:DropdownList ID="ddlContactQuickFind" RunAt="server"
PreserveItems="true" DataBindMode="GetData"
DataSourceName="ContactsQuickFind" DataTextField="contact_display"
DataValueField="contact_id" ItemDataSourceName="Contact"
ItemDataField="contact_id" OnSelectedIndexChanged="DoContinue"
AutoPostBack="true" Width="300">
<asp:ListItem Value="1">sidNoneDecorated</asp:ListItem>
<asp:ListItem Value="0">sidSelectResultCount</asp:ListItem>
</aw:DropdownList>
My question is I want to display the VIP flag instead of the file value in
the display:
<img src="http://pics.10026.com/?src=http://altiris3/AeXHD/images/icnVIP.gif" />
How can I do this?
Thanks
Dominique
I think you got the wrong newsgroup here... this has nothing to do with xml
and databases.
You may want to try one of the more generic xml groups.
Best regards
Michael
"Dominique" <Dominique@.discussions.microsoft.com> wrote in message
news:4C6C5A88-65C1-4A43-8996-4B2846ED0975@.microsoft.com...
> Hello,
> I have a customstrings.xml file containing the following:
> <string id="sidContactDisplayFormat">{0} - {1} - {2}</string>
> <string
> id="sidContactFormatFields">contact_name,contact_p hone,contact_vip_flag</string>
> In the ascx file I have:
> DataStore("ContactsQuickFind").SetCustomColumn("co ntact_display",
> "sidContactDisplayFormat", "sidContactFormatFields",
> "sidContactEmptyString")
> which is using the field referenced in the customstring file.
> then the display is done through a dropdownlist:
> <aw:DropdownList ID="ddlContactQuickFind" RunAt="server"
> PreserveItems="true" DataBindMode="GetData"
> DataSourceName="ContactsQuickFind" DataTextField="contact_display"
> DataValueField="contact_id" ItemDataSourceName="Contact"
> ItemDataField="contact_id" OnSelectedIndexChanged="DoContinue"
> AutoPostBack="true" Width="300">
> <asp:ListItem Value="1">sidNoneDecorated</asp:ListItem>
> <asp:ListItem Value="0">sidSelectResultCount</asp:ListItem>
> </aw:DropdownList>
> My question is I want to display the VIP flag instead of the file value in
> the display:
> <img src="http://pics.10026.com/?src=http://altiris3/AeXHD/images/icnVIP.gif" />
> How can I do this?
> Thanks
> --
> Dominique
|||thanks
Dominique
"Michael Rys [MSFT]" wrote:

> I think you got the wrong newsgroup here... this has nothing to do with xml
> and databases.
> You may want to try one of the more generic xml groups.
> Best regards
> Michael
> "Dominique" <Dominique@.discussions.microsoft.com> wrote in message
> news:4C6C5A88-65C1-4A43-8996-4B2846ED0975@.microsoft.com...
>
>

Display images ...

Hello,
I have a customstrings.xml file containing the following:
<string id="sidContactDisplayFormat">{0} - {1} - {2}</string>
<string
id="sidContactFormatFields"> contact_name,contact_phone,contact_vip_f
lag</str
ing>
In the ascx file I have:
DataStore("ContactsQuickFind").SetCustomColumn("contact_display",
"sidContactDisplayFormat", "sidContactFormatFields", "sidContactEmptyString"
)
which is using the field referenced in the customstring file.
then the display is done through a dropdownlist:
<aw:DropdownList ID="ddlContactQuickFind" RunAt="server"
PreserveItems="true" DataBindMode="GetData"
DataSourceName="ContactsQuickFind" DataTextField="contact_display"
DataValueField="contact_id" ItemDataSourceName="Contact"
ItemDataField="contact_id" OnSelectedIndexChanged="DoContinue"
AutoPostBack="true" Width="300">
<asp:ListItem Value="1">sidNoneDecorated</asp:ListItem>
<asp:ListItem Value="0">sidSelectResultCount</asp:ListItem>
</aw:DropdownList>
My question is I want to display the VIP flag instead of the file value in
the display:
<img src="http://pics.10026.com/?src=http://altiris3/AeXHD/images/icnVIP.gif" />
How can I do this?
Thanks
--
DominiqueI think you got the wrong newsgroup here... this has nothing to do with xml
and databases.
You may want to try one of the more generic xml groups.
Best regards
Michael
"Dominique" <Dominique@.discussions.microsoft.com> wrote in message
news:4C6C5A88-65C1-4A43-8996-4B2846ED0975@.microsoft.com...
> Hello,
> I have a customstrings.xml file containing the following:
> <string id="sidContactDisplayFormat">{0} - {1} - {2}</string>
> <string
> id="sidContactFormatFields"> contact_name,contact_phone,contact_vip_f
lag</s
tring>
> In the ascx file I have:
> DataStore("ContactsQuickFind").SetCustomColumn("contact_display",
> "sidContactDisplayFormat", "sidContactFormatFields",
> "sidContactEmptyString")
> which is using the field referenced in the customstring file.
> then the display is done through a dropdownlist:
> <aw:DropdownList ID="ddlContactQuickFind" RunAt="server"
> PreserveItems="true" DataBindMode="GetData"
> DataSourceName="ContactsQuickFind" DataTextField="contact_display"
> DataValueField="contact_id" ItemDataSourceName="Contact"
> ItemDataField="contact_id" OnSelectedIndexChanged="DoContinue"
> AutoPostBack="true" Width="300">
> <asp:ListItem Value="1">sidNoneDecorated</asp:ListItem>
> <asp:ListItem Value="0">sidSelectResultCount</asp:ListItem>
> </aw:DropdownList>
> My question is I want to display the VIP flag instead of the file value in
> the display:
> <img src="http://pics.10026.com/?src=http://altiris3/AeXHD/images/icnVIP.gif" />
> How can I do this?
> Thanks
> --
> Dominique|||thanks
--
Dominique
"Michael Rys [MSFT]" wrote:

> I think you got the wrong newsgroup here... this has nothing to do with xm
l
> and databases.
> You may want to try one of the more generic xml groups.
> Best regards
> Michael
> "Dominique" <Dominique@.discussions.microsoft.com> wrote in message
> news:4C6C5A88-65C1-4A43-8996-4B2846ED0975@.microsoft.com...
>
>