image

MS WORD

    Next

  • 1. How to execute a macro upon opening a document
    Can someone tell me how to make a macro automatically execute when a document first opens? I also need to know how to change the setting found in tools/options using VBA. Thanks, Keith
  • 2. update fields macros
    I have a template which is standard for all kind of studies in the report. I have created user form kind of template which let person write in all the fields and at the end when update details button is clicked it will update TOC, all fields etc. But, some time when it updating everything the out of memonry error message comes. Also macro runs so fast that one of my field is not updated and I have to go manually update it. Is there any way to slow down macro little bit or pause it in between so every thing is updated properly and also, error do not appear. thanks Resh
  • 3. execute some code before printing a document
    Is it possible? I 've to ensure that some words have not been used in the document. Does really word have just the events NewDocument, OpenDocument, CloseDocument? thanks Agostino ---------------------------------------------------------------- CEDAP Informatica SRL via Caboto 20/c 33170 Pordenone italy ----------------------------------------------------------------
  • 4. Increasing max-length of drop down menu
    Is there a way to increase the max length of a pull down menu? I believe the max-length for this is set to 31 chars. Is there a way to increase this? Thanks, Frederick S.
  • 5. Save AS ??
    Hi Greg, Instead of creating a filesystemobject, why not use the built-in FileCopy statement? FileCopy Source:="L:\Path\FileName.Extension", Destination:="C:\Test\FileName.Extension" HTH, Dave "Greg" < XXXX@XXXXX.COM > wrote in message news: XXXX@XXXXX.COM ... > I would like to change the name of the log file that is created to save as applog "date" in this routine but I can't get it to work. Any help would be great. TIA > > Sub Main() > Dim fsf As Object > Dim f As Object > Dim sFrom As String > Dim sTo As String > On Error GoTo errhndle > > Set fsf = CreateObject("Scripting.FileSystemObject") > Set f = fsf.CreateTextFile("\\mypath\applog.log", True) > > sFrom = "\\mypath\file1.txt": sTo = "\\mypath1\folder1 " > fsf.copyfile sFrom, sTo > sFrom = "\\mypath\file2.txt": sTo = "\\mypath2\folder2 " > fsf.copyfile sFrom, sTo > sFrom = "\\mypath\file3.txt": sTo = "\\mypath3\folder3 " > fsf.copyfile sFrom, sTo > sFrom = "\\mypath\file4.txt": sTo = "\\mypath4\folder4 " > fsf.copyfile sFrom, sTo > sFrom = "\\mypath\file5.txt": sTo = "\\mypath4\folder5 " > fsf.copyfile sFrom, sTo > > > f.Close > > Exit Sub > > errhndle: > > f.WriteLine "Failure copying from " & sFrom & _ > " to " & sTo & Now > > Resume Next > End Sub

image

Postby cmFuaQ » Sun, 17 Sep 2006 12:03:01 GMT

can any tell me how to recognize different type of images like jpg, gif, bmp 
inside word Doc using VBA.

Re: image

Postby Cindy M. » Sun, 17 Sep 2006 23:34:30 GMT

Hi =?Utf-8?B?cmFuaQ==?=,

This isn't possible. Word tends to convert graphics to file types it can work 
with, not maintain the original graphic format. And even when it does (later 
versions retain JPG, for example), the object model doesn't expose any of this 
information.

Cindy Meister
INTER-Solutions, Switzerland
 http://www.**--****.com/ (last update Jun 17 2005)
 http://www.**--****.com/ 

This reply is posted in the Newsgroup; please post any follow question or reply 
in the newsgroup and not by e-mail :-)


Re: image

Postby cmFuaQ » Mon, 18 Sep 2006 09:01:01 GMT

Thanks Cindy,

This was quite useful information.





Similar Threads:

1.Control image property locking image file even after image cleared

Hi All

When I set a buttons image to a image file in the properties window it seems 
to lock the file even if I clear the button image property in the properties 
window

Sometimes I am editing the icon/bitmap and connect it to the button to see 
what it looks like

Then I want to make further changes so I clear the image from the buttons 
image property, but when I edit and try to save the image file I get a 
message saying it is in use by another program

I have to close the VB.net 2005 solution to free it up


Any ideas

Regards
Steve 


2.VB6 create image, save image to memory, send image to asp

Ok, here is the deal, ive search all around and no one has this.

In visual basic 6 ( activex dll )
1. create a image in a picturebox control
2. save the picture in memory (not to disk)
3. place the saved picture into a stream or object that can be passed
to an ASP page

In asp classic
1. calls activex dll to generate image
2. set varable/object to the resulting image
3. display the image in the http ( as a locally cached .jpg, bmp, gif
or png, i dont care about format )

3.Joining multiple images together to form 1 single .jpg image

