|
Hi friends,
how can i download a wav file on clicking a HTML Download Link?...
Note: without zipping that file
Thanks in advance
|
|
|
|
|
Hi Guys
I am working an asp.net application in which i required to fetch client PC MAC address
I gone through this Script but its giving Error
So Any Other solution Plz Tell me
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Untitled Page</title>
<script id="clientEventHandlersJS" type="text/javascript">
function Button1_onclick() {
var locator = new ActiveXObject ("WbemScripting.SWbemLocator");
var service = locator.ConnectServer(".");
var properties = service.ExecQuery("SELECT * FROM Win32_NetworkAdapterConfiguration");
var e = new Enumerator (properties);
document.write("<table border=1>");
dispHeading();
for (;!e.atEnd();e.moveNext ())
{
var p = e.item ();
document.write("<tr>");
document.write("<td>" + p.Caption + "</td>");
document.write("<td>" + p.IPFilterSecurityEnabled + "</td>");
document.write("<td>" + p.IPPortSecurityEnabled + "</td>");
document.write("<td>" + p.IPXAddress + "</td>");
document.write("<td>" + p.IPXEnabled + "</td>");
document.write("<td>" + p.IPXNetworkNumber + "</td>");
document.write("<td>" + p.MACAddress + "</td>");
document.write("<td>" + p.WINSPrimaryServer + "</td>");
document.write("<td>" + p.WINSSecondaryServer + "</td>");
document.write("</tr>");
}
document.write("</table>");
}
function dispHeading()
{
document.write("<thead>");
document.write("<td>Caption</td>");
document.write("<td>IPFilterSecurityEnabled</td>");
document.write("<td>IPPortSecurityEnabled</td>");
document.write("<td>IPXAddress</td>");
document.write("<td>IPXEnabled</td>");
document.write("<td>IPXNetworkNumber</td>");
document.write("<td>MACAddress</td>");
document.write("<td>WINSPrimaryServer</td>");
document.write("<td>WINSSecondaryServer</td>");
document.write("</thead>");
}
</script>
</head>
<body onload ="Button1_onclick();" >
</body>
</html>
Thanks In Advanced
krishna veer singh
|
|
|
|
|
What does 'it's giving error' mean ? That's kind of useless.
As you're finding, you can only find the Mac address in IE, no other browser, and then only via an ActiveX control.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Ya Its working only in ie 6.0 after Active ActiveX component
but I want Script which work in all browser
or
Any different method i can use
krishna veer singh
|
|
|
|
|
krishnaveer wrote: Any different method i can use
No other alternatives.
|
|
|
|
|
So How can go ahead with this one
becoz its my application requirement
krishna veer singh
|
|
|
|
|
You customer may not know about web applications. But as a programmer, you should be able to understand the limitations of a web application and take appropriate design decisions. As I said, there is no way to get clients MAC id. Try to make your customer understand this and think about other possible designs.
BTW, what are you doing with the clients MAC id?
|
|
|
|
|
If your client had approached a real programmer, then they would have dealt with someone who told them what was physically possible, instead of someone who accepted anything that they could imagine, despite having no idea how it could be done.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
sorry buddys it might be in wrong category, but i use ASP.NET platform
for devloping so...
now my question:
i have table formated as three column:
id,parent_id,name
ex..
id /parent_id /name
1 /null /ABC1
2 /1 /ABC2
3 /1 /ABC3
4 /2 /ABC4
5 /4 /ABC5
6 /3 /ABC6
for example i wnt to retrive perticulars child and sub child of id 2 then
it should give result:
2 /1 /ABC2
4 /2 /ABC4
5 /4 /ABC5
actually i want perticulars child and sub childs.. if id is 2 den i want child of id 2, and sub childs of id 2,s child and so on..
Please giv me appropriate query for it...
thanks in advance
modified on Wednesday, August 19, 2009 2:58 AM
|
|
|
|
|
Can you expl more because what you asking and what your result is doesnt make sence.
|
|
|
|
|
actually i want perticulars child and sub childs.. if id is 2 den i want child of id 2, and sub childs of id 2,s child and so on..
|
|
|
|
|
sorry, this is wrong forum... if you post you question in a appropriate forum you will be clearly guided by our experts.....
|
|
|
|
|
Since you asked about query, here is a possible implementation using stored procedure.
1 - Write a stored procedure that takes a parent id.
2 - Do a select to get all the children of the supplied parent id and assign it to a T-SQL cursor.
3 - Iterate over all of the children.
3.1 - Add row into a temporary table
3.2 - Call this procedure again (recursive) by passing the child id as parent id. Goes to step 2
4 - Select all the rows from the temporary table if @@NESTLEVEL is 1.
5 - Drop temporary table, de-allocate cursor.
Note: SQL server has a stored procedure nesting limit. I guess it is 32. So if you have an item which is nested more than 32 levels, you will get error. In such case, you need to handle this in the application code rather than on a procedure.
Also you need to make sure that the temporary table is getting created only once, that is when the procedure starts executing for the first time. All the nested calls will get the temporary table created on the first call.
This can be done in a better way using C# (or whatever language you use).
|
|
|
|
|
ok... i understand ur method, but i faced problem to create procedure.. can you reply me demo procedure???
thanks..
|
|
|
|
|
punit_belani wrote: but i faced problem to create procedure
What problem are you facing in creating a procedure?
punit_belani wrote: can you reply me demo procedure
Its very easy to create your own procedure with the steps provided in my last post. If you have problems, come back with specific error messages. Do a search on creating nested stored procedures and learn to do it yourself. Spoon feeding will not benefit you.
|
|
|
|
|
you mean you need hierarchical data. If particular node is chosen, you need all its child elements.
I think it is very easy to do in Recursion, but very tough to do it in a single SQL.
Try it, It needs Self joins in query. I will do this when get time and let you know.
|
|
|
|
|
ok.. waitin for ur reply.. thanks..
|
|
|
|
|
m looking to get the value of label or hidden input field in javascript ....
<javascript>
var lbl = document.getElementById(Label1);
.
.
so.addParam('flashvars', 'file=' + lbl.value + '&type=video');
.
.
>
where Label1 is
or
<asp:label id="Label1" runat="server" text="NeverEndingSunAviHochberg.flv" visible="False" ><="" asp:label="">
but i m not geeting it right
any help.........
thanks in advance
|
|
|
|
|
You need to use the ClientID property of Label1 to find out what it's called on the client
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
u meanz.
var lbl = document.getElementById(<%=title.ClientID>').value;
but still not working
|
|
|
|
|
Well, that's because you have not put the id in quotes.
When you move beyond making the sort of basic mistakes that are clear to anyone with half a clue, you will find it hard to get answers if you don't move past 'still not working', to actually explain any error messages, what you did about those messages, and why you're still stuck.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
not at all actually its just typing mistake.
in js..
var lbl = document.getElementById('<=title.ClientID>;').value;
title is..
;
|
|
|
|
|
AhmedNisar82 wrote: var lbl = document.getElementById('<=title.ClientID>;').value;
This won't work, just < and > does not make a server side tag. You need to put a % inside either side for that to work. Have you checked the HTML to see what comes out ?
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Hi all,
I want to drag and drop items from one listbox to another listbox on the same webform. Do anybody have an idea of how to do this in ASP.net?
|
|
|
|
|
There is no way that ASP.NET can help you, you want to do something that requires the use of javascript.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|