HyperLink column datagrid

A

aspnetpal

Hi every1, I have a hyperlink column in the datagrid and it is working
fine.
This column is also a primary key for that table.

Problem on hand:
When user click on a particular value (row) in that column a new window
should open as a MS Word document (since that record should refer to
that document).

What I have so far is this.
When user clicks on the link a new window opens as a windows explorer.
What I want to do is this when user clicks on it, then it should open
up that document. The document name should be primarykey.doc
For example,

Hyperlink column = 1019

Document Name = 1019.doc

Currently all documents located on local drive & I'm thinking to move
them to webserver.

Any suggestion would be highly appreciated.

Thanks
 
R

Riki

aspnetpal said:
Hi every1, I have a hyperlink column in the datagrid and it is working
fine.
This column is also a primary key for that table.

Problem on hand:
When user click on a particular value (row) in that column a new
window should open as a MS Word document (since that record should
refer to that document).

What I have so far is this.
When user clicks on the link a new window opens as a windows explorer.
What I want to do is this when user clicks on it, then it should open
up that document. The document name should be primarykey.doc
For example,

Hyperlink column = 1019

Document Name = 1019.doc

Currently all documents located on local drive & I'm thinking to move
them to webserver.

Any suggestion would be highly appreciated.

Just set these properties for the hyperlink column:
DataNavigateUrlFormatString="{0}.doc"
Target="_blank"

That's it.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,230
Members
46,819
Latest member
masterdaster

Latest Threads

Top