On Jun 30, 8:05爌m, Onur G鼁el < XXXX@XXXXX.COM > wrote:
> On Jun 30, 6:43爌m, Paul < XXXX@XXXXX.COM > wrote:
>
>
>
>
>
> > Hi,
>
> > I am having trouble getting my VB app to join images on top of each
> > other to form a single file.
>
> > All my images are the same width and height and I would like to join
> > them together, one of top of the other.
>
> > My code compiles but does not give the right result!
>
> > ????Dim jpg1 As String = "c:\existing_image_1.jpg"
> > ????Dim jpg2 As String = "c:\existing_image_2.jpg"
> > ????Dim jpg3 As String = "c:\new_image.jpg"
>
> > ????Dim img1 As Image = Image.FromFile(jpg1)
> > ????Dim img2 As Image = Image.FromFile(jpg2)
>
> > ????Dim width As Integer = Math.Max(img1.Width, img2.Width)
> > ????Dim height As Integer = img1.Height + img2.Height + 20
>
> > ????Dim img3 As New Bitmap(width, height)
> > ????'MsgBox(img3.Width & " width, " & img3.Height & " height ")
> > ????Dim g As Graphics = Graphics.FromImage(img3)
>
> > ????g.Clear(Color.Empty)
> > ????g.DrawImage(img1, New Point(0, 0))
> > ????g.DrawImage(img1, New Point(0, img1.Height))
> > ????g.Dispose()
>
> > ????img1.Dispose()
> > ????img2.Dispose()
>
> > ????img3.Save(jpg3, System.Drawing.Imaging.ImageFormat.Jpeg)
> > ????img3.Dispose()
>
> > Its showing it like this.. Please excuse the crude diagram!
>
> > _________________________
> > | ?st image ?| ???????????爘
> > | displays ??爘 ???????????爘
> > |__here _____| ???????????爘
> > | ?????????????????????爘
> > | ?????????????????????爘
> > | ????燽lack background ????|
> > | ?????????????????????爘
> > | ?????????????????????爘
> > |____________ ???????????|
> > | 2nd image ?爘 ???????????|
> > |displays here | ???????????|
> > |___________ |_____________|
>
> > This is how I would like to to appear...
>
> > ____________________
> > | ????????????????爘
> > | ????1st image ?????|
> > | ?????here ????????|
> > | ????????????????爘
> > | ????????????????爘
> > |___________________|
> > | ????????????????爘
> > | ????????????????爘
> > | ?????nd image ????|
> > | ?????爃ere ???????爘
> > | ????????????????爘
> > |___________________|
>
> > Any help is much appreciated.
>
> > Thanks
>
> > Paul
>
> Hi Paul,
>
> This code should do what you want, if all pictures have the same
> width, specifying width of one of them is enough to specify the entire
> picture's width, and the entire height is calculated by adding all the
> heights of pictures, that is img3 as follows:
>
> Dim jpg1 As String = "c:\existing_image_1.jpg"
> Dim jpg2 As String = "c:\existing_image_2.jpg"
> Dim jpg3 As String = "c:\new_image.jpg"
>
> Dim img1 As Image = Image.FromFile(jpg1)
> Dim img2 As Image = Image.FromFile(jpg2)
>
> ' If all images have same width
> ' specifiying one's width and
> ' is enough, eg: img1
>
> Dim width As Integer = img1.Width
> ' If All the pictures have same height, multiplying
> ' one of pic's height with picture amount is enough
> Dim height As Integer = img1.Height * 2
>
> Dim img3 As New Bitmap(width, height)
>
> Dim g As Graphics = Graphics.FromImage(img3)
>
> g.DrawImage(img1, 0, 0, img1.Width, img1.Height)
> g.DrawImage(img2, 0, img1.Height, img2.Width, img2.Height)
>
> img1.Dispose()
> img2.Dispose()
>
> img3.Save(jpg3, System.Drawing.Imaging.ImageFormat.Jpeg)
>
> Hope this helps,
>
> Onur G鼁el- Hide quoted text -
>
> - Show quoted text -

Hi Onur,

Thank you very much for the working code!  It works like a charm.  Now
my next step is to give support for more than 2 images and add a nice
GUI! Thanks for setting me on my way!

Paul

4.Convert Color image to Gray Shade Image

Hi all,

I'm creating a custom button control. I need to show a color image when
the button control is enabled and a gray shade of the same image when
the button control is disabled. How can i convert a color image to a
gray image in VB 2005.

Thanks,
Sugan
Chennai, INDIA

5.Combining Ink Strokes with Background Image into a Bit map Image

H
I need to combine Ink strokes with the background image into a bit map. Would appreciate any help

Thank
A

6. Image Button Problem: "SetPixel is not supported for images with indexed pixel formats"

7. Cached image name for images in WebBrowser control

8. Proper image format to use for Alpha images?



Return to MS WORD

 

Who is online

Users browsing this forum: No registered users and 74 guest