|
koolprasad2003 wrote: Can i give caption/Title to confirm box in javascript ???
No you can't
|
|
|
|
|
No, in JavaScript
Yes, in VBScript
|
|
|
|
|
i am using datagrid on clikcing edit button upload control is display
the code is
ON Updatecommand of datagrid i m writing the code
Dim pid As Integer = Val(e.Item.Cells(1).Text)
Dim upload1 As FileUpload = CType(e.Item.FindControl("UpRSPictureedt"), FileUpload)
Dim objcmaint As New ClsMaintenence
If Not IsNothing(upload1) Then
intImageSize = upload1.PostedFile.ContentLength
(AT THIS POINT IT IS GIVING ERROR AS OBJECT NOT SET TO REFRENCE )
strImageType = upload1.PostedFile.ContentType
' Reads the Image
please suggest me
|
|
|
|
|
try using
if upload1.HasFile then
end if
Paras Kaneriya The difference between genius and stupidity is that genius has its limits.
|
|
|
|
|
this code i m using in datagrid html
<asp:templatecolumn headertext="IncidentPicture">
<itemtemplate>
" target="new">ViewPicture
<edititemtemplate>
<asp:fileupload id="UpRSPictureedt" runat="server">
when user clicks the update button i m taking update method ,updating upload control as follows
Dim upload1 As FileUpload = CType(e.Item.FindControl("UpRSPictureedt"), FileUpload)
but here when i m checking upload1.hasfile or upload1.postedfile,it is null so please suggest me how to capture it when updating the uploadcontrol
|
|
|
|
|
<asp:templatecolumn headertext="IncidentPicture">
<itemtemplate>
<<%#Container.DataItem("InciPicID")%>"
<edititemtemplate>
<asp:fileupload id="UpRSPictureedt" runat="server">
when user clicks the update button i m taking update method ,updating upload control as follows
Dim upload1 As FileUpload = CType(e.Item.FindControl("UpRSPictureedt"), FileUpload)
but here when i m checking upload1.hasfile or upload1.postedfile,it is null so please suggest me how to capture it when updating the uploadcontrol
|
|
|
|
|
<%--<asp:templatecolumn headertext="IncidentPicture">
<itemtemplate>
<<%#Container.DataItem("InciPicID")%>"
<edititemtemplate>
<asp:fileupload id="UpRSPictureedt" runat="server">
--%>
when user clicks the update button i m taking update method ,updating upload control as follows
Dim upload1 As FileUpload = CType(e.Item.FindControl("UpRSPictureedt"), FileUpload)
but here when i m checking upload1.hasfile or upload1.postedfile,it is null so please suggest me how to capture it when updating the uploadcontrol
|
|
|
|
|
<%--<asp:templatecolumn headertext="IncidentPicture"><itemtemplate><%#Container.DataItem("InciPicID")%>"<edititemtemplate> <asp:fileupload id="UpRSPictureedt" runat="server">--%>
when user clicks the update button i m taking update method ,updating upload control as follows
Dim upload1 As FileUpload = CType(e.Item.FindControl("UpRSPictureedt"), FileUpload)
but here when i m checking upload1.hasfile or upload1.postedfile,it is null so please suggest me how to capture it when updating the uploadcontrol
|
|
|
|
|
11<asp:TemplateColumn HeaderText="IncidentPicture">
<ItemTemplate>
<<%#Container.DataItem("InciPicID")%>" </ItemTemplate>
<EditItemTemplate>
<asp:FileUpload ID="UpRSPictureedt" runat="server" />
</EditItemTemplate>
</asp:TemplateColumn>
when user clicks the update button i m taking update method ,updating upload control as follows
Dim upload1 As FileUpload = CType(e.Item.FindControl("UpRSPictureedt"), FileUpload)
but here when i m checking upload1.hasfile or upload1.postedfile,it is null so please suggest me how to capture it when updating the uploadcontrol
|
|
|
|
|
MD12 wrote: If Not IsNothing(upload1) Then
if(upload1.HasFile) then
Best Regard
Pathan
please don't forget to vote on the post that helped you.
|
|
|
|
|
11<asp:TemplateColumn HeaderText="IncidentPicture">
<ItemTemplate>
<<%#Container.DataItem("InciPicID")%>" </ItemTemplate>
<EditItemTemplate>
<asp:FileUpload ID="UpRSPictureedt" runat="server" />
</EditItemTemplate>
</asp:TemplateColumn>
when user clicks the update button i m taking update method ,updating upload control as follows
Dim upload1 As FileUpload = CType(e.Item.FindControl("UpRSPictureedt"), FileUpload)
but here when i m checking upload1.hasfile or upload1.postedfile,it is null so please suggest me how to capture it when updating the uploadcontrol
|
|
|
|
|
1) Verify whether UpRSPictureedt has a RUNAT=server attribute. Custom manually typed controls normally, we skip and create this error.
2) upload1.PostedFile should be checked for NULL
|
|
|
|
|
11<asp:TemplateColumn HeaderText="IncidentPicture">
<ItemTemplate>
<<%#Container.DataItem("InciPicID")%>" </ItemTemplate>
<EditItemTemplate>
<asp:FileUpload ID="UpRSPictureedt" runat="server" />
</EditItemTemplate>
</asp:TemplateColumn>
when user clicks the update button i m taking update method ,updating upload control as follows
Dim upload1 As FileUpload = CType(e.Item.FindControl("UpRSPictureedt"), FileUpload)
but here when i m checking upload1.hasfile or upload1.postedfile,it is null so please suggest me how to capture it when updating the uploadcontrol
|
|
|
|
|
how to create an excel document on the button click in asp.net2.0
Gayatri
|
|
|
|
|
In visual studio 2005, Add the reference - Microsoft office 10.0 object Library to your project.
Add the following code in button click event
Dim excel As New Excel.Application
Dim wbook As Excel.Workbook
Dim wSheet As Excel.Worksheet
wbook = excel.Workbooks.Add()
wSheet = wbook.ActiveSheet()
Dim strFileName As String = "The location to save the excel file"
wbook.SaveAs(strFileName)
excel.Workbooks.Open(strFileName)
excel.Visible = True
Try it and check whether its working.
with regards,
lavanya
|
|
|
|
|
Or you can output your data to an HTML table in the page and then add headers to get explorer to open that item in Excel.
|
|
|
|
|
Hi,
I am new to MS.net 2.0.
i have some problems when designing the page..
1. After placing some controls ( like text box or button) to my page (having html some tables ) , i couldnt switch to design view , it show some tag missing like error..automatically some tags are missing frm my web page .. why this happen??
2. when i try to rename a control's(textbox or buton) name,it shows error like invalid domain name.
plz help.....
All I ever wanted is what others have.... CrazySanker
|
|
|
|
|
Please check out whether all the tags are being closed i.e all the start tags have its corresponding end tags.. if so then there'll be no such errors..
Regards
Sivan.G
|
|
|
|
|
i confirmed it..all openng tags have closing tages.sometimes its work fine. The issue arise only when i try to place a new control in it....
All I ever wanted is what others have.... CrazySanker
|
|
|
|
|
hi,
I am using .net 2005 ajax enabled website. It kept two dropdownlist, if I select a value in the first dropdownlist, the value related to that should loaded in the second dropdownlist with out page re-loading(refresh).
How to do this without page loading.
please help me,
jai prakash
|
|
|
|
|
|
You can do that using ICallbackEventHandler interface
watch DEMO
Source code
You can also use CascadingDropDown control
Visit Link
Best Regard
Pathan
please don't forget to vote on the post that helped you.
|
|
|
|
|
u putt this drop down list in update panel
Piyush Vardhan Singh
Senior Software Engineer
TAS NewDelhi
India
|
|
|
|
|
jai aswitha wrote: if I select a value in the first dropdownlist, the value related to that should loaded in the second dropdownlist with out page re-loading(refresh).
How to do this without page loading.
Put a UpdatePanel, and drag your drop down control inside to that. You are almost done
|
|
|
|
|
how to count child node of selected node in tree view
Piyush Vardhan Singh
Senior Software Engineer
TAS NewDelhi
India
|
|
|
|