April 29, 200916 yr Hi Kaostika, Sure, you can use: Set Field [ containerField ; textField ] Commit Records/Requests But why would you want to do that instead of simply using the text field? Once you put text into a container, you lose the ability to modify or search that data. LaRetta
April 29, 200916 yr Hi, Is there a way with [color:blue]scriptmaster to put text into a container. Kaostika Are you asking about ScriptMaker, or ScriptMaster, as in this product Link If the later, then we should move it. Lee
April 29, 200916 yr Author Yes Sharp! I mean the 360 works Scriptmaster. I want to put text over a gradient. kaostika
May 2, 200916 yr Hi Kaostika, You can do this if you combine the "Java Drawing Example" (in the example database that comes with ScriptMaster 2.08) with the "Gradient Image" example. Add a third input variable "textstring" and modify the gradient code by including the creation of the text: import java.awt.*; import java.awt.image.*; import javax.imageio.*; int width=500; int height=200; Color c1 = Color.decode(color1); Color c2 = Color.decode(color2); GradientPaint gradient = new GradientPaint(0, 0, c1, width, height, c2); BufferedImage img = new BufferedImage(width, height, BufferedImage.TYPE_INT_RGB); Graphics2D g = img.createGraphics(); g.setPaint(gradient); g.fillRect(0, 0, width, height); // draw a transparent watermark string g.setColor(new Color(0, 255, 255, 100)); g.setFont(new Font("Verdana", Font.BOLD, 24)); g.drawString(textstring, 100, 100); return img; You may have to play around with it to position the text nicely, either hard coding or adding more variables.
Create an account or sign in to comment