472,371 Members | 1,585 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,371 software developers and data experts.

linklabel, javascript and C Sharp

Is it possible to use javascript within a link label link in C#?

I want to call up a web page from a link label but without any scroll
bars and have it a certain size. I am trying to use the
javascript:window.open

this.lbtnArrangeColumns.Links[0].LinkData =
"javascript:window.open('http://localhost/Test.aspx','access','width=600px,height=550px,scro llbars=no')";

private void Test(object sender,
System.Windows.Forms.LinkLabelLinkClickedEventArgs e)
{

System.Diagnostics.Process.Start(e.Link.LinkData.T oString());
}

However it opens a browser window with [Object] in it and then opens
my smaller custom window. Can any one tell me how to prevent it
opening the first browser window.

Thanks,

np
Nov 15 '05 #1
1 2027
I have tried this for some of my links, unfortuantely there is a piece
of functionality where I need process start to open the small window
as no link label is used.

Also were you able to superimpose the hyperlink over the winform
control so that it looks like it is part of the winform? I tried
messing about with Z-index but no good the winform is always in the
foreground so you can't see the hyperlink

Thanks in Advance,

Nick

"Sunil TG" <tg*****@hotmail.com> wrote in message news:<05****************************@phx.gbl>...
I too had the same problem. What i did to solve this
problem is, i deleted the server side linklabel, and
placed an ordinary hyperlink, and wrote javascript in the
aspx file, which nicely opened the smaller window.
-----Original Message-----
Is it possible to use javascript within a link label link

in C#?

I want to call up a web page from a link label but

without any scroll
bars and have it a certain size. I am trying to use the
javascript:window.open

this.lbtnArrangeColumns.Links[0].LinkData =
"javascript:window.open

('http://localhost/Test.aspx','access','width=600px,height=
550px,scrollbars=no')";

private void Test(object sender,
System.Windows.Forms.LinkLabelLinkClickedEventArg s e)
{

System.Diagnostics.Process.Start

(e.Link.LinkData.ToString());
}

However it opens a browser window with [Object] in it and

then opens
my smaller custom window. Can any one tell me how to

prevent it
opening the first browser window.

Thanks,

np
.

Nov 15 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: tota | last post by:
i'm using windowsApplication to connect to DB made by SQL i need to Display the Data of the first table in the DB as links when click it it openes a table and i navigte between them using buttons...
1
by: gabe | last post by:
I am looking for a way to mimic some of the functionality of a web page without writing html (or I am looking to someone to point out something really obvious that I am over looking) Currently I...
3
by: vince | last post by:
Hello, I have a ListBox filled with many lines of simply text I want to make few lines be a LinkLabel How can I do this Thanks
0
by: Suz | last post by:
I am stumped! I can't seem to figure out how to put a linklabel in a datagrid on a windows form. I have working code that displays a linklabel in edit mode but need the linklabel to display during...
1
by: Marcus Kwok | last post by:
I am having problems getting my LinkLabel hyperlink to work properly. Every time I click on it, I get the following exception: System.ComponentModel.Win32Exception: The requested lookup key was...
2
by: Terrance | last post by:
Can someone please help with a problem that I'm having? I'm trying to create a linklabel in VB.NET 2003 at runtime when a user clicks a button. The app looks in a path for .doc and .pdf files and...
4
by: David Veeneman | last post by:
I'm creating a UserControl that uses a LinkLabel. For reasons that I won't bore everyone with, I don't want the LinkLable to show the default hand cursor when the mouse enters the control. Should...
3
by: bsturg21 | last post by:
Hello, I have a windows form that has a series of linklabels on it, and I need to have each linklabel, when clicked, open a separate windows form that has a single paramter passed into it. The...
2
by: prokopis | last post by:
am using c# for windows applications. am using dynamic linklayer array to print some labels in the form.i get some data from the database i add them in the linklabel array and i print it on the...
2
by: Kemmylinns12 | last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and efficiency. While initially associated with cryptocurrencies...
0
by: Naresh1 | last post by:
What is WebLogic Admin Training? WebLogic Admin Training is a specialized program designed to equip individuals with the skills and knowledge required to effectively administer and manage Oracle...
0
by: Arjunsri | last post by:
I have a Redshift database that I need to use as an import data source. I have configured the DSN connection using the server, port, database, and credentials and received a successful connection...
1
by: Matthew3360 | last post by:
Hi, I have been trying to connect to a local host using php curl. But I am finding it hard to do this. I am doing the curl get request from my web server and have made sure to enable curl. I get a...
0
Oralloy
by: Oralloy | last post by:
Hello Folks, I am trying to hook up a CPU which I designed using SystemC to I/O pins on an FPGA. My problem (spelled failure) is with the synthesis of my design into a bitstream, not the C++...
0
by: Carina712 | last post by:
Setting background colors for Excel documents can help to improve the visual appeal of the document and make it easier to read and understand. Background colors can be used to highlight important...
1
by: Johno34 | last post by:
I have this click event on my form. It speaks to a Datasheet Subform Private Sub Command260_Click() Dim r As DAO.Recordset Set r = Form_frmABCD.Form.RecordsetClone r.MoveFirst Do If...
1
by: ezappsrUS | last post by:
Hi, I wonder if someone knows where I am going wrong below. I have a continuous form and two labels where only one would be visible depending on the checkbox being checked or not. Below is the...
0
by: jack2019x | last post by:
hello, Is there code or static lib for hook swapchain present? I wanna hook dxgi swapchain present for dx11 and dx9.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.