English

Introduction to AI on Microsoft Azure 853 480 mezo

Introduction to AI on Microsoft Azure

Hello my dear padawans I would like to write some notes about AI for everyone, I am preparing for Microsoft AI Engineer certification exams and I will put my notes here as much as possible 🙂

What is AI? AI is a powerful tool, paving the way for innovative software that enhances health care, assists individuals with physical limitations, fortifies smart infrastructure, delivers captivating entertainment experiences, and contributes to environmental conservation.

Exploring AI

AI is characterized by its ability to mimic human behaviors and skills. It encompasses:

  • Machine Learning: The cornerstone of AI, enabling computers to learn from data and make informed predictions.
  • Computer Vision: Allows AI to interpret visual information from images and videos.
  • Natural Language Processing: Enables computers to understand and respond to human language.
  • Document Intelligence: Manages and processes vast amounts of data in documents efficiently.
  • Knowledge Mining: Extracts valuable information from unstructured data sources.
  • Generative AI: Creates original content ranging from text to images.

Diving Deep into Machine Learning

Machine learning stands as the bedrock of many AI applications. Since its inception in the 1950s, it has been a focal point for data scientists globally. This branch of AI intertwines computer science with mathematics.

Consider sustainable farming – an area where machine learning proves instrumental. Companies like The Yield leverage sensors, data analytics, and machine learning algorithms to provide farmers with actionable insights on weather patterns, soil quality, and plant health.

Unraveling Machine Learning Mechanisms

In today’s digital age, we are inundated with a plethora of data daily. Machine learning algorithms sift through this extensive dataset – including social media posts, emails, photographs – discerning patterns and relationships that inform decision-making processes.

For instance in environmental conservation efforts; machine learning models analyze complex datasets identifying correlations between various elements. These insights are pivotal for developing strategies aimed at preserving our planet’s biodiversity while promoting sustainable practices.

Unleashing the Power of AI: A Deep Dive into Machine Learning and Computer Vision

In the ever-evolving field of Artificial Intelligence (AI), a team of dedicated botanists and scientists are making remarkable strides in understanding wildflower species. Armed with labeled data meticulously collected from wildflower samples, these professionals employ sophisticated algorithms to unveil intricate relationships between various features and species.

The Journey from Data Collection to Model Creation

The process begins in the heart of nature, where every sample is labeled with precision, ensuring accuracy in data collection. This labeled data then undergoes rigorous processing through an algorithm designed to uncover hidden patterns and relationships. The culmination of this process is a comprehensive model that encapsulates these findings.

As AI continues its upward trajectory, new samples discovered by volunteers can now be easily identified by this model, marking a significant milestone in AI’s capabilities.

Microsoft Azure: Your Companion in Machine Learning

Machine learning has found a formidable ally in Microsoft Azure. With its Azure Machine Learning service, users are endowed with a cloud-based platform tailored for creating, managing, and publishing machine learning models with ease.

Azure Machine Learning Studio stands out with its diverse authoring experiences including Automated machine learning for quick model creation; Azure Machine Learning designer for no-code solution development; Data metric visualization for experiment analysis; and Notebooks for personalized code writing on integrated Jupyter Notebook servers.

A Glimpse into the World of Computer Vision

Venturing into the realm of computer vision unveils possibilities that were once considered beyond reach. The Seeing AI app exemplifies computer vision’s prowess. Crafted for individuals with blindness or low vision, this app employs AI to narrate the visual world around them – an innovation transforming lives.

For an immersive experience on Seeing AI’s capabilities watch this video or explore more on the Seeing AI web page.

In Conclusion

AI’s journey from collecting wildflower samples to identifying species labels using complex models underscores its phenomenal growth. With platforms like Microsoft Azure enhancing machine learning and innovations like Seeing AI illuminating paths in computer vision, we are indeed witnessing a renaissance in artificial intelligence!

TaskDescription
Image classificationAn image of a taxi with the label "Taxi".
Image classification involves training a machine learning model to classify images based on their contents. For example, in a traffic monitoring solution you might use an image classification model to classify images based on the type of vehicle they contain, such as taxis, buses, cyclists, and so on.
Object detectionAn image of a street with buses, cars, and cyclists identified and highlighted with a bounding box.
Object detection machine learning models are trained to classify individual objects within an image, and identify their location with a bounding box. For example, a traffic monitoring solution might use object detection to identify the location of different classes of vehicle.
Semantic segmentationAn image of a street with the pixels belonging to buses, cars, and cyclists identified.
Semantic segmentation is an advanced machine learning technique in which individual pixels in the image are classified according to the object to which they belong. For example, a traffic monitoring solution might overlay traffic images with “mask” layers to highlight different vehicles using specific colors.
Image analysisAn image of a person with a dog on a street and the caption "A person with a dog on a street".
You can create solutions that combine machine learning models with advanced image analysis techniques to extract information from images, including “tags” that could help catalog the image or even descriptive captions that summarize the scene shown in the image.
Face detection, analysis, and recognitionAn image of multiple people on a city street with their faces highlighted.
Face detection is a specialized form of object detection that locates human faces in an image. This can be combined with classification and facial geometry analysis techniques to recognize individuals based on their facial features.
Optical character recognition (OCR)An image of a building with the sign "Toronto Dominion Bank", which is highlighted.
Optical character recognition is a technique used to detect and read text in images. You can use OCR to read text in photographs (for example, road signs or store fronts) or to extract information from scanned documents such as letters, invoices, or forms.

Understand natural language processing

Natural language processing (NLP) is a subfield of artificial intelligence that deals with the interaction between computers and humans in natural language. It involves processing natural language datasets, such as text corpora or speech corpora, using either rule-based or probabilistic (i.e. statistical and, most recently, neural network-based) machine learning approaches. The goal is a computer capable of “understanding” the contents of documents, including the contextual nuances of the language within them. The technology can then accurately extract information and insights contained in the documents as well as categorize and organize the documents themselves.

NLP has a wide range of applications, including:

  • Sentiment Analysis: Identifying the sentiment of a piece of text, such as whether it is positive, negative, or neutral.
  • Named Entity Recognition: Identifying and categorizing named entities in text, such as people, organizations, and locations.
  • Machine Translation: Automatically translating text from one language to another.
  • Question Answering: Automatically answering questions posed in natural language.
  • Chatbots: Interacting with users in natural language to answer questions or perform tasks.

