|
Hi i am using some links in one of my form...,
Those links i want in all my other forms too...,
I dont like to give each and every forms those links...,
So i like to give those links in some javascript....,
To call that javascript in all forms that links want to be come there...,
Its possible?,
This is my code:(That Inside "div" things want to come in script)
How to do that,Plz help me...,
<form id="clock" method="post" runat="server">
<div class="horizontalcssmenu">
<TABLE id="Table1" style="Z-INDEX: 103; LEFT: 8px; POSITION: absolute; TOP: 136px; HEIGHT: 15px"
width="700" bgColor="#cde686" border="0">
<TR>
<TD style="WIDTH: 836px">
<ul id="cssmenu1">
<li style="LEFT: 4px; BORDER-LEFT: #202020 1px solid; WIDTH: 144px; TOP: 0px; HEIGHT: 1%">
<A style="WIDTH: 160px; HEIGHT: 1%" href="default.aspx">Master</A>
<ul style="LEFT: 0px; TOP: 0px">
<li>
<A href="frmCompanyMasterDetails.aspx">Master Company</A>
</li>
<li>
<A href="frmProjectMaster.aspx">Master Project</A>
</li>
<li>
<A href="frmprojectrpt.aspx">Report</A>
</li>
</ul>
</li>
<li>
<A href="Login.aspx">LogOut</A>
</li>
</ul>
<br style="CLEAR: left">
</TD>
</TR>
</TABLE>
</div>
<asp:hyperlink id="hplchequeissued" style="Z-INDEX: 102; LEFT: 992px; POSITION: absolute; TOP: 328px" runat="server" ForeColor="Indigo" Width="96px" Height="24px" NavigateUrl="frmChequeissuedstatement.aspx" Visible="False">Cheque Issued</asp:hyperlink>
</form>
Regards,
Magi
|
|
|
|
|
It's possible, but why would you want to use Javascript for that?
Just put the menu in a user control.
---
single minded; short sighted; long gone;
|
|
|
|
|
Hi Mr.Guffa,
I need it in script only...,
Becoz The links will come inside the and - tag...,
Regards,
Magi
|
|
|
|
|
Hi all
In a data grid i have two such columns where it acts as a link to a different page. But problem is since i have two response.redirect statements its executing the first one only. My condition is after redirecting to different page i am populating that page with some details( example if i am clicking on cand id 1 then in the next page detail will of cand whose id is 1) so i am using session varible. The code what wrote is
If (......I want the condition.....) Then
lbCand_Id = e.Item.FindControl("Label5")
Session("CAND_ID") = lbCand_Id.Text
Response.Redirect("Update_Feedback.aspx")
Else
lbCand_Id1 = e.Item.FindControl("Label1")
Session("Cand_ID1") = lbCand_Id1.Text
Response.Redirect("Summary.aspx")
End If
Pl tel me in if condition what i have to write like datagrid1.item... something like that.so that i can execute both the conditions.
Thanks and Regards
Prakash Mishra(Banglore,India)
|
|
|
|
|
Hi in datagrid template column u have the hyper link or outside the grid u have?,
If inside the grid u have the hyperlink,then u can access the link using this code:
For Each MainGRD As DataGridItem In Me.dgrdmain.Items
dim Candid as HyperLink=ctype(maingrd.FindControl("Idofhyperlink"),HyperLink)
Next
Here candid is the hyperlink now...,
U can use ur if condition based on that candid...,
Did u got it?,
Regards,
Magi
|
|
|
|
|
hi magi
I already wrote the code its working fine my problem is i want to write a condition (if else)so that i can execute my code, Pl see the code in post.
So just tell me the if condition. Like suppose i click on the 1 column of the grid some thing like this( datagrid1.item.....)
Regards
Prakash Mishra(Banglore,India)
|
|
|
|
|
Hi i think this is ur probs...,
In datagrid ur displaying the candidate id and his photo...,
Based on the candi id selection it want to open another child window and show his details ?,
If its yes...,
Use this way,.
In ur datagrid property bulder select the hyperlink column and there u can see "Url format string", There give some other aspx page form and ur passing parameter...,
Means it should eb like this:
frmCashflowStatementLink.aspx?candid={0}
Then there itself see the "target" dropdown box there u select "-new"
Then Go to that child page(for me i have taken this one frmCashflowStatementLink.aspx)
In ur pageload not postback method give this code:
txtLinkID.Text = Request.QueryString("candid")
Then in ur sqladapater query u check with that txtlinkid value...,
If its correct display those values like...,
This only u asked na?,
Regards,
Magi
|
|
|
|
|
Hi magi i just asked the IF condition in vb for the data grid
eg
if( first column is selected)
do some thing
else
do some thing
I want to know in the bracket what i have to write, any r u form bangalore?
Regards
Prakash Mishra(Banglore,India)
|
|
|
|
|
.
why didnt u can use query string for passing candid?
In datagrid , create a template column with hyper link
like
<<code> <asp:TemplateColumn HeaderText="News Heading">
<HeaderStyle HorizontalAlign="Center"></HeaderStyle>
<ItemStyle Width="35%"></ItemStyle>
<ItemTemplate>
<asp:HyperLink Runat =server CssClass=Newslink NavigateUrl ='<%#GetURL(DataBinder.Eval(Container.DataItem, "NewsId").ToString())%>' ID="Hyperlink1">
<%#DataBinder.Eval(Container.DataItem, "NewsHeading")%>
</asp:HyperLink>
</ItemTemplate>
</asp:TemplateColumn>
</code> >
in c#
<br />
protected string GetURL (string fldval ) <br />
<br />
{ <br />
<br />
string SzOpenwindow="";<br />
<br />
<br />
SzOpenwindow="javascript:openMywindow('yourpage1.aspx?&id="+ fldval +"','View',500,320)";<br />
<br />
return SzOpenwindow; <br />
<br />
}<br />
writa js
function openMywindow(url,name,iWidth,iHeight)
{
var iLeft = (screen.availWidth-500 - iWidth/ 2);
var iTop = (screen.availHeight-420 - iHeight / 2);
var features;
var objwindow;
features = "width="+iWidth+",height="+iHeight+",left="+iLeft+",top="+iTop;
features += ",screenX="+iLeft+",screenY="+iTop;
features += ",scrollbars=1,resizable=0,location=0";
features += ",menubar=0,toolbar=0,status=0";
objwindow = window.open(url,name, features);
}
All I ever wanted is what others have.... CrazySanker
|
|
|
|
|
Give command name property to both link.
Like as for link1 CommandName="Link1"
and link2 CommandnName="Link2"
Now U can use If condition on GridView rowcommand event
If(commandName=="Link1")
{
//code is here for link1
}
else if(commandName=="Link2")
{
//code is here for link2
}
Best Regard
Pathan
---------------------------------------------------
|
|
|
|
|
Hi,
FileUpload control is not working in Mac PC. It is working fine in Windows PC.
Please let me know how to resolve it in Mac.
Thanks!!
Jagadeesh
-- modified at 1:48 Saturday 28th July, 2007
|
|
|
|
|
Define 'not working' ? Have you looked to see what HTML is being generated for the Mac browser ?
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Hi Christian,
The HTML is same on Mac and Windows.
But it is not working on Mac.
Plz Help.
Regards,
~Jagadeesh
|
|
|
|
|
Then the problem is the Mac browser sucks. Not much you can do about that.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Standard question #1:
What do you mean by "not working"?
Unless you explain what's happening, there is no information that points to any possible reasons for the problem.
---
single minded; short sighted; long gone;
|
|
|
|
|
Hi.
In ASP3.0 (Not ASP.Net), I can't run a page that has DB connection!
It must be uploaded on server and then I can test that page?
Locally on my computer I can't test these pages that work with DB?
I use Windows vista.
Best wishes
|
|
|
|
|
Huh?
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
I guess the two questions are ,why are you using ASP, and why are you asking in the ASP.NET forum ?
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
1. It's a practice in a class
2. there is no forum for ASP3 here
3. If you can't help, don't post anything, please!
Best wishes
|
|
|
|
|
1 - any class that wanted to teach me asp in 2007, I would drop immediately, and let the teacher know they are stupid. No-one uses that rubbish anymore, unless it's legacy apps.
2 - There is a web development forum for outdated technologies such as ASP and PHP
3 - actually, you're far more likely to get help if you post in the right place, so I *am* helping.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
hi all
I want to create a web form.In this form I have a data Grid(GridView1). This grid view contains some rows that fetch from a table of a database.I want to insert a button at the last column of each row, This button must update a row which selected which but I don't know how to insert this button and how to write click event for each button
|
|
|
|
|
Hi,
I'm wondering,did u mean that u want a button each row in last column, and u want that event button able to update value on row selected?
maybe u can checked the enable edit checkBox on u're gridview and set the properties to a button..so when the edit button pressed it allow user to change/update value on the selected row
Hope that answer u're question
Regards,
Tomi
|
|
|
|
|
Yeah I mean a button each row in last column, and I want when user click each button update value on selected row, but I don't know how to reach this goal.I use auto format of data grid(VS 2005)but I don't know how to set.
|
|
|
|
|
1.First expand properties of data grid (little arrow on top right corner) it will show some properties like : auto format, etc..
2. find the checked box at that properties (enable editing, enable deleting, enable select, and etc..)
3. checked the checkbox which enable editing..and maybe if u want to enable the other just click the checkbox
4. after u checked the properties, find a link name Edit if u checked the checkbox for enabled the editing, and link Delete if u enable deleting in your data grid..
5. on the runtime that link will allow user to update the data of the selected column
6. if u want to make this link to be a button or naming the link,just change the properties and change it like u want to be
Hope this can help u
Regards,
Tomi
|
|
|
|
|
Hello
this my code:
<asp:repeater id="myRepeater" runat="server">
<headertemplate>
<itemtemplate>
What i try to do is to write in the Label where i put the text: "dddddddddd" to have a real data from a Session or maybe from the same Querry the repeater is fill
Tanks in advance
Assaf <asp:label runat="server" id="LblName" text="dddddddddd"> | Grade Name | Institution Name | <%#DataBinder.Eval(Container.DataItem, "GradeName")%> | <%#DataBinder.Eval(Container.DataItem, "InstitutionName")%> |
|
|
|
|