Saturday, September 15, 2018

How to transfer android mobile files and data to Laptop or PC using this awesome app

Hello everyone, today I will tell you about one nice android app which is very useful to transfer your files from your mobile to your Laptop or PC using Wi-Fi on any OS. I am going to tell you the steps required to do this.

Step 1- Open play store on your Android phone, type Xander in search bar. Select Xander app and install it on your phone.

Step 2- Open this app and slide right to show menu -> then click more -> select Connect to PC

Step 3- Select Hotspot tab. It will show few things to do with your PC/Laptop.

Step 4- On your PC/Laptop, open WiFi connection and connect with hotspot mentioned in Xander App.

Step 5- After WiFi hotspot connection done. Open Web Browser like Chrome/Firefox and type in URL bar 192.168.43.1:4433. This URL also mentioned in Xander app. Press Enter.

Step 6- Now on your mobile showing a Pop up window. Select Accept. ITS DONE

Now in your browser you will be able to see all files and images. Surf all items in this and you will be able to upload and download any file between your Mobile and PC / Laptop.

Enjoy...

Tuesday, July 21, 2015

Dynamic Set the Height of Iframe by its Content Jquery JavaScript

Go through these simple Steps: 

step 1: Make Iframe with onload event
 
<IFRAME SRC="usagelogs/default.aspx" width="100%" height="200px" id="iframe1"  
 marginheight="0" frameborder="0" onLoad="autoResize('iframe1');"></iframe> 

Step 2: Write autoResize(id) Function
 
<script language="JavaScript">
function autoResize(id){
    var newheight;
    var newwidth;
    if(document.getElementById){
        newheight=document.getElementById(id).contentWindow.document.body.scrollHeight;
        newwidth=document.getElementById(id).contentWindow.document.body.scrollWidth;
    }
    document.getElementById(id).height= (newheight) + "px";
    document.getElementById(id).width= (newwidth) + "px";
}
</script>

Sunday, July 19, 2015

Load jQuery or JAVAScript when using Update Panel in ASP.net C# or VB.Net

Here are simple 3 steps -

Step 1: Write all javascript or jQuery code inside a function like following-
 
<script> 
function BindIt()
{
    alert("execute again"); 
    //****Add your code here***//
   ----
   -----  
}
</script> 
 
Step 2: Call "BindIt()" function on Body onload event.  
 
<body onload="javascript:BindIt()">
 
Step 3: Add following javascript code inside UpdatePanel..and All Done.. 
 
<form runat="server" ID="form1"> 
 <asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager>
   <asp:UpdatePanel ID="UpdatePanel1" runat="server">
       <ContentTemplate>
          
          <script type="text/javascript">
              Sys.Application.add_load(BindIt);
          </script>

Friday, January 17, 2014

Create Zip File in ASP.NET using "Ionic.zip.dll" with Example

Step 1:

Ionic.zip.dll Download  and right-click on "Bin" folder of your project and select "Add Reference" select this "Ionic.zip.dll" file and click Add. It will add Ionic.zip.dll into your project.
Make following folder structure in your Project-


Step 2:

In Design Page write following code :


Step 3: 

In Code (.cs) Page write following code :

zip.AddFiles(filenames,date);
"date" used for folder name where these files will be stored inside ZIP.

If you want to delete all files inside folder "ZipMyFiles" use following code-


If you want large file to Upload and ZIP then follow step 4.
Step 4:
In web.config file write following setting:

Friday, December 27, 2013

ASP.NET : Call a function inside Gridview

In .aspx page.....

<asp:GridView ID="GV" runat="server"  AutoGenerateColumns="False"
onrowcommand="GV_RowCommand" BackColor="White" BorderColor="#999999" BorderStyle="Solid" BorderWidth="1px"  CellPadding="3" ForeColor="Black" GridLines="Vertical">


<Columns>

                    <asp:TemplateField HeaderText="S.No.">

                    <ItemTemplate>

                             
                                <%#(Container.DataItemIndex + 1)%>.

                    </ItemTemplate>

                    </asp:TemplateField>

                    <asp:BoundField HeaderText="Admission No." DataField="RollNo" />

                    <asp:TemplateField HeaderText="Student Name">

                    <ItemTemplate>

                    <asp:LinkButton ID="LStudentName" runat="server"  

                          CommandName="LStudentName" 
                         CommandArgument='<%#Eval("RollNo") %>' 
                         Text='<%#Eval("StudentName") %>'></asp:LinkButton>

                    </ItemTemplate>

                    </asp:TemplateField>