NLP is a rapidly evolving field, with new techniques and models being developed all the time. Some of the most recent advances include:

  • Pre-trained Language Models: Large neural network models that are trained on massive amounts of text data, allowing them to perform a wide range of NLP tasks with high accuracy.
  • Transformers: A type of neural network architecture that has revolutionized NLP by allowing models to process entire sequences of text at once, rather than one word at a time.
  • Zero-shot Learning: A technique that allows models to perform NLP tasks in languages they have never seen before, by leveraging their knowledge of related languages.

NLP is a powerful tool that has the potential to transform the way we interact with computers and with each other. As the field continues to evolve, we can expect to see even more exciting applications of this technology in the years to come.

Document intelligence

Document Intelligence is a subfield of AI that focuses on managing, processing, and utilizing large volumes of data found in forms and documents. It enables the creation of software that can automate processing for contracts, health documents, financial forms, and more. This technology can extract valuable information from unstructured data sources, categorize and organize documents, and efficiently manage high volumes of data. Knowledge Mining is another area of AI that deals with extracting information from large volumes of often unstructured data to create a searchable knowledge store. It is a powerful tool that can help organizations extract valuable insights from their data and make informed decisions. Together, Document Intelligence and Knowledge Mining are transforming the way businesses manage and process data, enabling them to work more efficiently and effectively.

Generative AI

Generative AI is a subfield of artificial intelligence that deals with creating original content. It is often used in chat applications, where it takes in natural language input and returns appropriate responses in a variety of formats, including natural language, image, code, and audio. Generative AI models learn the patterns and structure of their input training data and then generate new data that has similar characteristics. This technology has a wide range of applications, including art, writing, script writing, software development, product design, healthcare, finance, gaming, marketing, and fashion. With the advent of large neural network models and transformer-based deep neural networks, generative AI has become more powerful and capable of performing a wide range of tasks with high accuracy.

Responsible AI 

Responsible AI is an approach to developing, assessing, and deploying AI systems in a safe, trustworthy, and ethical way. It emphasizes accountability, fairness, and inclusivity. The goal is to ensure that AI is created and applied in an ethical way that benefits everyone, while minimizing the potential for artificial intelligence to cause harm. Responsible AI practices aim to mitigate bias, ensure privacy, and prioritize the well-being of all users. Microsoft Azure provides a suite of tools to help you create a customized, end-to-end responsible AI experience, including the Responsible AI Dashboard, which offers a range of tools to help you operationalize responsible AI practices for your organization or business. As the field of AI continues to evolve, responsible AI practices will play an increasingly important role in ensuring that AI is developed and deployed in a way that benefits society as a whole.

At Microsoft, AI software development is guided by a set of six principles, designed to ensure that AI applications provide amazing solutions to difficult problems without any unintended negative consequences.

  • Fairness
  • Reliability and safety
  • Privacy and security
  • Inclusiveness
  • Transparency
  • Accountability

I hope that is helpful

May the knowledge be with you

Components on Blazor 1024 557 mezo

Components on Blazor

Hi my fellow Padawans

Blazor is a frontend framework like Angular or React but mostly like React and it has components for create pages and reusable objects functionalities.

But how can we create a component and use it on the pages in our Blazor application?

First Read this Article and create your first Blazor application 🙂

Then on your Solution Explorer find Pages and right click on it and Add -> Razor Component

On Add New Item windows write your components name and create it

I decided to make something different and I created Todo.Razor file and I add these codes on the page

@page "/todo"
@using BlazorApp1.Data;

<h3>Todo</h3>

<ul>
    @foreach (var todo in todos)
    {
            <li>@todo.Title</li>
    }
</ul>

<input placeholder="Something todo" @bind="newTodo" />
<button @onclick="AddTodo">Add todo</button>

@code {
    private List<TodoItem> todos = new();
    private string? newTodo;

    private void AddTodo()
    {
        if (!string.IsNullOrWhiteSpace(newTodo))
        {
            todos.Add(new TodoItem { Title = newTodo });
            newTodo = string.Empty;
        }
    }
}

And find NavMenu.razor file inside of the Shared folder on your Solution Explorer. Find the last item of menu divs and Add this code:

  <div class="nav-item px-3">
            <NavLink class="nav-link" href="todo">
                <span class="oi oi-list-rich" aria-hidden="true"></span> Todo
            </NavLink>
        </div>

You will have a NavMenu.Razor page like this:

<div class="top-row ps-3 navbar navbar-dark">
    <div class="container-fluid">
        <a class="navbar-brand" href="">BlazorApp1</a>
        <button title="Navigation menu" class="navbar-toggler" @onclick="ToggleNavMenu">
            <span class="navbar-toggler-icon"></span>
        </button>
    </div>
</div>

<div class="@NavMenuCssClass" @onclick="ToggleNavMenu">
    <nav class="flex-column">
        <div class="nav-item px-3">
            <NavLink class="nav-link" href="" Match="NavLinkMatch.All">
                <span class="oi oi-home" aria-hidden="true"></span> Home
            </NavLink>
        </div>
        <div class="nav-item px-3">
            <NavLink class="nav-link" href="counter">
                <span class="oi oi-plus" aria-hidden="true"></span> Counter
            </NavLink>
        </div>
        <div class="nav-item px-3">
            <NavLink class="nav-link" href="fetchdata">
                <span class="oi oi-list-rich" aria-hidden="true"></span> Fetch data
            </NavLink>
        </div>
        <div class="nav-item px-3">
            <NavLink class="nav-link" href="todo">
                <span class="oi oi-list-rich" aria-hidden="true"></span> Todo
            </NavLink>
        </div>
    </nav>
</div>

@code {
    private bool collapseNavMenu = true;

    private string? NavMenuCssClass => collapseNavMenu ? "collapse" : null;

    private void ToggleNavMenu()
    {
        collapseNavMenu = !collapseNavMenu;
    }
}

When you open the webpage you will see the Todo on your left navigation menu and then you will see your amazing Todo application like below:

If you want to use this component in other pages for example add this component on the home page. Go to your Index.Razor inside of the Pages folder and add this code :

<Todo/>

Your index.Razor will look like this

@page "/"

<PageTitle>Index</PageTitle>

<h1>Hello, Everyone!</h1>

Welcome to your new app. Hello 

<SurveyPrompt Title="How is Blazor working for you?" />




<Todo/>

Then we RUN our app oooorrr we can Hot Reload and we will see the result like below:

That is easy isn’t it ?

I hope that is helpful

May the knowledge be with you

Create Your First Blazor Application 1024 557 mezo

