TechSapphire Wednesday, 2018-10-17, 12:45 PM
Site menu
Login form
News
Play Games
  • Deep Freeze
  • Ice Slide
  • Gyroball
  • Fat Fish
  • Bush Royal Rampage
  • Main » 2011 » October » 5 » Writing Text to image using Vb.Net Or writing text to image .net Or writing to image file .Net
    7:18 PM
    Writing Text to image using Vb.Net Or writing text to image .net Or writing to image file .Net
    Writing Text to image using Vb.Net Or writing text to image .net Or writing to image file .Net
    You can write text to image pro grammatically using VB.Net. This is sample code in VB.Net.
    Solution:
    Namespace required:

    Imports System.Drawing

    Imports System.Drawing.Imaging

    Source Code:

           Dim objBitmap As New Bitmap(100, 50)

            Dim objGraphics As Graphics = Graphics.FromImage(objBitmap)

            Dim objPoint As New PointF(5.0F, 5.0F)

            objGraphics.FillRectangle(Brushes.White, 0, 0, Width, Height)

            objGraphics.DrawString(Me.TextBox1.Text, "selectedfont", Brushes.Black, objPoint)

            objBitmap.Save("Result.JPG", ImageFormat.Jpeg)

    Explanation:

    At place of selected font you have to specify name of font, this is of type drawing font.

    If want to check live project example download this project. Here you would find installation of font run time using Vb.Net.


    Move to solution page.

    Category: Programming | Views: 1027 | Added by: Admin | Tags: how to write text to image using vb, text image .net, write image with text vb, write text to image .net | Rating: 2.0/1
    Total comments: 1
    1  
    Pin my tail and call me a doenyk, that really helped.

    Only registered users can add comments.
    [ Registration | Login ]
    Categories
    Programming [27]
    Tips for programming
    Security [2]
    Security Tips
    Google [1]
    Use google faster then ever you use
    Project [14]
    HTML [2]
    Electronics [0]
    Data Structure [0]
    Database [16]
    SQL SERVER
    SSRS [1]
    Sql Server Reporting Services
    Copyright MyCorp © 2018