Print Page | Close Window

Problem with CaptionMetrics

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Property Grid
Forum Description: Topics Related to Codejock Property Grid
URL: http://forum.codejock.com/forum_posts.asp?TID=3222
Printed Date: 23 November 2024 at 2:14pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Problem with CaptionMetrics
Posted By: Miroslaw
Subject: Problem with CaptionMetrics
Date Posted: 15 November 2005 at 5:06am

 

When I write these lines of code:

  Set SubCategory = Category.AddChildItem(PropertyItemFont, "Font", Me.Font)
  SubCategory.CaptionMetrics.ForeColor = vbBlue

All is OK.

But when I write these lines of code:

  Set SubCategory = Category.AddChildItem(PropertyItemFont, "Font", Me.Font)
  SubCategory.CaptionMetrics.Font.Bold = True

I recieve error message: "Object variable or With block variable not set"

Where is my fault?




Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net