Create Your First Blazor Application

Hello My Fellow Padawans 🙂

Today I will tell you about a new Frontend Technology called “Blazor”. It sounds similar from somewhere… Yes Razor and yes its a Microsoft technology.

Ok but lets remember what is RAZOR first: Razor is a format for generating text-based content, like HTML. Razor files have cshtml or a razor file extension, and contain a mix of C# code along with HTML.

What is Blazor

Blazor is a user-interface framework built on .NET and Razor. Blazor applications can run on a server as part of an ASP.NET application or can be deployed to run in the browser on a user’s machine similar to a single-page application. It comes with 2 different app styles.

Blazor Server: is an implementation of the Blazor user-interface framework as part of the ASP.NET Core web development framework, deployed to a web server. Developing an application with Blazor Server generates HTML on a web server as it is requested by web site visitors, typically using a web browser. That HTML is then delivered to the visitor’s browser, and a two-way communication pipeline is maintained using ASP.NET Core SignalR and preferring a Web Sockets connection.

Users that click buttons, navigate, and perform other interactions with a Blazor Server application have their actions transmitted on this SignalR connection, and the server responds with user-interface updates using the same connection. The Blazor Server framework automatically updates the browser with the content generated on the web server.

Blazor WebAssembly: Shortened to Blazor WASM, is an implementation of the Blazor user-interface framework that runs on the HTML 5 standard WebAssembly runtime present in all modern browsers. The binary output of your application, the DLL files, are transmitted to the browser and run with a version of .NET that has been optimized to work with the WebAssembly runtime regardless of the underlying operating system of the device browsing to the website.

Since WebAssembly is a technology that runs entirely in the browser, it’s possible to deploy this model of the Blazor application using files that a web server doesn’t parse or interact with. This type of “static” approach reduces the requirements for a web server and shifts all processing for the application to the user’s machine.

Advanced processing and logic can take place in the browser. When the application needs data or to interact with other services, it can use standard web technologies to communicate with HTTP services.

How to build an application with Blazor

Start your Visual Studio 2022

Then create Blazor Server App and in the Configure your new project window, enter BlazorApp as the project name and select Next.

In the Additional information window, select .NET 7.0 (Standard Term Support) in the Framework drop-down if not already selected and click the Create button.

Your project is created and loaded in Visual Studio. Take a look at the contents of your project using Solution Explorer.

Several files were created to give you a simple Blazor app that is ready to run.

  • Program.cs is the entry point for the app that starts the server and where you configure the app services and middleware.
  • App.razor is the root component of the app.
  • The Pages directory contains some example web pages for the app.
  • BlazorApp.csproj defines the app project and its dependencies and can be viewed by double-clicking the BlazorApp project node in the Solution Explorer.
  • The launchSettings.json file inside the Properties directory defines different profile settings for the local development environment. A port number is automatically assigned at project creation and saved on this file.

To run your application basically click the Run button.

When you made some changes and you want to see your changes on the browser you need to click the Hot Reload button

If you want to make “Hot Reload” every time you save your changes then you need to click the menu button next to “Hot Reload” and select “Hot Reload on File Save” Then VS will watch your file save and refresh your web app on the browser to show your changes.

After you run your app you will see the default app of the Blazor.

Congrats you made your first Blazor App and make it run!

Last thing I want to show is how Blazor files and pages look like

_Host.cshtml This holds our application and renders page components.

@page "/"
@namespace BlazorApp1.Pages
@addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers
@{
    Layout = "_Layout";
}

<component type="typeof(App)" render-mode="ServerPrerendered" />

Index.razor : This is the Home page that you see on the screenshot below.

@page "/"

<PageTitle>Index</PageTitle>

<h1>Hello, Everyone!</h1>

Welcome to your new app. Hello 

<SurveyPrompt Title="How is Blazor working for you?" />

Counter.razor and this is the counter component as a page. It’s easy to render and reuse.

@page "/counter"

<PageTitle>Counter</PageTitle>

<h1>Counter</h1>

<p role="status">Current count: @currentCount</p>

<button class="btn btn-primary" @onclick="IncrementCount">Click me</button>

@code {
    private int currentCount = 0;

    private void IncrementCount()
    {
        currentCount++;
    }
}

Congrats 🙂 you open the new Blazor App and make that work

I will keep continuing to write about it coz I probably will use it for my company.

I hope that is helpful

May the knowledge be with you

Binary representation of floating-point numbers 1024 420 mezo

Binary representation of floating-point numbers

Have you ever considered the process by which computers store floating-point numbers such as 3.1416 (𝝿) or 9.109 × 10⁻³¹ (the mass of the electron in kg) in the memory which is limited by a finite number of ones and zeroes (aka bits)?

For integers (i.e., 17). It appears to be fairly straightforward. Assume we have 16 bits (2 bytes) to store the number. We can store integers between 0 and 65535 in 16 bits:

(0000000000000000)₂ = (0)₁₀

(0000000000010001)₂ =
    (1 × 2⁴) +
    (0 × 2³) +
    (0 × 2²) +
    (0 × 2¹) +
    (1 × 2⁰) = (17)₁₀

(1111111111111111)₂ =
    (1 × 2¹⁵) +
    (1 × 2¹⁴) +
    (1 × 2¹³) +
    (1 × 2¹²) +
    (1 × 2¹¹) +
    (1 × 2¹⁰) +
    (1 × 2⁹) +
    (1 × 2⁸) +
    (1 × 2⁷) +
    (1 × 2⁶) +
    (1 × 2⁵) +
    (1 × 2⁴) +
    (1 × 2³) +
    (1 × 2²) +
    (1 × 2¹) +
    (1 × 2⁰) = (65535)₁₀

On the off chance that we really want a marked number we might utilize two’s supplement and shift the scope of [0, 65535] towards the negative numbers. For this situation, our 16 pieces would address the numbers in a scope of [-32768, +32767].

As you would have seen, this approach will not permit you to address the numbers like – 27.15625 (numbers after the decimal point are simply being disregarded).

However, we’re not the initial ones who have seen this issue. Around ≈36 years ago a few brilliant people conquered this limit by presenting the IEEE 754 norm for floating-point arithmetic.

The IEEE 754 standard portrays the way (the framework) of utilizing those 16 bits (or 32, or 64 bits) to store the numbers of wider range, including the small floating numbers (smaller than 1 and closer to 0).

To get the thought behind the standard we could review the logical documentation – an approach to communicating numbers that are excessively huge or excessively little (for the most part would bring about a long string of digits) to be helpfully written in decimal structure.