<asp:TemplateField HeaderText="Status">

                    <ItemTemplate>

                    <asp:Label ID="lblstatus" runat="server"

Text='<%#GenrateStatus(Eval("Status"))%>' ></asp:Label>

                    </ItemTemplate>

  </asp:TemplateField>

</Columns>

                <FooterStyle BackColor="#CCCCCC" />

                <PagerStyle BackColor="#999999" ForeColor="Black"

HorizontalAlign="Center" />

                <SelectedRowStyle BackColor="#000099" Font­

Bold="True" ForeColor="White" />

                <HeaderStyle BackColor="Black" Font­Bold="True"

ForeColor="White" />

                <AlternatingRowStyle BackColor="#CCCCCC" />

            </asp:GridView>


In .cs page....

 public static string GenrateStatus(object status)

    {

        string strStatus = status.ToString();

        if (strStatus == "0")

            strStatus= "Pending";

        else if (strStatus == "1")

            strStatus= "Updated";

        return strStatus;

    }

Wednesday, October 16, 2013

AutoNumber Column In GridView DataList ASP.NET 4.0, 3.5, 2.0


We can add AutoNumber column by using Container.DataItemIndex property in html markup of the Gridview.

<title>Auto Number Cloumn in GridView </title>
</head>
<body>
<form id="form1" runat="server">
<asp:GridView ID="GridView1" runat="server" 
              AllowPaging="True" AutoGenerateColumns="False"
              DataSourceID="SqlDataSource1" PageSize="6" 
              AlternatingRowStyle-BackColor="#006699" 
              AlternatingRowStyle-ForeColor="#FFFFFF" >
    <Columns>
    <asp:TemplateField HeaderText="Serial Number">
    <ItemTemplate>
        <%# Container.DataItemIndex + 1 %>
    </ItemTemplate>
    </asp:TemplateField>
    <asp:BoundField DataField="Name" HeaderText="Name" 
                    SortExpression="Name" />
    <asp:BoundField DataField="Location" HeaderText="Location" 
                    SortExpression="Location" />
    </Columns>
    </asp:GridView>
<asp:SqlDataSource ID="SqlDataSource1" runat="server" 
ConnectionString="<%$ ConnectionStrings:ConnectionString %>"
SelectCommand="SELECT [Name], [Location] FROM [Details]">
</asp:SqlDataSource>

Saturday, August 31, 2013

New Features in ASP.NET 4.5

There are too many features in ASP.NET 4.5 to cover in one post, so I'll stick with some of the notable features added or enhanced in this version.
  • Web Sockets: Full support for the Web Sockets HTML5 standard is available with ASP.NET 4.5 running on IIS 8.0 via the SignalR library. This allows you to easily add real-time Web functionality to applications.
  • Authentication: There is now a universal provider (DefaultMembershipProvider) for simplification. In addition, the OAuth protocol is embraced.
  • Async programming: While this feature is not ASP.NET-specific, it is worth noting that C# 5 and Visual Basic 11 provide async support without using multiple threads (via async and await keywords).
  • Web publishing: This feature has been enhanced, whereas you can compare local and remotes files, publish only selected files, and so forth.
  • Web API: This API provides the REST approach to building applications -- a key difference from the WCF alternative. In addition, the Web API now includes extensive OData support, which is another instance of Microsoft embracing open source standards.
  • Friendly URLs: The popularity of tinyurl demonstrates the widespread problem of keeping up with long, arcane URLs. This feature is now available with ASP.NET applications via the FriendlyURLs feature.
  • Mobile: The explosion of smartphones, eReaders and other mobile devices has changed the landscape for Web application development. HTML5 support is supposed to simplify mobile application development. In addition, MVC 4 includes mobile templates, and there are a variety of mobile device emulators that can be used in Visual Studio 2012.
  • IIS: This allows you to use new features available in Internet Information Server (IIS) 8.0. Some of these features include prefetching and application initialization like application ping on startup. Also, an express edition of IIS is now available.