|
using System;
using System.Web.UI.WebControls;
Now add following code in code behind
protected void Page_Load(object sender, EventArgs e)
{
if(!IsPostBack)
{
Label masterlbl = (Label)Master.FindControl("lblMaster");
TextBox mastertxt = (TextBox) Master.FindControl("txtMaster");
lblContent.Text = masterlbl.Text;
txtContent.Text = mastertxt.Text;
}
}
Here 'txtMaster' is a textbox placed in the masterPage...u can try like this to get all controls from MasterPage
|
|
|
|
|
Salam & Good Day Aatif
Many thanks for your support. But actually you can give me the C# code and I am using VB.NET following are the codes.
DirectCast(SelectSurvey.FindControl("lblMaster"), DropDownList)
But It give error on "SelectSurvey.FindControl" where SelectSurvey is page where that control exist. Infect there is no .FindControl property in list when I give the page name and pressing DOT(.) can you I also add two reference of class as below
Imports System
Imports System.Web.UI.WebControls
Can you please let me know why. Your quick reply will be highly appreciated
Regards
Ferhat
|
|
|
|
|
dear all,
I have a case, like this:
I have 2 servers, the server A and server B,
A server in my store the result data file upload from application A,
How do it so I can download it from the server B / Applications B.
without using FTP or shared folders term,
and how can I find out if the way there is a new file on the Server A is the result of the application upload A.
course using Microsoft Dotnet technology.
thanks so much for his attention,
any form of advice, referral and opinions greatly appreciated.
greetings advance.
|
|
|
|
|
Research this Windows function: FileSystemWatcher(), it can be used to monitor a directory for files that have been newly created.
Also, depending on how big the files are you may be able to create a webservice on Server B which can be invoked by a Windows service on Server A.
My idea is something like this:
1) Create a windows service on server A which uses FileSystemWatcher() to monitor a directory for newly uploaded files.
2) When a new file is detected, invoke a Webservice on Server B to send the data over.
How about that? 
|
|
|
|
|
thanks for replay David Mujica,
thanks for the advice ... I'll try it,
whether it can be safe in terms of its web security and server ...
or maybe there are other ideas ..
but I thank you for his time ...
|
|
|
|
|
|
Please don't post a link to another forum and expect us to read through all of the posts. If you have a question, please clearly articulate it and we'll be happy to help.
There are only 10 types of people in the world, those who understand binary and those who don't.
|
|
|
|
|
I have created asp.net web application in windows 7. I am able to run locally but i am not able to run from other system.
What could be the possible reason.
If anybody knows, please reply me.
Thanks in advance.
|
|
|
|
|
Can you change your connection string.
Ans what error you see when you try to run fro other system.
|
|
|
|
|
|
are you trying to access through IP address or copying your application to other system. can you provide some more details...
|
|
|
|
|
Please provide us more detail i.e VS version or IIS version.
|
|
|
|
|
Hello,
Check the Settings IIS 6.0
1. Right Click on the virtual directory -> Properties -> Directory Security -> Anonymous Access and Authentication Control -> Edit
2. Under that tab make ensure Allow Anonymous Access & Allow IIS to control Password check boxes are checked.
3. Uncheck the Integrated Windows Authentication, then followed by Aplly & Ok.
4. Then access your application from any other system by using your IP seems like http://192.168.3.107[YOUR_MACHINE_IP]/[APP_ALIAS_NAME]
Try it and let me know.
Regards,
Chakra
|
|
|
|
|
Hi, Iam using C#, VS-2010. It's my first project in ASP.
The Image can be found on top of website home-page...It's "ISG"
... When I try to save the image by Right Click, its shows " Adobe Flash Player 11.7.700.224...blah..blah...".
Hence I wish to learn this area...
That image looks like animated waves passing over the image...Therefore I wish to create like the similar flash animation...so how to achieve those style....? Which control can achieve it?
The Website...
http://www.infosys-global.com/en/[^]
Thanks for the guidances..
|
|
|
|
|
It's not an image, it's a flash animation. To download a flash animation, you can take a look at here[^]. To create a flash animation, you must use a software such as Adobe Flash.
|
|
|
|
|
Thank You thanh_bkhn
|
|
|
|
|
Hi, I am working on .net framework 4.0 with language as C#.
I am using Cosole Application to consume webservice.
The provider's webservice is registered in UDDI registry (provider's private registry , and not microsoft's registry)
I have the provider Webservice's " .wsdl" URL and EndPoint
with the help of these two things, how i can consume UDDI registry's webservice in my Console Application ?
I have never consumed webservice from UDDI registry, so this is first time I am working on such task.
Can any one suggest me the possible solution ?
Thanks in advance
Prakash Sawant
System Analyst
Mumbai, India.
|
|
|
|
|
i have code
[AllowAnonymous]
public ActionResult IndexDT(int? page, string sortOrder, string currentFilter, string searchString)
{
ViewBag.CurrentSort = sortOrder;
ViewBag.NameSortParm = String.IsNullOrEmpty(sortOrder) ? "TenSanPham desc" : "";
ViewBag.CostSortParm = sortOrder == "Gia" ? "Gia desc" : "Gia";
if (Request.HttpMethod == "GET")
{
searchString = currentFilter;
}
else
{
page = 1;
}
ViewBag.CurrentFilter = searchString;
int pageSize = 2;
int pageNumber = (page ?? 1);
return View(spBLL.ListDT(searchString, sortOrder).ToPagedList(pageNumber, pageSize));
}
@model PagedList.IPagedList<ComputerBLL.SanPham>
@{
ViewBag.Title = "IndexDT";
}
<script src="../../Scripts/jquery-1.7.1.js" type="text/javascript"></script>
<script src="../../Scripts/jquery-ui-1.8.20.js" type="text/javascript"></script>
<script src="../../Scripts/jquery.unobtrusive-ajax.js" type="text/javascript"></script>
<script type="text/javascript">
$(document).ready(function () {
$("#timKiemNangCao").click(function () {
$("#search").after('');
});
});
function TimNangCao() {
var sanpham = new Object();
sanpham.TenSanPham = $("#name").val();
$.ajax({
type: "POST",
url: '../../SanPham/TimKiemNangCao',
data: JSON.stringify(sanpham),
contentType: 'application/json; charset=utf-8',
success: function (data) {
$(document).html(data);
},
error: function (xhr) {
alert(xhr.toString());
}
});
}
</script>
<h2>Index</h2>
<p>
@Html.ActionLink("Create New", "CreateDT")
</p>
@using (Html.BeginForm())
{
<p id="search">
Find by name: @Html.TextBox("SearchString", ViewBag.CurrentFilter as string)
<input type="submit" value="Search" />
<a style="color:Blue; cursor:pointer" id="timKiemNangCao">Tìm kiếm nâng cao</a>
</p>
<table style="text-align:left">
<tr><td><span>Tên sản phẩm</span></td><td><input type="text" id="name"/></td></tr>
<tr><td><span>Giá</span></td><td><input type="text" style="width: 100px"/>đến
<input type="text" style="width: 100px"/></td></tr>
<tr><td><span>Hệ điều hành</span></td><td></td></tr>
<tr><td><span>Nhà sản xuất</span></td></tr>
<tr><td><input type="button" onclick="TimNangCao()" value="Tìm nâng cao"/></td></tr>
</table>
}
<div class="portfolio_1_4">
<ul id="list">
@foreach (var item in Model)
{
if (item.ChiTietDT != null)
{
<!-- START PORTFOLIO COLUMN #1 -->
<li id="id-1" class="app"><span class="image"><a href= "@item.HinhAnh" data-rel="prettyPhoto" class="img-thumb">
<img class="portfolio_image" src="@item.HinhAnh" alt="" /></a> </span><span class="title">@Html.ActionLink(item.TenSanPham, "Details", new { id = item.MaSanPham })</span>
<span class="description">@Html.DisplayFor(modelItem => item.Gia)<br />
Đặt hàng<br />
@Html.ActionLink("Edit", "Edit", new { id = item.MaSanPham }) |
@Html.ActionLink("Details", "Details", new { id = item.MaSanPham }) |
@Html.ActionLink("Delete", "Delete", new { id = item.MaSanPham })
</span><span class="clear padding15"></span></li>
<!-- END PORTFOLIO COLUMN #1 -->
}
}
</ul>
<div class="clear">
</div>
</div>
<div>
Page @(Model.PageCount < Model.PageNumber ? 0 : Model.PageNumber)
of @Model.PageCount
@if (Model.HasPreviousPage)
{
@Html.ActionLink("<<", "IndexDT", new { page = 1, sortOrder = ViewBag.CurrentSort, currentFilter=ViewBag.CurrentFilter })
@Html.Raw(" ");
@Html.ActionLink("< Prev", "IndexDT", new { page = Model.PageNumber - 1, sortOrder = ViewBag.CurrentSort, currentFilter=ViewBag.CurrentFilter })
}
else
{
@:<<
@Html.Raw(" ");
@:< Prev
}
@if (Model.HasNextPage)
{
@Html.ActionLink("Next >", "IndexDT", new { page = Model.PageNumber + 1, sortOrder = ViewBag.CurrentSort, currentFilter=ViewBag.CurrentFilter })
@Html.Raw(" ");
@Html.ActionLink(">>", "IndexDT", new { page = Model.PageCount, sortOrder = ViewBag.CurrentSort, currentFilter=ViewBag.CurrentFilter })
}
else
{
@:Next >
@Html.Raw(" ")
@:>>
}
</div>
in only search one data
please suggest for me how to search more data
thank you !
|
|
|
|
|
I am not going to read through all of your code to try and make sense of it. Please narrow down to what specific lines of code are relevant and also explain why you are having a hard time.
There are only 10 types of people in the world, those who understand binary and those who don't.
|
|
|
|
|
I was handed a "precompiled" asp.net app source code. OK, how do I make this such that I can use and debug it? How do I compile a precompiled app?
http://i67.photobucket.com/albums/h292/Athono/precompiled_zps65b526bf.png
After I click past this window, and i try to build the application, I get an error that says "This application is already precompiled".
What can I do?
|
|
|
|
|
Sir;
look if this page[^] helps or try to delete 'PrecompiledApp.config'
Help people,so poeple can help you.
|
|
|
|
|
Hi Sirs,
Recently i heard about Light Switch from one of the blog,can any body tell me why its not that much used ?
|
|
|
|
|
|
I think part of the problem is the demos never really worked right. That's a pretty bad way to market something. The post referenced about how to get an answer does not define what we can and can't discuss on this forum. We used to have discussions here. Some of us are still open to it.
|
|
|
|
|