As you might see from the picture, the number portrayal may be parted into three sections:

sign
division (otherwise known as significant) – the important digits (the significance, the payload) of the number
example – controls how far and in which direction to move the decimal point in the fraction
The base part we might preclude simply by settling on what it will be equivalent to. For our situation, we’ll involve 2 as a base.

Rather than utilizing every one of the 16 bits (or 32 bits, or 64 bits) to store the fraction of the number, we might share the bits and store a sign, type, and portion simultaneously. Contingent upon the numbers of bits that we will use to store the number we end up with the accompanying parts:

Floating-point formatTotal bitsSign bitsExponent bitsFraction bitsBase
Half-precision1615102
Single-precision3218232
Double-precision64111522

With this approach, the number of bits for the fraction has been reduced (i.e. for the 16-bits number it was reduced from 16 bits to 10 bits). It means that the fraction might take a narrower range of values now (losing some precision). However, since we also have an exponent part, it will actually increase the ultimate number range and also allow us to describe the numbers between 0 and 1 (if the exponent is negative).

For example, a signed 32-bit integer variable has a maximum value of 2³¹ − 1 = 2,147,483,647, whereas an IEEE 754 32-bit base-2 floating-point variable has a maximum value of ≈ 3.4028235 × 10³⁸.

To make it possible to have a negative exponent, the IEEE 754 standard uses the biased exponent. The idea is simple – subtract the bias from the exponent value to make it negative. For example, if the exponent has 5 bits, it might take the values from the range of [0, 31] (all values are positive here). But if we subtract the value of 15 from it, the range will be [-15, 16]. The number 15 is called bias, and it is being calculated by the following formula:

exponent_bias = 2 ^ (k−1) − 1

k - number of exponent bits

I’ve tried to describe the logic behind the converting of floating-point numbers from a binary format back to the decimal format on the image below. Hopefully, it will give you a better understanding of how the IEEE 754 standard works. The 16-bits number is being used here for simplicity, but the same approach works for 32-bits and 64-bits numbers as well.

Checkout the interactive version of this diagram to play around with setting bits on and off, and seeing how it would influence the final result

Here is the number ranges that different floating-point formats support:

Floating-point formatExp minExp maxRangeMin positive
Half-precision−14+15±65,5046.10 × 10⁻⁵
Single-precision−126+127±3.4028235 × 10³⁸1.18 × 10⁻³⁸

Be aware that this is by no means a complete and sufficient overview of the IEEE 754 standard. It is rather a simplified and basic overview. Several corner cases were omitted in the examples above for simplicity of presentation (i.e. -0-∞+∞ and NaN (not a number) values)

Code examples

In the javascript-algorithms repository, I’ve added a source code of binary-to-decimal converters that were used in the interactive example above.

Below you may find an example of how to get the binary representation of the floating-point numbers in JavaScript. JavaScript is a pretty high-level language, and the example might be too verbose and not as straightforward as in lower-level languages, but still it is something you may experiment with directly in the browser:

See the Pen bitsToFloat.js by mzekiosmancik (@mzekiosmancik) on CodePen.

References

You might also want to check out the following resources to get a deeper understanding of the binary representation of floating-point numbers:

Welcome to AI-Powered Blogging 1024 1024 mezo

Welcome to AI-Powered Blogging

Artificial intelligence (AI) has made significant strides in recent years and is now being utilized in a variety of industries, including blogging. AI has the potential to revolutionize the way we create and consume content online, and it is important for bloggers to understand how it is being used in the industry. In this article, we’ll explore the various ways in which AI is being utilized in blogging and how it could shape the future of the industry.

One way AI is being used in blogging is through the use of natural language processing (NLP). NLP allows computers to understand and analyze human language, which can be used to improve the accuracy of content recommendations and suggestions. For example, if you’re writing a blog post and you want to include a related article, an AI tool could suggest relevant content based on the keywords and themes in your post. This can help bloggers create more coherent and cohesive content and provide a better experience for their readers.

Another way AI is being utilized in blogging is through the use of chatbots. Chatbots are computer programs that are designed to simulate conversation with human users, and they’re often used to provide customer service or support. In the context of blogging, chatbots can be used to interact with readers and provide them with personalized recommendations based on their reading history. This can help build a sense of community and engagement with readers and improve the overall user experience.

Created by Dall-E by OpenAI

AI can also be used to optimize the design and layout of a blog. For example, an AI tool could analyze user data and suggest the best layout for a blog based on factors such as the type of content being shared and the target audience. This can help bloggers create a more user-friendly and engaging experience for their readers.

In addition to these uses, AI can also help improve the speed and efficiency of content creation. For example, AI tools can help writers generate ideas for blog posts, identify the best sources for research, and even write drafts of articles. While these tools are not meant to replace human writers, they can help streamline the content creation process and save time for bloggers.

One area where AI is particularly useful is in content curation. With the vast amount of information available online, it can be difficult for bloggers to keep up with the latest trends and news in their industry. AI tools can help by curating relevant content and delivering it to bloggers in real-time. This can help bloggers stay up-to-date and provide their readers with the latest and most relevant information.

AI is also being used to improve the accuracy of spelling and grammar in blog posts. With the help of AI tools, bloggers can catch mistakes and typos before they are published, helping to improve the overall quality of their content.

In addition to these uses, AI is being utilized in the field of search engine optimization (SEO). SEO is the practice of optimizing a website in order to rank higher in search engine results. AI tools can help bloggers optimize their content for search engines by analyzing user data and suggesting the most effective keywords and phrases to use. This can help bloggers increase their visibility and reach a wider audience.

AI is also being used to improve the personalized recommendations provided to readers. By analyzing user data, AI tools can suggest content that is most relevant and interesting to individual readers. This can help improve the user experience and keep readers coming back for more.

Despite all of these potential uses, it’s important to note that AI is still in its early stages and there are limitations to what it can do. While AI can help improve the accuracy and efficiency of content creation, it is not yet able to replicate the creativity and nuance of human writing. As such, it is unlikely that AI will

Created by Dall-E by OpenAI

what is chat gpt

CHAT-GPT (short for “Chat Generative Pre-training Transformer”) is a variant of the GPT (Generative Pre-training Transformer) language model developed by OpenAI. It is designed to generate human-like text and responses in the context of a conversation, making it well-suited for use in chatbots and virtual assistants.

