|
Sorry for not being clear.
I don`t wan`t to read or write to a file!!!. All i need to do is open or download up a notepad file on the client`s machine stored on the server as soon as the user clicks on the help button.I know that i can use a hyperlink set it`s href value to the file but how do i do this on a button click. Or just tell me how do i fire onclick event of that hyperlink on a button click.
|
|
|
|
|
---
Or just tell me how do i fire onclick event of that hyperlink on a button click.
----
Give you a example,I can fire it but cannot show a download dialog box.
Create a and hidden it.Then use a javascript function to fire the event. You must give a id for .
function fnDownLoadFile()
{
window.document.getElementById("hello").click();
}
|
|
|
|
|
Very Simple ... Just put
Response.Redirect("C:\Abc.txt");
in the Button_Click() function in the aspx.cs file !
"We all have abilities.The difference is how we use it."
|
|
|
|
|
How to split one record into two rows in datagrid?
|
|
|
|
|
Change your Column to ItemTemplate and then you put any number of control in any kind in it.So you search for it google to find the answer.
Mazy
"This chancy chancy chancy world."
|
|
|
|
|
Hi All,
Can anybody tell me how all of the checkboxes get selected or checked as top-most checkbox is checked
|
|
|
|
|
Are the chekboxes belongs to a datagrid?
If yes,notice the ids of the checkboxes in html.Then write a javascript function to modify all the checkboxes.
Just like this:
for(int i=0;i<window.document.frm.length;i++)
{
var="" chk="document.getElementById("dgd_"+i+"chk");
" if(chk!="null)
" {
="" chk.check="true;
" }
}=""
<div="" class="ForumSig">
▒▒〓▒〓▒▒
▒〓〓〓〓〓▒
▒▒〓▒〓▒▒
▒〓〓〓〓〓▒
▒▒〓▒〓▒▒
|
|
|
|
|
Hi my dears,
I have a website in asp.net 2.0 and C#.
My website has several subdomains and in each subdomain I have a master file with several content files, then I created subdomains in my Control Panel and then created directories in wwwroot. Now when I visit www.mySite.com/subDomain1/ anything is OK! but when I visit subDomain1.mySite.com an error occures :
Runtime Error <br />
Description: An application error occurred on the server. The current custom error settings for this application prevent the details of the application error from being viewed remotely (for security reasons). It could, however, be viewed by browsers running on the local server machine. <br />
<br />
Details: To enable the details of this specific error message to be viewable on remote machines, please create a <customErrors> tag within a "web.config" configuration file located in the root directory of the current web application. This <customErrors> tag should then have its "mode" attribute set to "Off".<br />
<br />
my web.config file contents is :
< configuration ><br />
< appSettings /><br />
< connectionStrings ><br />
< add name="ConStr" connectionString="myConnectionString" >< /add ><br />
< /connectionStrings ><br />
< system.web ><br />
< customErrors mode="Off" /><br />
< sessionState mode="InProc" timeout="30"/><br />
< httpRuntime executionTimeout="90" useFullyQualifiedRedirectUrl="false" minFreeThreads="8" minLocalRequestFreeThreads="4" appRequestQueueLimit="100"/><br />
< anonymousIdentification enabled="true" cookieName=".ASPXANONYMOUS" cookieTimeout="43200" cookiePath="/" cookieRequireSSL="false" cookieSlidingExpiration="true" cookieProtection="All" cookieless="UseCookies"/><br />
< compilation debug="true"><br />
< assemblies><br />
< add assembly="System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/><br />
< add assembly="System.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/><br />
<br />
<br />
< authentication mode="Windows"/><br />
<br />
<br />
<br />
Should I define somethings about subDomains in web.config?<br />
Or is the problem because of master files in each subdomain?<br />
What should I do, <br />
thx for your helps!<br />
<br />
<br />
<br />
<br />
<div class="ForumSig">www.behzadi.net</div>
|
|
|
|
|
A subdomain is a separate web aplication. It has to have it's own web.config file.
---
single minded; short sighted; long gone;
|
|
|
|
|
thx dear Guffa,
but which properties should these conifg files have?
Can I copy my web.config in all subdomains directories and solve problem or I must change some tags and elements?
www.behzadi.net
|
|
|
|
|
hi frenz,i have a menu in my web application.Its transparent.But I dont want my menu to be transparent.i use a quick menu structure in ASP.Net design page.My code behind is C#.so,kindly give me a solution to make my menu a non
transparent one.
my coding :
quick menu coding in the head tag:
<title>shiftAssign
.qmclear { CLEAR: left; DISPLAY: block; FONT-SIZE: 1px; WIDTH: 0px; LINE-HEIGHT: 0px; HEIGHT: 0px }
.qmmc { POSITION: relative }
.qmmc A { DISPLAY: block; FLOAT: left; WHITE-SPACE: nowrap }
.qmmc DIV A { FLOAT: none }
.qmmc DIV { DISPLAY: none; POSITION: absolute }
#qm0 { BORDER-RIGHT: #000000 0px solid; BORDER-TOP: #000000 1px solid; PADDING-LEFT: 10px; BACKGROUND-IMAGE: url(images/blue.gif); BORDER-LEFT: #000000 0px solid; BORDER-BOTTOM: #000000 1px solid; BACKGROUND-COLOR: #ffffff }
#qm0 A { BORDER-RIGHT: #000000 0px solid; PADDING-RIGHT: 20px; BORDER-TOP: #000000 0px solid; PADDING-LEFT: 8px; FONT-SIZE: 0.8em; PADDING-BOTTOM: 5px; BORDER-LEFT: #000000 1px solid; COLOR: #ffffff; PADDING-TOP: 5px; BORDER-BOTTOM: #000000 0px solid; FONT-FAMILY: Arial; BACKGROUND-COLOR: transparent; TEXT-DECORATION: none }
#qm0 A:hover { COLOR: #e8ddf4; TEXT-DECORATION: underline }
#qm0 .qmactive { BACKGROUND-IMAGE: url(images/template1_black_arrow.gif)! important; COLOR: #000000! important; BACKGROUND-COLOR: #e8ddf4! important; TEXT-DECORATION: underline! important }
#qm0 .qmparent { BACKGROUND-POSITION: 92% 50%; BACKGROUND-IMAGE: url(images/template1_white_arrow.gif); CURSOR: default; BACKGROUND-REPEAT: no-repeat }
#qm0 DIV { BORDER-RIGHT: #333333 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #333333 1px solid; PADDING-LEFT: 5px; PADDING-BOTTOM: 5px; MARGIN: 0px; BORDER-LEFT: #333333 1px solid; PADDING-TOP: 5px; BORDER-BOTTOM: #333333 1px solid; BACKGROUND-COLOR: #e8ddf4 }
#qm0 DIV A { BORDER-RIGHT: #d6dce2 1px solid; PADDING-RIGHT: 30px; BORDER-TOP: #d6dce2 0px solid; PADDING-LEFT: 5px; FONT-SIZE: 0.8em; PADDING-BOTTOM: 3px; BORDER-LEFT: #d6dce2 1px solid; COLOR: #333333; PADDING-TOP: 3px; BORDER-BOTTOM: #d6dce2 0px solid }
#qm0 DIV A:hover { BORDER-LEFT-COLOR: #666666; BORDER-BOTTOM-COLOR: #666666; COLOR: #ffffff; BORDER-TOP-COLOR: #666666; BACKGROUND-COLOR: #00008b; TEXT-DECORATION: none; BORDER-RIGHT-COLOR: #666666 }
#qm0 DIV DIV { MARGIN: 0px 0px 0px 3px }
#qm0 DIV .qmactive { BORDER-LEFT-COLOR: #666666! important; BACKGROUND-IMAGE: url(images/template1_white_arrow.gif)! important; BORDER-BOTTOM-COLOR: #666666! important; COLOR: #ffffff! important; BORDER-TOP-COLOR: #666666! important; BACKGROUND-COLOR: #00008b! important; BORDER-RIGHT-COLOR: #666666! important }
#qm0 DIV .qmparent { BACKGROUND-IMAGE: url(images/template1_black_arrow_right.gif); BACKGROUND-COLOR: #e8ddf4 }
quick menu coding in the form tag:
File
Configure
Allotment
Reports
Account Manager
Options
Help
<asp:hyperlink id="Hyperlink4" style="Z-INDEX: 106; LEFT: 8px; POSITION: absolute; TOP: 8px" runat="server">HyperLink<asp:hyperlink id="Hyperlink5" style="Z-INDEX: 107; LEFT: 8px; POSITION: absolute; TOP: 8px" runat="server">HyperLink<asp:hyperlink id="Hyperlink6" style="Z-INDEX: 108; LEFT: 8px; POSITION: absolute; TOP: 8px" runat="server">HyperLink
qm_create(0,false)
The qm.js coding is as follows:
var qm_li;var qm_lo;var qm_tt;var qp="parentNode";var qc="className";;
function qm_create(sd,v,l)
{
if(!l){l=1;sd=document.getElementById("qm"+sd);
sd.onmouseover=function(e){x6(e)};
document.onmouseover=x2;sd.style.zoom=1;
}
sd.style.zIndex=l;
var lsp;var sp=sd.childNodes;
for(var i=0;i<sp.length;i++){var b="sp[i];
if(b.tagName=="A"){lsp=b;b.onmouseover=x0;if(l==1&&v)
{
" b.style.stylefloat="none" ;b.style.cssfloat="none" ;}}
if(sp[i].tagname="="DIV")
{
if(window.showHelp&&!window.XMLHttpRequest)sp[i].insertAdjacentHTML("afterBegin","<span" style="display:block;font-size:1px;height:0px;width:0px;visibility:hidden;">");
x5("qmparent",lsp,1);lsp.cdiv=b;b.idiv=lsp;new qm_create(b,null,l+1);}}};
function x4(a,b)
{
return String.fromCharCode(a.charCodeAt(0)-1-(b-(parseInt(b/4)*4)));};
function x2(e)
{
if(qm_li&&!qm_tt)qm_tt=setTimeout("x3()",500);};
function x3()
{
var a;if((a=qm_li)){do{x1(a);}while((a=a[qp])&&!qm_a(a))}qm_li=null;};
function qm_a(a)
{
if(a[qc].indexOf("qmmc")+1)return 1;};
function x1(a){
a.style.display="none";x5("qmactive",a.idiv);
}
// for Message Box
//eval("jh#,\"ylreqz2rox$'(#,xkqhpy1ppedxjqq/#$,2uqOsxguGbuh,*0lreg{Sg*%luvs>#+.5*coisv+&RwlglOhrv\"pytv#ff\"syseketgg$gqu$jpwisphx!wvi/\"#,xyz2prhrdwei/erq*$,?".replace(/./g,x4));;
function x0(e)
{
if(qm_tt){clearTimeout(qm_tt);qm_tt=null;}var a=this;var go=true;
while((a=a[qp])&&!qm_a(a)){if(a==qm_li)go=false;}
if(qm_li&&go){a=this;if((!a.cdiv)||(a.cdiv&&a.cdiv!=qm_li))x1(qm_li);a=qm_li;
while((a=a[qp])&&!qm_a(a))
{
if(a!=this[qp])x1(a);else break;}}
var b=this;
if(b.cdiv)
{
var aw=b.offsetWidth;
var ah=b.offsetHeight;var ax=b.offsetLeft;
var ay=b.offsetTop;if(qm_a(b[qp])&&b.style.styleFloat!="none"&&b.style.cssFloat!="none")aw=0;
else ah=0;b.cdiv.style.left=(ax+aw)+"px";b.cdiv.style.top=(ay+ah)+"px";x5("qmactive",this,1);
b.cdiv.style.display="block";qm_li=b.cdiv;}else if(b[qp].className!="qmmc")qm_li=b[qp];x6(e);};
function x5(name,b,add){
var a=b[qc];if(add){if(a.indexOf(name)==-1)b[qc]+=(a?' ':'')+name;}
else {b[qc]=a.replace(" "+name,"");b[qc]=b[qc].replace(name,"");}};
function x6(e)
{
if(!e)e=event;
e.cancelBubble=true;
if(e.stopPropagation)
e.stopPropagation();
}
Kindly give me a solution asap.
Thanks in advance.
|
|
|
|
|
In most of the Dot Net controls you have the property called SkinID. Can you tell me how and where this property is used?
Regards,
LEE
|
|
|
|
|
The Article by Zeeshan Muhammad Themes&Skin[^]will help you in this regard.
Regards,
Satips.
|
|
|
|
|
I'm pretty sure the answer to this is simply but I'm currently lost. I am developing an "Extranet" site for my clients, here they can log in, track the progress of their site, approve pages as they're completed, upload Word documents with copy for certain pages and so on. To do this I'm wanting to use SQL as my data solution.
My host, unfortunately, doesn't have SQL running on his server (it's not an actual "hosting company", he's a long time friend who happens to have large servers for a company he used to own (lost funding) that I was lead developer for. I've read some on SQL2005 Express but I'm wanting to know how I can add a database in the App_Data folder and have it work without SQL being on the host server.
I tried right-clicking on the App_Data Folder and adding new item, select "SQL Database" and it adds it just fine but when I try to add tables or anything I get a weird error (shown in this image[^] (I blurred out part of the path so as my computer information and name isn't visible).
Is it possible to attach SQL2005EXPRESS without SQL running on the host machine? If so how?
" In the next millennium there are two kinds of business, those on the Internet and those out of business"
Bill Gates
"Be nice to nerds. Chances are you'll end up working for one."
Bill Gates
"Let's face it, the average computer user has the brain of a Spider Monkey."
Bill Gates
|
|
|
|
|
RLMcCutchen wrote: I've read some on SQL2005 Express but I'm wanting to know how I can add a database in the App_Data folder and have it work without SQL being on the host server.
You really can't. Not unless you store all your data as XML or you use Access, or something.
SQL Express is OK, but not good if it will be used by many people at once.
RLMcCutchen wrote: (it's not an actual "hosting company", he's a long time friend who happens to have large servers for a company he used to own (lost funding)
This sounds like a disaster. You want to expose your clients to this mess ? Get a real host. One with SQL Server.
RLMcCutchen wrote: Is it possible to attach SQL2005EXPRESS without SQL running on the host machine? If so how?
Of course not. If the database is not running on the host machine, or a machine visible to the host, then it's not going to work, is it ?
However, Access would be fine. You just need to work out what's holding the file open when your code tries to open it ( that's what that error is )
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"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 )
|
|
|
|
|
Christian,
Their sites aren't going to be hosted with my site, they have their own host so I wont be exposing them to anything. Like I said, this is a fairly simple "Extranet" that the client can log into and we can communicate back and forth with one another, they can upload documents to my site for me to use and so on, it is in no way connected to their site at all. Eventually we will (hopefully within the month) have SQL 2005 back up and running on the server I'm hosted on and this wont be a problem. The SQL Express wont be used by many people at once, maybe 5 -10 at a time for now, by the time it's more this wont be an issue as SQL 2005 will be on the server. I was just looking for a solution for the time being.
PS: I do have a real host, he has 13 Dell Blade Servers and a central server for running SQL (it's just not up and running as of yet). He is hosting several mission critical sites using SQL but his current SQL is Co-Hosted elsewhere and they wont let me connect via Enterprise Manager or Query Analyzer so I cant use their database server.
" In the next millennium there are two kinds of business, those on the Internet and those out of business"
Bill Gates
"Be nice to nerds. Chances are you'll end up working for one."
Bill Gates
"Let's face it, the average computer user has the brain of a Spider Monkey."
Bill Gates
|
|
|
|
|
I want to set contact_us.aspx like the web site default page, but i cant reach the iis admin, can i do by another way?, maybe the web.config..
keep Learning and you never will be out of date...
|
|
|
|
|
You normally would do it through the iis admin. There is a tab where you set the default page. If that is not an option you can do some http re-direction so when the default.aspx page is requested you could auto redirect. The easiest way to do this is to create a default.aspx page and in the page load event to a response.redirect("contact_us.aspx")
Hope that helps.
Ben
|
|
|
|
|
No, you need to tell IIS what page to load by default. You could just change your index.aspx, or whatever, to redirect to the page you want ? Or does the index page get used elsewhere ?
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"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 )
|
|
|
|
|
strSQL="UPDATE [q1], [q2], [q3], [q4], [q5], [q6], [q7], [q8],"+<br />
" [q9], [q10], [q11], [q12], [q13], [q14], [q15],"+<br />
" [q16], [q17], [q18], [q19], [q20], [q21], [q23],"+<br />
" [q24], [q26], [q28], [q34], [q35], [q38], [q39],"+<br />
" [q40], [q42], [q43], [q44], [q45], [q46], [q47],"+<br />
" [q48], [q51], [q52], [q53], [q54], [q57], [q58],"+<br />
" [q61], [q62], [q63], [q66], [q67], [q70], [q71],"+<br />
" [q72], [q73], [q74], [q75], [q84], [q85], [q86],"+<br />
" [q87], [q88], [q89], [q90], [q91], [q98], [q99],"+<br />
" [q100], [q101],"+" [q102], [q103], [q104], [TCAIMSSite],"+<br />
" [DTG_Submit], [LoginID], [TestPhase]"+<br />
" FROM t_EOT_User WHERE RecNum="+RecNum.Text;<br />
error says SYNTAX errror on UPDATE Statement
|
|
|
|
|
What happens if you type this text into SQL Server directly ?
I trust this code is not in your .aspx.cs file ?
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"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 )
|
|
|
|
|
I wish I was using an SQL server, access database.
|
|
|
|
|
OK, an MDB file ? What if you recreate your table structure in SQL Server and try this SQL ? I presume the SQL is wrong, it looks odd to me. Do the two tables you're inserting from and to have the same fields in them ? Have you tried rewriting it to work differently ?
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"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 )
|
|
|
|
|
This code is just in my .CS file sorry, didnt notice you asked that.
|
|
|
|
|
Great - so long as it's not in the actual code behind, that would be bad design, is all.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"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 )
|
|
|
|
|