Hi,
In my VB application, I create crystal report through CRPEAuto.Application object. I have Crystal report version 8.5 and VB6.
My problem is that it gets blank report. I am using the stored procedure. The crystal report passes two parameters. The crystal report works fine individually. But, seems like it has problem with the stored procedure. I have bunch of If statements in my stored procedure. If I remove those if statements, then it works fine in my application.
I was wondering why the same stored procedure works with crystal reports and not through VB? Is there any syntex problem? If somebody knows about it please let me know correct syntex.
My store procedure is like this...
CREATE Procedure dbo.Cycle_Packing_ListApp
@IsDistrict as bit,
@County_Shipment_Type as varchar(50)
AS
IF @IsDistrict = 1
SELECT * FROM orPackingList
ELSE
begin
IF @County_Shipment_Type = 'Cycle I'
SELECT statement....
ELSE IF @County_Shipment_Type = 'Cycle II'
SELECT statement....
ELSE IF @County_Shipment_Type = 'Cycle III'
SELECT statement....
end
Any suggestion is welcome,
Thanks,
Nita
In my VB application, I create crystal report through CRPEAuto.Application object. I have Crystal report version 8.5 and VB6.
My problem is that it gets blank report. I am using the stored procedure. The crystal report passes two parameters. The crystal report works fine individually. But, seems like it has problem with the stored procedure. I have bunch of If statements in my stored procedure. If I remove those if statements, then it works fine in my application.
I was wondering why the same stored procedure works with crystal reports and not through VB? Is there any syntex problem? If somebody knows about it please let me know correct syntex.
My store procedure is like this...
CREATE Procedure dbo.Cycle_Packing_ListApp
@IsDistrict as bit,
@County_Shipment_Type as varchar(50)
AS
IF @IsDistrict = 1
SELECT * FROM orPackingList
ELSE
begin
IF @County_Shipment_Type = 'Cycle I'
SELECT statement....
ELSE IF @County_Shipment_Type = 'Cycle II'
SELECT statement....
ELSE IF @County_Shipment_Type = 'Cycle III'
SELECT statement....
end
Any suggestion is welcome,
Thanks,
Nita