The GPT model was first introduced by OpenAI in 2018 as a way to generate natural language text that is difficult to distinguish from text written by humans. It was trained on a massive dataset of human-generated text and was able to generate coherent and coherent paragraphs and even entire articles.

CHAT-GPT builds on the capabilities of the original GPT model by adding the ability to track context and engage in conversation with users. It does this by using a conversational data set to learn about common patterns and structures in human conversation. This allows it to generate responses that are more natural and contextually appropriate in a conversation.

CHAT-GPT has been used in a variety of applications, including virtual assistants, chatbots, and even language translation. Its ability to generate human-like text and engage in conversation has made it a popular choice for developers looking to build natural language processing applications.

While CHAT-GPT and other AI language models have made significant strides in generating human-like text, it is important to note that they are not yet able to fully replicate the complexity and nuance of human language. However, as AI technologies continue to evolve, it is likely that they will become increasingly sophisticated and capable of more advanced language processing tasks.

This Article created by AI 🙂

Create a React Native Web, Android, and IOS project with Expo CLI 1024 635 mezo

Create a React Native Web, Android, and IOS project with Expo CLI

Hello fellow programmer padawans

As you can understand from the title I will tell you how to create a web, Android, and IOS project with React Native and Expo. First, we need the Expo CLI package.

What’s Expo CLI?

Expo CLI is the npm package that creates a project that we can test on our devices. We won’t need to write codes on Xcode or Android Studio. We only need Visual Studio Code and we can write codes for 3 different environments.

First things first, we need NodeJs installed on our computer if you don’t have it you can download it here: https://nodejs.org/en/.

Install Expo and Create Project

To install the Expo CLI you need to open Node.js Command Prompt and run this code

npm install -g expo-cli

To create the project run this code below

expo init ProjectName

Template Selection

As soon as you make the code creation command run, you will see the selection menu as shown below. We need to select a template depending on our needs. I prefer to select a TABS template, it’s a TypeScript and a very good sample to learn and to see the structure of the project.

Start your project and see your app on your device

After the project creation is over we need to go inside the project folder from Nodejs Command Prompt to start your project.

expo start

Then we can see a website and a barcode on the command prompt, that barcode is the magic. I will show you…

After you see all these screens you now are ready to test your app on your device. Download the Expo app from the Apple App Store or Google Play and create an account.

Open your Camera and read the barcode. It will then ask you to open in the Expo app, do it and Voila! Your app is working on your phone or tablet.

First, open the project folder with Visual Studio Code so you can checkout the folder and file structure. Then you can find the Screens folder and make some changes on the TabScreenOne.tsx or TabScreenTwo.tsx files and you will see your app is changing on your device as well.

That’s all for now! I will write about components on React Native on my next post.

Thanks for reading

May the force be with you. 

Levenshtein Distance Algorithm 1024 668 mezo

Levenshtein Distance Algorithm

Hello my fellow Padawans 

Couple days ago I had to use an algorithm for comparing string and I want to write something about Levenshtein Algorithm. This algorithm is for measure the metric distance between 2 string text. Informally, the Levenshtein distance between two words is the minimum number of single-character edits (insertions, deletions or substitutions) required to change one word into the other. It is named after the Soviet mathematician Vladimir Levenshtein, who considered this distance in 1965.

Mathematically, the Levenshtein distance between two strings a, b (of length |a| and |b| respectively) is given by leva,b(|a|,|b|)

where 1(ai≠bi) is the indicator function equal to 0 when ai≠bi and equal to 1 otherwise, and leva, b(i,j) is the distance between the first i characters of a and the first j characters of b.

Note that the first element in the minimum corresponds to deletion (from a to b), the second to insertion and the third to match or mismatch, depending on whether the respective symbols are the same.

We can use this algorithm for string matching and spell checking

This algorithm calculates the number of edit operation that are necessary to modify one string to another string. Fro using this algorithm for dynamic programming we can use these steps :
1- A matrix is initialized measuring in the (m, n) cells the Levenshtein distance between the m-character prefix of one with the n-prefix of the other word.
2 – The matrix can be filled from the upper left to the lower right corner.
3- Each jump horizontally or vertically corresponds to an insert or a delete, respectively.
4- The cost is normally set to 1 for each of the operations.
5- The diagonal jump can cost either one, if the two characters in the row and column do not match else 0, if they match. Each cell always minimizes the cost locally.
6- This way the number in the lower right corner is the Levenshtein distance between these words.

An example that features the comparison of “HONDA” and “HYUNDAI”,

Following are two representations: Levenshtein distance between “HONDA” and “HYUNDAI” is 3.

The Levenshtein distance can also be computed between two longer strings. But the cost to compute it, which is roughly proportional to the product of the two string lengths, makes this impractical. Thus, when used to aid in fuzzy string searching in applications such as record linkage, the compared strings are usually short to help improve speed of comparisons.

Here’s the code that you can use the Levenshtein Distance and calculate percentage between 2 string.

See the Pen levenshtein.js by mzekiosmancik (@mzekiosmancik) on CodePen.

Microsoft Edge Chromium new browser for Windows and Mac OS 500 334 mezo

Microsoft Edge Chromium new browser for Windows and Mac OS

Microsoft officially launched new Edge Chromium browser for Windows and MacOS. A stable version of Edge Chromium is available for everyone to download here. Microsoft initially targeting Edge at enterprise users of Windows and macOS , but consumers will be able to manually install it .

In coming months, Edge Chromium will be available with the Windows 10 updates for fully replace the existing built-in browser. Microsoft taking things slowly and carefully about bringing the new Edge Chromium gradually to groups of Windows 10 users through Windows 10 update.

Microsoft working with Google to make Edge faster and stable. Also Edge Chromium will support Chrome extensions . if you’re using Chrome you can sync your history settings and extensions. You can choose from three different levels to avoid being tracked on the web in Edge, and the default setting will block trackers from sites you haven’t visited before. This makes sure content and ads are less personalized and harmful trackers are blocked. There’s also a strict setting that blocks the majority of trackers on the web, but that could mean some parts of sites fail to load or might not work correctly. If you’re familiar with Ghostery, then Microsoft’s built-in protection Edge is similar.

It’s also available for IOS , Android , MacOS , Windows 10, 8.1 , 8 , 7

I hope you will like new browser.
Stay with wisdom my fellow Padawan 🙂
Peace
Mezo…

Vue.js 2 Cookbook 302 373 mezo

Vue.js 2 Cookbook

