Public Function CreateImage(path, size, font, xpos, ypos, color, text)
Picture1.Picture = LoadPicture(path)
Picture1.AutoRedraw = True
Picture1.FontSize = size
Picture1.font = font
Picture1.CurrentX = xpos
Picture1.CurrentY = ypos
Picture1.FillColor = color
Picture1.Print text
End Function
Private Sub UserControl_Initialize()
CreateImage "c:\10bt.jpg", 20, "Verdana", 50, 50, 120000, "SALL"
End Sub
My Vb application is like above
i saved it sates.vbp and sa1.ctl name of user contols is also sa1
i compiled it sates.ocx
in asp page
i tried it
<%
set xx=server.CreateObject ("sates.sa1")
%>
error
ASP 0241 (0x80004005)
creating ('null') object c0000005 (access violation )
<%
set xx=server.CreateObject ("sates.sa1")
%>
error
ASP 0177 (0x800401F3) Invalid ProgID
how can i solve this problem and use this ocx with parameters of my
function.. help me? 2 1905
Try to use it in another VB project to make sure you get the ProgID correct.
Ctrl-Alt-J to see the Object Browser might help
Jeff
"Savas Ates" <sa***@indexinteractive.com> wrote in message
news:#y**************@TK2MSFTNGP12.phx.gbl... Public Function CreateImage(path, size, font, xpos, ypos, color, text) Picture1.Picture = LoadPicture(path) Picture1.AutoRedraw = True Picture1.FontSize = size Picture1.font = font Picture1.CurrentX = xpos Picture1.CurrentY = ypos Picture1.FillColor = color Picture1.Print text End Function
Private Sub UserControl_Initialize() CreateImage "c:\10bt.jpg", 20, "Verdana", 50, 50, 120000, "SALL" End Sub
My Vb application is like above
i saved it sates.vbp and sa1.ctl name of user contols is also sa1
i compiled it sates.ocx
in asp page i tried it
<% set xx=server.CreateObject ("sates.sa1") %> error ASP 0241 (0x80004005) creating ('null') object c0000005 (access violation )
<% set xx=server.CreateObject ("sates.sa1") %> error ASP 0177 (0x800401F3) Invalid ProgID
how can i solve this problem and use this ocx with parameters of my function.. help me?
Is Picture1 a dialog control? If so I suspect that it requires a window in
order to be instantiated.
Try commenting out the CreateImage call in the initialize function. If
createobject does not give an error in the ASP page then that is probably
the case. VB objects which require a UI do not work in ASP be cause there is
no display context available. Exactly what are you trying to do?
--
Mark Schupp
Head of Development
Integrity eLearning www.ielearning.com
"Savas Ates" <sa***@indexinteractive.com> wrote in message
news:%2****************@TK2MSFTNGP12.phx.gbl... Public Function CreateImage(path, size, font, xpos, ypos, color, text) Picture1.Picture = LoadPicture(path) Picture1.AutoRedraw = True Picture1.FontSize = size Picture1.font = font Picture1.CurrentX = xpos Picture1.CurrentY = ypos Picture1.FillColor = color Picture1.Print text End Function
Private Sub UserControl_Initialize() CreateImage "c:\10bt.jpg", 20, "Verdana", 50, 50, 120000, "SALL" End Sub
My Vb application is like above
i saved it sates.vbp and sa1.ctl name of user contols is also sa1
i compiled it sates.ocx
in asp page i tried it
<% set xx=server.CreateObject ("sates.sa1") %> error ASP 0241 (0x80004005) creating ('null') object c0000005 (access violation )
<% set xx=server.CreateObject ("sates.sa1") %> error ASP 0177 (0x800401F3) Invalid ProgID
how can i solve this problem and use this ocx with parameters of my function.. help me? This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Chris Bates |
last post by:
I am getting the below error , which is stopping VS from creating the
classes for the reports I add.
When I add a Crystal Report.NET to a project in Visual studio enterprise
developer 2003, I...
|
by: ERI1618 |
last post by:
I am trying to create a table in Access but i have a syntax error:
I just want to crate a table with default values for excample
create table test (column1 Text(20) DEFAULT 'This is a test')
...
|
by: Solunac |
last post by:
Hi, everyone, I am new here ...
I have a problem to create a after-trigger (update).
Example tables:
CREATE TABLE R
(
log_num SMALLINT NOT NULL,
int_num SMALLINT NOT NULL,
|
by: punitshrivastava |
last post by:
Hi to All.
I am Punit Shrivastava.I am working in Asp.As i am new in this technology please help me.
I want to create enquiry form in Asp.
For this i code like this:
<form name="enquiry"...
|
by: taylorcarr |
last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
|
by: aa123db |
last post by:
Variable and constants
Use var or let for variables and const fror constants.
Var foo ='bar';
Let foo ='bar';const baz ='bar';
Functions
function $name$ ($parameters$) {
}
...
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
| |