Andrea Passaglia dan Vue.js ogrenebilmek profesyonel web uygulamalari gelistirebilmeniz icin 101 hands on Vue.js 2 ornegi ve ayrintili anlatimi.

Indirmek icin tiklayiniz…

Modern Python Cookbook 302 373 mezo

Modern Python Cookbook

Indirmek icin tiklayiniz…

Mastering OpenCV with Practical Computer Vision Projects 302 373 mezo

Mastering OpenCV with Practical Computer Vision Projects

Indirmek icin tiklayiniz…

Expert Delphi 302 373 mezo

Expert Delphi

Indirmek icin tiklayiniz…

Angular Test-Driven Development 302 373 mezo

Angular Test-Driven Development

Indirmek icin tiklayiniz…

Mastering Qt5 302 373 mezo

Mastering Qt5

İndirmek için tıklayınız…

Artificial Intelligence with Phyton 302 373 mezo

Artificial Intelligence with Phyton

Click for Download PDF…

PostgreSQL Development Essentials 302 373 mezo

PostgreSQL Development Essentials

indirmek için tıklayınız…

Andriod UI 302 373 mezo

Andriod UI

Android UI Design örnek kodları ve birden fazla ortam için dönüştürülmüş formatları ile Android kullanıcı arayüzü tasarımında büyük ilerleme sağlayacağınız bir kitap olacak.

İndirmek için tıklayınız…

Training – ASP.NET MVC 4 Application Development 376 292 mezo

Training – ASP.NET MVC 4 Application Development

Hello my fellow Padawans  

I found this complete set of ASP.Net MVC 4 training and i thought that it will be so useful for everyone. Its from pluralsight but you don’t need to login or sign up to web site. I watched all of it and I really like style of Scott Allen. Here’s the content of this training.

77-asp-net-mvc-4-codingcluster-745669
  • Introduction
  • Web Installer
  • The Tools
  • New Project
  • Modules, Views, Controller
  • Making Changes
  • Unit Testing
  • JavaScript and CSS
  • Summary

Click Here for watch Videos 

Stay with force

Mezo

The Real Reasons You’re Unhappy at Work 375 375 mezo

The Real Reasons You’re Unhappy at Work

You hate your boss. Your coworkers give you the cold shoulder. Your to-do list is either painfully boring or terrifyingly long. These sound like valid reasons to hate your job. But in truth, they’re only the surface cause of your misery. Dig deeper, and you’ll discover underlying reasons you’re unhappy at work that are, fortunately, fixable.
“The ‘I hate my job because (fill in the blank)’ usually exists because too much time has passed where the ‘blank’ has gone unattended to,” says human resources expert Tiffani Murray. “Or other circumstances make the ‘blank’ appear bigger than it ought to be. Stepping back, assessing where you want to be in your job and career and digging deeper into the hatred is the way to find resolution and determine a next step.”
Keep reading for eight reasons you might be unhappy at work–and how to solve them.

What You Say: “I’m Bored at Work”

The_Real_Reasons_You’re_Unhappy-17d30a97363ddfcf4ddd4086a886fb95
The Real Reason: Your efforts have been unrecognized.
The Symptoms: You feel unmotivated. You seek out diversions to real work, such as updating social media or shopping a flash sale.
The Solution: Seek out feedback.
If you’re bored at work, it could be because you’ve been doing the same thing for too long and you’re ready for a change. Or it could be that you feel no matter how hard you work, you never get that “atta girl!” you deserve. If either is the case, seeking out feedback from your boss is a way to end this morale killer.
“A lot of times, a supervisor is not aware that someone is looking to move up the ladder,” Murray says. “If you don’t say anything, and you appear to be doing your job well, the thought usually is, ‘Let’s keep that person in that job.’ You have to take the initiative and let your boss know, ‘I want more opportunities to learn more things.’”
So, the next time you submit that big project and get zero feedback in return, don’t let it discourage you. Instead, ask your boss what she thought of it, and ask her for something more challenging next time around.

What You Say: “The Hours are Too Long”
The Real Reason: You’re overloaded with responsibilities but are afraid to push back and say, “No, I can’t take on more.”
The Symptoms: You’re the first in and/or the last to leave, and even when you’re not at work you have a Pavlovian response to the “ding” from your smartphone.
The Solution: Talk to your boss about suggestions on ways to better organize and prioritize your workload.
“Some people don’t know how to say ‘no’ to added responsibilities, and with the way the economy has been there’s been a lot of fear around saying ‘no,’” says Murray. “But now that the economy is turning around, tell your boss you need to discuss your workload and get better ideas on how to organize it.”
Ideally, having this conversation will open your boss’ eyes to exactly how much you have to get done–and how impossible that is within a 40-hour workweek. Also, she might give you guidance on what to prioritize and what deadlines can be spaced out a bit more. This can give you some much-needed breathing room (and some recognition from a supervisor who might not have realized how much you’ve been working).

What You Say: “I Hate My Co-workers”
The_Real_Reasons_You’re_Unhappy-8e10051a986eb8f983038520cf91d789The Real Reason: The problem might not be the people but rather the culture of the organization.
The Symptoms: You feel ganged up on or left out, or you find yourself arguing–a lot.
The Solution: If the culture isn’t the right match for you, you should consider moving on.
If the workplace culture doesn’t mesh with your personality, odds are the people there won’t either. For example, if the business feeds on competition amongst coworkers, and you’re not a competitive type, you’re going to chafe at that type of energy. And that’s going to make you hate the guy who’s constantly trying to one-up you, even if in doing so he’s just getting his job done.
If leaving the job isn’t feasible, figure out how to make the environment less stressful. If there are people you particularly abhor, make sure you take your lunch an hour after or before they do. Or request a desk change. And think about the end game. “Focus on your work and your goals,” says Murray. “Give yourself an 18-24 month time limit. During that time, strive for a promotion and get it. Then, start looking for your next job.”
Before doing something that drastic, realize that work friends often only last as long as you’re at that job. Focus instead on strengthening your friendships outside of the office.

What You Say: “I’m Underpaid.”
The Real Reason: You feel stifled and unfulfilled.
The Symptoms: Simple–you look at your paycheck and grumble.
The Solution: Find out what opportunities exist for you not only to get promoted to a higher-paying job, but to contribute more to growing the company.
Making a lot of money definitely makes life easier. You pay your bills, you even have a little left over for the fun stuff. But if you hang your work happiness on that biweekly paycheck, you’re giving short shrift to what happens every other day of the week. You have to show up, you have to perform, and, ideally, you have to feel satisfied by the work you do. If you feel fulfilled professionally and are given the license to be creative and develop new ideas on the job, you will get satisfaction that goes beyond the paycheck.
“People want to be heard,” says Sandy Mazur, division president at Spherion Staffing Services. “Base salary is a way of attracting someone to a company. But if you look at what makes people stay in their jobs, base pay takes a backseat to how well they can advance their careers. People also want to know their opinion matters. Then you take more ownership of the job.”
Ask your boss for ways you can contribute more to the team. Give her ideas on how processes could be done more efficiently. Have an idea for a new product? Take a deep breath and pitch it. When your paycheck isn’t your only payoff at work, you’re bound to feel more fulfilled.

What You Say: “I Feel Trapped in this Job”
The Real Reason: You are bored and unchallenged by your job, yet quitting is not an option.
The Symptoms: You dread Mondays and the days feel incredibly long.
The Solution: Find inspiration in places outside of work.
One in four workers rates his job satisfaction as fair or poor, according to Spherion’s Emerging Workforce Study. That’s a lot of bored employees. “When you spend so much time doing boring things, it affects other parts of your life,” says Nicole Williams, LinkedIn’s Career Expert and author of “Girl on Top.” “You feel really tired, not because you are tired, but because you can’t get out of the rut.”
To motivate yourself, find a mentor or go to a career-related conference that will remind you of why you chose your profession in the first place. Or become a mentor yourself. Sometimes motivating someone else can have the benefit of motivating you as well, Williams says.
If that doesn’t work, stop trying to find your inspiration at work. “Physically challenge yourself,” says Williams. “Take a walk. Go for a run. Or find something else you are interested in and do that. When you get involved in something you are interested in, your workday can feel less boring.”
To solve the “trapped” feeling on the job, ask yourself when was the last time you took on an assignment that truly scared you. If it’s been a while, have a conversation with your supervisor about taking on extra responsibility. Trying something new at work can be equally liberating.

What You Say: “I Hate My Boss”
The_Real_Reasons_You’re_Unhappy-c9bfdcd74e077caa5416cc3217900f7fThe Real Reason: Your boss doesn’t fully recognize your efforts causing you to feel unappreciated and resentful.
The Symptoms: When his name is in your inbox or you hear his voice coming down the hall, you cringe.
The Solution: Ask your boss for feedback on your performance, and give him some feedback on his.
If someone is constantly telling you what to do but never giving you any recognition for your efforts, yeah, it’s easy to hate that guy. The same is true if his or her management style is contrary to your personality. If your boss uses yelling and name-calling to get results, and that’s not what motivates you, you will learn to dread those weekly staff meetings.
But hatred can be diffused by communication, says Williams. “A lot of times bosses don’t recognize that what they are doing is causing problems,” she says. For example, if your boss is a screamer Williams advises you tell her, “I know you must be frustrated, and I know it’s a hard job, but I’m going to perform better if you don’t scream at me.” One of Williams’ clients tried this approach and was successful. “The boss said, ‘I didn’t realize I was raising my voice to that degree.’ There was surprisingly receptive feedback to that conversation. And often, negative boss behavior is bully behavior. Once they’re called out on it, they usually go and pick on someone else.”

What You Say: “I Chose the Wrong Career”
The Real Reason: You’ve given up on your dreams.
The Symptoms: Feeling discontented and as if work is something you have to do, not something you could ever enjoy.
The Solution: Pursue your dream outside the office.
Maybe you chose the career your parents wanted for you, rather than the one you wanted. Or you did all the hard work to get the necessary training and degrees only to realize that you hate the work you now have to do. Either way, you’re no longer chasing your dream, and that can leave you discouraged.
“Women rationalize by saying, ‘I should relocate for this job. I need the salary to support my family. I spent six years in school for this.’ They’re talking about what they should do and have to do, instead of living from their authentic self,” says Career Expert Cornelia Shipley. “Solving this involves reconnecting to your dream in some way.”
Maybe you wanted to be a ballerina but your parents encouraged you to get your MBA instead. S,o start taking dance classes again, teach dance or join the board at your local dance company. Maybe you became a doctor because you wanted to help the poor, but your student loans quickly led you to a different path. Volunteer at a clinic in a low-income neighborhood.
“Ask yourself, ‘What is the truth behind my dream today, and how do I incorporate that dream into my life?’” Shipley says. “If you connect the dots, you will get to the truth of what it is you truly want to do.”

What You Say: “I’ve Hit the Ceiling”
The_Real_Reasons_You’re_Unhappy-01ba4562048b38dc4f18e6f38352870aThe Real Reason: You’ve given up control of your career to someone else.
The Symptoms: You feel powerless over your career and don’t see a way out of the job you’re in.
The Solution: Communicate where you want to be and ask for help getting there.
You’ve been walking into the same cubicle for five years, doing the same work, barely getting cost-of-living raises, and you don’t see a way that things will change. Maybe your company is small and has very little opportunities for advancement or you’ve looked for other jobs but nothing has panned out. And so you work, watch the clock and have stopped planning for the future. If so, you’re not alone: only 28 percent of employees are satisfied with their current growth and earnings potential, according to data from Spherion’s Emerging Workforce Study.
Instead of puttering along in neutral, you need to create a new path for yourself. Don’t wait for your boss to suddenly notice you. Instead, “You have to decide which job you want and go after it,” says Shipley. Approach your boss about what opportunities there are for your advancement. Talk to human resources about job openings in other departments that might suit you. Get the extra schooling or training that will help make you more attractive to employers. But most of all, take control of your own career.
“If you put your boss in charge of making things happen for you, you will be disappointed,” says Shipley.

 

link

Windows 8 Store App _ Youtube Video on Media Element 935 593 mezo

Windows 8 Store App _ Youtube Video on Media Element

Hi everyone

I want to show you to how to play a youtube video on Windows 8 Store App Media Element control. We have to use 3th part references called “MyToolKit”. MyToolKit is have a class named Youtube. That class help us to geting video and play on our control.  You can take a look in here http://mytoolkit.codeplex.com/ .

In this site they said that if you want to use this class the NuGet Package is recomended.

Ok lets start and play any video on Windows 8 Store App

First of all we have to install MyToolKit on our project. Open NuGet Package Manager from Tools->Library Package Manager -> Manage Nuget Packages for Solution

Select Online and searh MyToolKit

Thats our package we find it. We have to click on Install button and select assembly which one will use this.

MyToolKit references will add on our project after select an assembly and click OK button.  That was the diffucult side. Lets check out the simple side of our project.

I added a MediaElement control on my StoreApp xaml page and give a name property…

<Pagex:Class=”youtube.MainPage”xmlns=”http://schemas.microsoft.com/winfx/2006/xaml/presentation”

xmlns:x=”http://schemas.microsoft.com/winfx/2006/xaml”

xmlns:local=”using:youtube”

xmlns:d=”http://schemas.microsoft.com/expression/blend/2008″

xmlns:mc=”http://schemas.openxmlformats.org/markup-compatibility/2006″

mc:Ignorable=”d”>

<Grid Background=”{StaticResource ApplicationPageBackgroundThemeBrush}”>

<MediaElement Name=”mediaYoutube” HorizontalAlignment=”Left” Height=”522″

Margin=”152,201,0,0″ VerticalAlignment=”Top” Width=”1111″/>

<Button Name=”btnPlay” Content=”Play” HorizontalAlignment=”Left” Margin=”904,71,0,0″

VerticalAlignment=”Top”/>

<TextBox Name=”txtYoutubeID” HorizontalAlignment=”Left” Margin=”529,77,0,0″

TextWrapping=”Wrap” Text=”TextBox” VerticalAlignment=”Top” Width=”370″/>

</Grid>

</Page>

 

 

Last thing we have to do write a little code on btnPlay_Click event

private async void btnPlay_Click(object sender, RoutedEventArgs e){var url = await YouTube.GetVideoUriAsync(txtYoutubeID.Text, YouTubeQuality.Quality480P);

mediaYoutube.Source = url.Uri;

}

 

Thats it. Now we have to select a youtube video and get the video id then play on our project then watch the video.

if youtube link is http://www.youtube.com/watch?v=hNpQpjyc9C8 . this videos ID is going to be “hNpQpjyc9C8” . If we write it to our textbox we can watch this video on our Windows Store App.

Like this.

You can download the source code in here http://sdrv.ms/YfrMdG

I hope that is helpful

May the knowledge be with you

M.Zeki Osmancık

Visual Studio 2012 Update 1 Now Available 474 642 mezo

Visual Studio 2012 Update 1 Now Available

S. Somasegar today announced the availability of Visual Studio 2012 Update 1.

He said that this update is so important for developers because this isn’t just about bug fixes, though it contains quite a few of those to measurably address issues reported through Connect, UserVoice, and Windows Error Reporting.  This is also delivers a wealth of new functionality into Visual Studio 2012.  The new functionality in Update 1 primarily spans four areas of investment: Windows development, SharePoint development, agile teams, and continuous quality.

You can download Visual Studio Update 1 in  here (see “Visual Studio 2012 Update 1” under the “Additional software” section)

I hope that is helpful

May the knowledge be with you

M.Zeki Osmancık

Windows 8 Store Apps Using Localization 935 590 mezo

Windows 8 Store Apps Using Localization

Hi Friends
In this article i want to explain about localization on Windows Store Apps. If you built an application and want to make this application world wide, you have to add multi-language in your application.
So lets start the sample about using localization on Windows Store Applications.
First of all we need to add *.resw files to project. This file is string resource files and we need to add resw file for every language.

I added 3 *.resw file in my project for English German and Turkish languages in different folders with same name.

Then i modifying my *.resw files for every language:
Resources.resw file in ”en” folder

Resources.resw file in ”gr” folder

Resources.resw file in ”tr” folder

In my MainPage.xaml page i place 1 combobox 3 TextBlock and 2 Textbox.

 

<Pagex:Class=”localizationsample.MainPage”xmlns=”http://schemas.microsoft.com/winfx/2006/xaml/presentation”

xmlns:x=”http://schemas.microsoft.com/winfx/2006/xaml”

xmlns:local=”using:localizationsample”

xmlns:d=”http://schemas.microsoft.com/expression/blend/2008″

xmlns:mc=”http://schemas.openxmlformats.org/markup-compatibility/2006″

mc:Ignorable=”d”>

 

<Grid Background=”{StaticResource ApplicationPageBackgroundThemeBrush}”>

<TextBlock Name=”txtUserName” HorizontalAlignment=”Left” Margin=”316,304,0,0″ TextWrapping=”Wrap” Text=”User Name” VerticalAlignment=”Top” FontSize=”36″/>

<TextBlock Name=”txtPassword” HorizontalAlignment=”Left” Margin=”316,353,0,0″ TextWrapping=”Wrap” Text=”Password” VerticalAlignment=”Top” FontSize=”36″/>

<ComboBox Name=”cmbLanguage” HorizontalAlignment=”Left” Margin=”591,38,0,0″ VerticalAlignment=”Top” Width=”205″ SelectionChanged=”ComboBox_SelectionChanged_1″/>

<TextBlock HorizontalAlignment=”Left” Margin=”381,38,0,0″ TextWrapping=”Wrap” Text=”Choose Language” VerticalAlignment=”Top” FontSize=”22″/>

<TextBox HorizontalAlignment=”Left” Margin=”553,304,0,0″ TextWrapping=”Wrap” VerticalAlignment=”Top” Width=”333″/>

<TextBox HorizontalAlignment=”Left” Margin=”553,353,0,0″ TextWrapping=”Wrap” VerticalAlignment=”Top” Width=”333″/>

 

</Grid>

</Page>

 

 

 

Write very simple code for add items in combobox.

cmbLanguage.Items.Add(“en”);cmbLanguage.Items.Add(“tr”);cmbLanguage.Items.Add(“gr”);

When you select a language on combobox ,language file will change. For doing this process we must write some code on combobox selectionChanged event.

var context = new ResourceContext();var selectedLanguage = cmbLanguage.SelectedItem;if (selectedLanguage != null){var lang = new List<string>();lang.Add(selectedLanguage.ToString());

context.Languages = lang;

var resourceStringMap = ResourceManager.Current.MainResourceMap.GetSubtree(“Resources”);

this.txtUserName.Text = resourceStringMap.GetValue(“string1”, context).ValueAsString;

this.txtPassword.Text = resourceStringMap.GetValue(“string2”,context).ValueAsString;

}

ResourceContext reads the *.resw files. If we read our language files we can read ids of contents and call them where ever we want.

Our language changer is ready just test.

I hope that is helpful

May the knowledge be with you

M.Zeki Osmancık

    Join our Newsletter

    We'll send you newsletters with news, tips & tricks. No spams here.